print all versions of tendermint and its sub protocols #9329
Conversation
cmd/tendermint/commands/version.go
Outdated
| values, _ := json.MarshalIndent(struct { | ||
| Tendermint string | ||
| ABCI string | ||
| BlockProtocol uint64 | ||
| P2PProtocol uint64 | ||
| }{ |
There was a problem hiding this comment.
Is the idea with the JSON format that this is going to be machine-interpreted? Who or what would be interpreting it?
And why the difference in JSON field naming convention as compared to what's used, for example, in the genesis file (Tendermint as opposed to tendermint, and BlockProtocol vs block_protocol)?
There was a problem hiding this comment.
did json format cause otherwise it looks ugly when printed. I can Rename if needed, I see this way as nicer
There was a problem hiding this comment.
I have a few suggestions here:
- Let's please rather keep the current
versioncommand default behaviour as-is (just printing the Tendermint version). I don't know if we always need to see all versions of all protocols in that output. Plus, people may rely on this output in scripts in some way, and if we're going to break it we'll need to add a changelog entry. - Could we add a
-v/--verboseflag to theversioncommand to print this JSON struct? - Let's please stick to the current JSON conventions used throughout the codebase, which favour
snake_case.
In general I like the idea of having the option of printing these JSON structs because they're machine-readable.
There was a problem hiding this comment.
Made the respective updates.
I don't think this requires a changelog as it doesn't really change the behaviour in a notable way but let me know if you disagree
…ermint into marko/print-all-versions
(cherry picked from commit ffce253)
(cherry picked from commit ffce253)
…x-rc1 * release/v0.37.0-rc1: QA Process report for v0.37.x (and baseline for v0.34.x) (tendermint#9499) (tendermint#9577) Fix TX payload for DO testnets (tendermint#9540) (tendermint#9542) blocksync: retry requests after timeout (backport tendermint#9518) (tendermint#9533) Extend the load report tool to include transactions' hashes (tendermint#9509) (tendermint#9513) build(deps): Bump styfle/cancel-workflow-action from 0.10.0 to 0.10.1 (tendermint#9502) build(deps): Bump actions/stale from 5 to 6 (tendermint#9494) loadtime: add block time to the data point (tendermint#9484) (tendermint#9489) config: Add missing storage section when generating config (tendermint#9483) (tendermint#9487) Sync Vote.Verify() in spec with implementation (tendermint#9466) (tendermint#9476) fix spec (tendermint#9467) (tendermint#9469) metrics: fix panic because of absent prometheus label (tendermint#9455) (tendermint#9474) Ensure Dockerfile stages use consistent Go version (backport tendermint#9462) (tendermint#9472) build(deps): Bump slackapi/slack-github-action from 1.21.0 to 1.22.0 (tendermint#9432) build(deps): Bump bufbuild/buf-setup-action from 1.7.0 to 1.8.0 (tendermint#9453) state: restore previous error message (tendermint#9435) (tendermint#9440) build(deps): Bump gonum.org/v1/gonum from 0.11.0 to 0.12.0 (tendermint#9411) docs: Update ADRs for v0.37 (tendermint#9399) (tendermint#9418) build(deps): Bump github.com/spf13/viper from 1.12.0 to 1.13.0 (tendermint#9410) build(deps): Bump github.com/lib/pq from 1.10.6 to 1.10.7 (tendermint#9409) feat: support HTTPS inside websocket (tendermint#9416) (tendermint#9422) Removed unused param (tendermint#9394) test: generate uuid on startup for load tool (tendermint#9383) (tendermint#9392) add redirect links (tendermint#9385) (tendermint#9389) refactor: migrate to cosmos/gogoproto (backport tendermint#9356) (tendermint#9381) cmd: print all versions of tendermint and its sub protocols (tendermint#9329) (tendermint#9386) Add missing changes changelog files (backport tendermint#9376) (tendermint#9382) add separated runs by UUID (backport tendermint#9367) (tendermint#9379) spec: abci++ cleanup for v0.37 (backport tendermint#9288) (tendermint#9374) ci: Remove "(WARNING: BETA SOFTWARE)" tagline from all upcoming releases (tendermint#9371) (tendermint#9372) Update rpc client header (tendermint#9276) (tendermint#9349) ci: Pre-release workflows (backport tendermint#9366) (tendermint#9368) test: add the loadtime report tool (tendermint#9351) (tendermint#9364) Update Tendermint version to v0.37.0 (tendermint#9354) test: add the loadtime tool (tendermint#9342) (tendermint#9357) # Conflicts: # version/version.go
print all versions of tendermint not only the main one
could we get this into 0.34 as well?
PR checklist
CHANGELOG_PENDING.mdupdated, or no changelog entry neededdocs/) and code comments, or nodocumentation updates needed