Skip to main content
added ref to existing doc, more clarifications on full vs patch.
Source Link

The more relevant doc describing the chain spec format is here: https://paritytech.github.io/polkadot-sdk/master/sc_chain_spec/index.html#

The RuntimeGenesisConfig within a chain-spec can be provided in two formats - full json representation of RuntimeGenesisConfig struct, and patch representation applied to the default value of RuntimeGenesisConfig.

The main purpose of genesis config patch:

  • minimize the maintenance effort when RuntimeGenesisConfig is changed in future (e.g. new pallets added to runtime or pallet's genesis config changed),
  • increase readability - it only contains relevant fields,
  • allows to apply numerous changes in distinct domains (e.g. for zombienet).

Patch is intended for development/testing configurations.

(link to relevant discussion: https://github.com/paritytech/polkadot-sdk/issues/62#issuecomment-1763992444)

The main purpose of genesis config patch:

  • minimize the maintenance effort when RuntimeGenesisConfig is changed in future (e.g. new pallets added to runtime or pallet's genesis config changed),
  • increase readability - it only contains relevant fields,
  • allows to apply numerous changes in distinct domains (e.g. for zombienet).

Patch is intended for development/testing configurations.

(link to relevant discussion: https://github.com/paritytech/polkadot-sdk/issues/62#issuecomment-1763992444)

The more relevant doc describing the chain spec format is here: https://paritytech.github.io/polkadot-sdk/master/sc_chain_spec/index.html#

The RuntimeGenesisConfig within a chain-spec can be provided in two formats - full json representation of RuntimeGenesisConfig struct, and patch representation applied to the default value of RuntimeGenesisConfig.

The main purpose of genesis config patch:

  • minimize the maintenance effort when RuntimeGenesisConfig is changed in future (e.g. new pallets added to runtime or pallet's genesis config changed),
  • increase readability - it only contains relevant fields,
  • allows to apply numerous changes in distinct domains (e.g. for zombienet).

Patch is intended for development/testing configurations.

(link to relevant discussion: https://github.com/paritytech/polkadot-sdk/issues/62#issuecomment-1763992444)

Source Link

The main purpose of genesis config patch:

  • minimize the maintenance effort when RuntimeGenesisConfig is changed in future (e.g. new pallets added to runtime or pallet's genesis config changed),
  • increase readability - it only contains relevant fields,
  • allows to apply numerous changes in distinct domains (e.g. for zombienet).

Patch is intended for development/testing configurations.

(link to relevant discussion: https://github.com/paritytech/polkadot-sdk/issues/62#issuecomment-1763992444)