Skip to content
This repository has been archived by the owner on Apr 6, 2020. It is now read-only.

Added support for private network parameters #24

Merged
merged 1 commit into from
Aug 27, 2018
Merged

Conversation

vpulim
Copy link
Contributor

@vpulim vpulim commented Aug 22, 2018

Added ability to construct a Common instance using custom chain parameters. Instead of calling new Common('mainnet'), you can now call new Common(chainParams) where chainParams is an object containing chain parameters for a private network. The chainParams object must contain at least these fields networkId, genesis, hardforks and bootstrapNodes.

@coveralls
Copy link

coveralls commented Aug 22, 2018

Pull Request Test Coverage Report for Build 90

  • 7 of 7 (100.0%) changed or added relevant lines in 1 file are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage increased (+0.2%) to 95.909%

Totals Coverage Status
Change from base Build 79: 0.2%
Covered Lines: 127
Relevant Lines: 131

💛 - Coveralls

@vpulim vpulim force-pushed the private-networks branch 2 times, most recently from 9648353 to 9bc9b1a Compare August 22, 2018 04:59
@holgerd77
Copy link
Member

Hi @vpulim, I am ok with the changes. This should be also reflected in the JSDocs, and the API documentation should be submitted in a re-generated version.

@vpulim
Copy link
Contributor Author

vpulim commented Aug 25, 2018

Thanks @holgerd77. Updated jsdoc and regenerated docs/index.md

Copy link
Member

@holgerd77 holgerd77 left a comment

Choose a reason for hiding this comment

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

Ok, cool, this looks good now. Had another closer look and checked the parameters, think it's ok to leave the URL field, though things like that are generally a bit dangerous, nevertheless - I conceptualized this field anyhow for just an external reviewer informational field, so this should be ok for now.

I also had some question how hardfork parameter selection now works in a private network, but on a second thought I realized that this was irritation on my side.

I will directly prepare a subsequent release on this, as v0.5.0.

@holgerd77 holgerd77 merged commit f426d93 into master Aug 27, 2018
@holgerd77 holgerd77 deleted the private-networks branch August 27, 2018 09:05
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants