-
Notifications
You must be signed in to change notification settings - Fork 38.7k
add NetworkIDString() to chainparams #4326
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
Conversation
src/qt/clientmodel.cpp
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Shouldn't this be "regtest"?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Indeed...
|
Hmm I just realize that we have the same information in getblockchaininfo, there it also uses the datadir name to identify the network. Not sure whether it's nice to change the debug window now (or we should use the BIP70 naming in getblockchaininfo as well, which may make sense... ). |
|
@laanwj IMHO it should be consistent all over the place and if we want to compare the strings it would be best to use ones that can be compared, so I vote for the BIP70 naming. |
|
I could add a Edit: See 2nd commit, that could be used instead, what do you think? |
|
Yes - I was initially against putting the BIP70 names on ChainParams as it was seemingly a UI-only thing @jtimon but with the field in |
|
Yes, I would have used a string network id chainparam like it's done in https://github.com/Diapolo/bitcoin/commit/dcca44115dfcafb38cc435679b40fde3c8179d19 You can just replace and completely forget about my PaymentServer::mapNetworkIdToName and your ClientModel::getNetworkName. |
|
I'm currently reworking this... |
- returns the BIP70 network string - use that new function in the core and GUI code and remove unused code and functions
|
Done... |
|
Seems we have two equivalent pulls now... |
|
@laanwj Not really, I took care of clientmodel and rpcconsole also ;). |
|
Right :) |
|
I created another PR (#4333) using jtimon@f5ae6c9 and making my other proposed change (removing chainparams::RPCisTestnet) on top of it. |
|
Automatic sanity-testing: PASSED, see http://jenkins.bluematt.me/pull-tester/f5ae6c98260fdd3c0ca203ce67c6467d9cdaea95 for binaries and test log. |
f5ae6c9 add NetworkIDString() to chainparams (Philip Kaufmann)
and functions