Skip to content
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

Support multiple network definitions inside a Package #358

Merged
merged 15 commits into from
Dec 22, 2023

Conversation

sduchesneau
Copy link
Contributor

@sduchesneau sduchesneau commented Dec 20, 2023

Add support for multiple network definitions inside a Package.

From changelog:

Highlights

  • Support new networks configuration block in substreams.yaml to override modules' params and initial_block. Network can be specified at run-time, avoiding the need for separate spkg files for each chain.
  • [BREAKING CHANGE] Remove the support for the deriveFrom overrides. The imports, along with the new networks feature, should provide a better mechanism to cover the use cases that deriveFrom tried to address.

These changes are all handled in the substreams CLI. The Substreams server endpoints do not need to be upgraded to support it.

Added

  • Added networks field at the top level of the manifest definition, with initialBlock and params overrides for each module. See the substreams.yaml.example file in the repository or https://substreams.streamingfast.io/reference-and-specs/manifests for more details and example usage.
  • The networks params and `initialBlock`` overrides for the chosen network are applied to the module directly before being sent to the server. All network configurations are kept when packing an .spkg file.
  • Added the --network flag for choosing the network on run and gui command. Default behavior is to use the one defined as network in the manifest.

Removed

  • Removed the handling of the DeriveFrom keyword in manifest, this override feature is going away.
  • Removed the `--skip-package-validation`` option only on run/gui/inspect/info

Fixed

  • The substreams gui command no longer reads the .spkg multiple times with different behavior during its process.

@sduchesneau sduchesneau marked this pull request as ready for review December 22, 2023 16:09
@sduchesneau sduchesneau merged commit d377089 into develop Dec 22, 2023
7 checks passed
@sduchesneau sduchesneau deleted the feature/multiple-networks branch December 22, 2023 16:14
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.

1 participant