Skip to content

fix(chain-spec): ChainSpecBuilder with object as default genesis#4345

Merged
bkchr merged 3 commits intoparitytech:masterfrom
saiintbrisson:patch-1
Jul 24, 2024
Merged

fix(chain-spec): ChainSpecBuilder with object as default genesis#4345
bkchr merged 3 commits intoparitytech:masterfrom
saiintbrisson:patch-1

Conversation

@saiintbrisson
Copy link
Contributor

The current json_patch::merge function will replace the default configuration with the builder action if the action is not a JSON Object, which means, if not configured, the current code will try to use Value::Null as the config, which (almost?) always fails, making it mandatory to configure with_genesis_config....

This change uses a JSON Object as the default values, which means the code will continue using the default config if none is given.

…nesis

The current `json_patch::merge` function will replace the default configuration with the builder action if the action is not a JSON Object, which means, if not configured, the current code will try to use `Value::Null` as the config, which (almost?) always fails, making it mandatory to configure `with_genesis_config...`.

This change uses a JSON Object as the default values, which means the code will continue using the default config if none is given.
@cla-bot-2021
Copy link

cla-bot-2021 bot commented May 1, 2024

User @saiintbrisson, please sign the CLA here.

@bkchr bkchr requested a review from michalkucharczyk May 2, 2024 07:47
Copy link
Member

@bkchr bkchr left a comment

Choose a reason for hiding this comment

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

Could you please add some test and some comment?

@bkchr bkchr added the T0-node This PR/Issue is related to the topic “node”. label May 2, 2024
@bkchr bkchr enabled auto-merge July 17, 2024 20:11
@bkchr bkchr added R0-no-crate-publish-required The change does not require any crates to be re-published. and removed T0-node This PR/Issue is related to the topic “node”. labels Jul 24, 2024
@bkchr bkchr added this pull request to the merge queue Jul 24, 2024
@bkchr bkchr added T0-node This PR/Issue is related to the topic “node”. and removed R0-no-crate-publish-required The change does not require any crates to be re-published. labels Jul 24, 2024
Merged via the queue into paritytech:master with commit b9aa8ab Jul 24, 2024
@bkchr bkchr added R0-no-crate-publish-required The change does not require any crates to be re-published. and removed T0-node This PR/Issue is related to the topic “node”. labels Jul 24, 2024
@saiintbrisson saiintbrisson deleted the patch-1 branch July 26, 2024 01:09
TarekkMA pushed a commit to moonbeam-foundation/polkadot-sdk that referenced this pull request Aug 2, 2024
…itytech#4345)

The current `json_patch::merge` function will replace the default
configuration with the builder action if the action is not a JSON
Object, which means, if not configured, the current code will try to use
`Value::Null` as the config, which (almost?) always fails, making it
mandatory to configure `with_genesis_config...`.

This change uses a JSON Object as the default values, which means the
code will continue using the default config if none is given.

Co-authored-by: Bastian Köcher <[email protected]>
ordian added a commit that referenced this pull request Aug 6, 2024
* master: (27 commits)
  Bridges improved tests and nits (#5128)
  Fix misleading comment about RewardHandler in epm config (#3095)
  Introduce a workflow updating the wishlist leaderboards (#5085)
  membership: Restructure pallet into separate files (#4536)
  Fix after ring-proof api change (#5126)
  Bump paritytech/review-bot from 2.4.0 to 2.5.0 (#5057)
  Bump docker/login-action from 3.0.0 to 3.3.0 (#5109)
  Bump docker/build-push-action from 5.1.0 to 6.5.0 (#5108)
  Bump peter-evans/create-pull-request from 5.0.0 to 6.1.0 (#5093)
  Tx Payment: drop ED requirements for tx payments with exchangeable asset  (#4488)
  Remove `pallet-getter` usage from pallet-transaction-payment (#4970)
  pallet macro: do not generate try-runtime related code when frame-support doesn't have try-runtime. (#5099)
  fix(chain-spec): ChainSpecBuilder with object as default genesis (#4345)
  Migrate BEEFY BLS crypto to  bls12-381 curve (#4931)
  Bump clap from 4.5.9 to 4.5.10 in the known_good_semver group (#5120)
  Use jobserver in wasm-builder to limit concurrency of spawned cargo processes (#4946)
  include events for voting (#4613)
  [subsystem-bench] Add mocks for own assignments triggering (#5042)
  Remove not-audited warning (#5114)
  hotfix: blockchain/backend: Skip genesis leaf to unblock syncing (#5103)
  ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

R0-no-crate-publish-required The change does not require any crates to be re-published.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants