Skip to content

Add contract release checker#192

Merged
cyc60 merged 2 commits into
masterfrom
contract-release
Apr 29, 2026
Merged

Add contract release checker#192
cyc60 merged 2 commits into
masterfrom
contract-release

Conversation

@cyc60
Copy link
Copy Markdown
Contributor

@cyc60 cyc60 commented Apr 29, 2026

No description provided.

Copilot AI review requested due to automatic review settings April 29, 2026 10:07
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Introduces a contract “release version” model per network and adds helper functions to check whether a vault (regular / genesis / meta) meets the minimum contract release requirements (including Pectra as release V4).

Changes:

  • Added sw_utils/release.py with is_vault_upgraded_to_release(...) and related helpers.
  • Extended BaseNetworkConfig with CONTRACTS_RELEASES and added V4/V5 release thresholds for MAINNET/HOODI/GNOSIS.
  • Removed the legacy sw_utils/pectra.py helper and bumped the package version.

Reviewed changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
sw_utils/release.py New public helpers to check vault upgrade status against per-network contract releases.
sw_utils/pectra.py Removes the old Pectra-specific vault-version helper module.
sw_utils/networks.py Defines release version enum/model and adds per-network release thresholds.
sw_utils/init.py Re-exports the new release-checker helpers.
pyproject.toml Bumps package version to v0.12.16.
Comments suppressed due to low confidence (1)

sw_utils/pectra.py:1

  • sw_utils/pectra.py is removed, which is a breaking change for any downstream code that imports sw_utils.pectra / get_pectra_vault_version. If this removal is intentional, consider keeping a thin compatibility wrapper (e.g., get_pectra_vault_version delegating to the new release-based logic) and/or doing a major version bump with a deprecation period instead of removing the module outright in a patch release.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread pyproject.toml Outdated
Comment thread sw_utils/release.py
@cyc60 cyc60 merged commit c04775a into master Apr 29, 2026
3 checks passed
@cyc60 cyc60 deleted the contract-release branch April 29, 2026 11:41
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