Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

enrich versioning with build deps #7848

Merged
merged 4 commits into from
Nov 9, 2020
Merged

enrich versioning with build deps #7848

merged 4 commits into from
Nov 9, 2020

Conversation

alessio
Copy link
Contributor

@alessio alessio commented Nov 8, 2020

The version command now displays the list of
build dependencies.

Also fix version's command output stream.

version's output should go to stdout as it's the command's
objective to actually display versioning information.

closes: #7835


Before we can merge this PR, please make sure that all the following items have been
checked off. If any of the checklist items are not applicable, please leave them but
write a little note why.

  • Targeted PR against correct branch (see CONTRIBUTING.md)
  • Linked to Github issue with discussion and accepted design OR link to spec that describes this work.
  • Code follows the module structure standards.
  • Wrote unit and integration tests
  • Updated relevant documentation (docs/) or specification (x/<module>/spec/)
  • Added relevant godoc comments.
  • Added a relevant changelog entry to the Unreleased section in CHANGELOG.md
  • Re-reviewed Files changed in the Github PR explorer
  • Review Codecov Report in the comment section below once CI passes

Alessio Treglia added 2 commits November 8, 2020 02:26
It's command's objective to actually display
versioning information.
@codecov
Copy link

codecov bot commented Nov 8, 2020

Codecov Report

Merging #7848 (cc5473e) into master (dd9ef12) will decrease coverage by 0.00%.
The diff coverage is 50.00%.

@@            Coverage Diff             @@
##           master    #7848      +/-   ##
==========================================
- Coverage   54.23%   54.23%   -0.01%     
==========================================
  Files         609      609              
  Lines       38807    38817      +10     
==========================================
+ Hits        21046    21051       +5     
- Misses      15604    15609       +5     
  Partials     2157     2157              

@alessio
Copy link
Contributor Author

alessio commented Nov 9, 2020

A practical example follows.

This is the information presently displayed by appd version --long:

alessio@phoenix:~/work/cosmos-sdk$ build/simd version --long
name: sim
server_name: simd
version: goz-phase-1-866-g70fa17b55
commit: 70fa17b55a97e99f2db09a9769416cf52a962193
build_tags: netgo,ledger
go: go version go1.15.2 linux/amd64

The following is appd version --long's new output:

