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

cmd/geth: print version on geth start #2622

Merged
merged 3 commits into from
Jul 12, 2016
Merged

cmd/geth: print version on geth start #2622

merged 3 commits into from
Jul 12, 2016

Conversation

mattdf
Copy link
Member

@mattdf mattdf commented May 26, 2016

For feature request #2609 - print version on geth start to help development / debugging when using different geth instances.

@robotally
Copy link

robotally commented May 26, 2016

Vote Count Reviewers
👍 0
👎 0

Updated: Wed Jun 8 14:13:58 UTC 2016

@bas-vk
Copy link
Member

bas-vk commented May 30, 2016

You added this line to the geth subcommand. That means if the users starts geth with a different subcommand, e.g. the console subcommand it would not print the version. Printing the version is only interesting when the node is actually started. Therefore a better place would be in the startNode function.

We also use the convention to specify the package name in the commit message.

@mattdf
Copy link
Member Author

mattdf commented May 31, 2016

I've moved it to the startNode function and changed the commit message format. Does that look fine?

@mattdf mattdf changed the title Print version on normal geth start cmd/geth: print version on geth start May 31, 2016
@codecov-io
Copy link

Current coverage is 56.39%

Merging #2622 into develop will decrease coverage by <.01%

@@            develop      #2622   diff @@
==========================================
  Files           215        215          
  Lines         24506      24575    +69   
  Methods           0          0          
  Messages          0          0          
  Branches          0          0          
==========================================
+ Hits          13821      13859    +38   
- Misses        10682      10715    +33   
+ Partials          3          1     -2   

Powered by Codecov. Last updated by a7434fd...aa05cd5

@bas-vk
Copy link
Member

bas-vk commented Jun 8, 2016

LGTM 👍

@@ -434,6 +434,8 @@ func execScripts(ctx *cli.Context) {
// it unlocks any requested accounts, and starts the RPC/IPC interfaces and the
// miner.
func startNode(ctx *cli.Context, stack *node.Node) {
// Report geth version
glog.V(logger.Info).Infof("instance: Geth/%s/%s/%s\n", verString, runtime.Version(), runtime.GOOS)
Copy link
Member

Choose a reason for hiding this comment

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

Please use utils.MakeNodeName(clientIdentifier, verString, ctx) instead of manually constructing the name. Also there's no need for the \n at the end of the log message. Also please rename instance: to Node version: (note, capitalized).

@karalabe
Copy link
Member

karalabe commented Jun 8, 2016

PS: Please also squash your commits into a single one :) (git rebase -i HEAD~3)

@karalabe karalabe added the review label Jun 8, 2016
@fjl fjl merged commit 68b48cc into ethereum:develop Jul 12, 2016
@fjl fjl removed the review label Jul 12, 2016
maoueh pushed a commit to streamingfast/go-ethereum that referenced this pull request Aug 14, 2024
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.

6 participants