Skip to content

Changed tutorial bitcoin config file to work with new core v0.17 format#454

Merged
instagibbs merged 2 commits intoElementsProject:elements-0.14.1from
wintercooled:elements-0.14.1
Nov 2, 2018
Merged

Changed tutorial bitcoin config file to work with new core v0.17 format#454
instagibbs merged 2 commits intoElementsProject:elements-0.14.1from
wintercooled:elements-0.14.1

Conversation

@wintercooled
Copy link
Copy Markdown
Contributor

Core v0.17 now handles config file settings differently and loads the existing config settings as mainnet and not regtest. This means our e1 and e2 nodes in the tutorial can't connect.

This PR makes the bitcoin.conf file compatible with both formats. Without this change the tutorial code fails if you are using bitcoind v0.17.0.0.

REF: https://github.com/bitcoin/bitcoin/blob/master/doc/release-notes/release-notes-0.17.0.md

If the following options are not in a section, they will only apply to mainnet:
addnode=, connect=, port=, bind=, rpcport=, rpcbind= and wallet=.
The options to choose a network (regtest= and testnet=) must be specified
outside of sections.

Tested with bitcoind v0.16.2.0 and v0.17.0.0

Comment thread contrib/assets_tutorial/bitcoin.conf Outdated
txindex=1

regtest.rpcuser=user3
regtest.rpcpassword=password3
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

I think these 2 lines are redundant because rpcuser and rpcpassword will apply to all networks if they are not in any section.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

I see - I will retest and amend accordingly. Thanks.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

I have updated the PR and removed .rpcuser and .rpcpassword and tested on 0.17 and 0.16.2 thanks @AkioNak

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM.

@instagibbs
Copy link
Copy Markdown
Contributor

thanks for the review @AkioNak

@instagibbs instagibbs merged commit 16113d8 into ElementsProject:elements-0.14.1 Nov 2, 2018
instagibbs added a commit that referenced this pull request Nov 2, 2018
…e v0.17 format

16113d8 Removed redundant .rpcuser, .rpcpassword (wintercooled)
370e797 Changed config file to work with new core v0.17 format as well as previous versions (wintercooled)

Pull request description:

  Core v0.17 now handles config file settings differently and loads the existing config settings as mainnet and not regtest. This means our e1 and e2 nodes in the tutorial can't connect.

  This PR makes the bitcoin.conf file compatible with both formats. Without this change the tutorial code fails if you are using bitcoind v0.17.0.0.

  REF: https://github.com/bitcoin/bitcoin/blob/master/doc/release-notes/release-notes-0.17.0.md

  If the following options are not in a section, they will only apply to mainnet:
  `addnode=`, `connect=`, `port=`, `bind=`, `rpcport=`, `rpcbind=` and `wallet=`.
  The options to choose a network (`regtest=` and `testnet=`) must be specified
  outside of sections.

  Tested with bitcoind v0.16.2.0 and v0.17.0.0

Tree-SHA512: 3136703da17570e410c1e86ab31f3ac0bca60847164dd10e75a57affd1b7b67fdfbba2be5437ad9ffdd5428c10f6d34073d3e746f55dacda858ab47b517cd3fc
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.

3 participants