alessio@phoenix:~/work/cosmos-sdk$ build/simd version --long
name: sim
server_name: simd
version: goz-phase-1-870-gcc5473e0b
commit: cc5473e0b49f18f2b728f1b6eea43aab3ed80e3b
build_tags: netgo,ledger
go: go version go1.15.2 linux/amd64
build_deps:
- github.com/99designs/keyring@v1.1.6
- github.com/ChainSafe/go-schnorrkel@v0.0.0-20200405005733-88cbf1b4c40d
- github.com/Workiva/go-datastructures@v1.0.52
- github.com/armon/go-metrics@v0.3.4
- github.com/beorn7/perks@v1.0.1
- github.com/bgentry/speakeasy@v0.1.0
- github.com/btcsuite/btcd@v0.21.0-beta
- github.com/cespare/xxhash/v2@v2.1.1
- github.com/confio/ics23/go@v0.6.3
- github.com/cosmos/go-bip39@v0.0.0-20180819234021-555e2067c45d
- github.com/cosmos/iavl@v0.15.0-rc4
- github.com/cosmos/ledger-cosmos-go@v0.11.1
- github.com/cosmos/ledger-go@v0.9.2
- github.com/davecgh/go-spew@v1.1.1
- github.com/dvsekhvalnov/jose2go@v0.0.0-20200901110807-248326c1351b
- github.com/enigmampc/btcutil@v1.0.3-0.20200723161021-e2fb6adb2a25
- github.com/felixge/httpsnoop@v1.0.1
- github.com/fsnotify/fsnotify@v1.4.9
- github.com/go-kit/kit@v0.10.0
- github.com/go-logfmt/logfmt@v0.5.0
- github.com/godbus/dbus@v0.0.0-20190726142602-4481cbc300e2
- github.com/gogo/gateway@v1.1.0
- github.com/gogo/protobuf@v1.3.1
- github.com/golang/protobuf@v1.4.3
- github.com/golang/snappy@v0.0.2
- github.com/google/btree@v1.0.0
- github.com/gorilla/handlers@v1.5.1
- github.com/gorilla/mux@v1.8.0
- github.com/gorilla/websocket@v1.4.2
- github.com/grpc-ecosystem/grpc-gateway@v1.15.2
- github.com/gsterjov/go-libsecret@v0.0.0-20161001094733-a6f4afe4910c
- github.com/gtank/merlin@v0.1.1
- github.com/gtank/ristretto255@v0.1.2
- github.com/hashicorp/go-immutable-radix@v1.0.0
- github.com/hashicorp/golang-lru@v0.5.4
- github.com/hashicorp/hcl@v1.0.0
- github.com/libp2p/go-buffer-pool@v0.0.2
- github.com/magiconair/properties@v1.8.4
- github.com/mattn/go-isatty@v0.0.12
- github.com/matttproud/golang_protobuf_extensions@v1.0.1
- github.com/mimoo/StrobeGo@v0.0.0-20181016162300-f8f6d4d2b643
- github.com/minio/highwayhash@v1.0.1
- github.com/mitchellh/go-homedir@v1.1.0
- github.com/mitchellh/mapstructure@v1.1.2
- github.com/mtibben/percent@v0.2.1
- github.com/pelletier/go-toml@v1.8.0
- github.com/pkg/errors@v0.9.1
- github.com/pmezard/go-difflib@v1.0.0
- github.com/prometheus/client_golang@v1.8.0
- github.com/prometheus/client_model@v0.2.0
- github.com/prometheus/common@v0.14.0
- github.com/prometheus/procfs@v0.2.0
- github.com/rakyll/statik@v0.1.7
- github.com/rcrowley/go-metrics@v0.0.0-20200313005456-10cdbea86bc0
- github.com/regen-network/cosmos-proto@v0.3.0
- github.com/rs/cors@v1.7.0
- github.com/spf13/afero@v1.2.2
- github.com/spf13/cast@v1.3.1
- github.com/spf13/cobra@v1.1.1
- github.com/spf13/jwalterweatherman@v1.1.0
- github.com/spf13/pflag@v1.0.5
- github.com/spf13/viper@v1.7.1
- github.com/stretchr/testify@v1.6.1
- github.com/subosito/gotenv@v1.2.0
- github.com/syndtr/goleveldb@v1.0.1-0.20200815110645-5c35d600f0ca
- github.com/tendermint/btcd@v0.1.1
- github.com/tendermint/crypto@v0.0.0-20191022145703-50d29ede1e15
- github.com/tendermint/go-amino@v0.16.0
- github.com/tendermint/tendermint@v0.34.0-rc6
- github.com/tendermint/tm-db@v0.6.2
- github.com/zondax/hid@v0.9.0
- golang.org/x/crypto@v0.0.0-20201012173705-84dcc777aaee
- golang.org/x/net@v0.0.0-20200930145003-4acb6c075d10
- golang.org/x/sys@v0.0.0-20201015000850-e3ed0017c211
- golang.org/x/text@v0.3.3
- google.golang.org/genproto@v0.0.0-20201014134559-03b6142f0dc9
- google.golang.org/grpc@v1.33.0
- google.golang.org/protobuf@v1.25.0
- gopkg.in/ini.v1@v1.51.0
- gopkg.in/yaml.v2@v2.3.0
- gopkg.in/yaml.v3@v3.0.0-20200313102051-9f266ea9e77c

Copy link
Member

@tac0turtle tac0turtle left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.

Copy link
Contributor

@amaury1093 amaury1093 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm.

Would like to understand the context of this addition: did a user ask for it? In what use-cases is it useful (one could just go to github to check the same thing)?

@alessio
Copy link
Contributor Author

alessio commented Nov 9, 2020

@amaurymartiny yep: #7835

Plus I bet users would find extremely useful while debugging to know what version of the cosmos-sdk their app builds on.

Copy link
Contributor

@alexanderbez alexanderbez left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ACK (so long as this is only visible with the --long flag).

@alessio alessio merged commit e172a08 into master Nov 9, 2020
@alessio alessio deleted the alessio/enrich-version branch November 9, 2020 15:17
alessio pushed a commit that referenced this pull request Nov 9, 2020
The output of the version --long command now shows
the list of build dependencies.

From: #7848
Closes: #7835
alessio pushed a commit that referenced this pull request Nov 9, 2020
The output of the version --long command now shows
the list of build dependencies.

From: #7848
Closes: #7835
alessio pushed a commit that referenced this pull request Nov 10, 2020
The output of the version --long command now shows
the list of build dependencies.

From: #7848
Closes: #7835
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Make gaiacli version --long include the cosmos SDK version.
4 participants