Skip to content

feat(soroban): add contract upgrade orchestration with state migration safety verification#860

Merged
temma02 merged 1 commit into
StellerCraft:mainfrom
ayomidearegbeshola29-dev:feat/soroban-contract-upgrade-orchestration
Jun 27, 2026
Merged

feat(soroban): add contract upgrade orchestration with state migration safety verification#860
temma02 merged 1 commit into
StellerCraft:mainfrom
ayomidearegbeshola29-dev:feat/soroban-contract-upgrade-orchestration

Conversation

@ayomidearegbeshola29-dev

Copy link
Copy Markdown
Contributor

Summary

Implements Soroban Contract Upgrade Orchestration with state migration safety verification (#770).

Changes

  • upgrade-orchestrator.ts: New module with:

    • diffAbiSchemas() — compares old/new ABI schemas using structural diff, detecting added, removed, and type-changed storage keys
    • orchestrateContractUpgrade() — orchestrates upgrades with schema safety checks and optional dry-run simulation
    • Breaking change detection: blocks upgrades that remove required keys or change storage key durability types
    • Dry-run support: simulates the upgrade transaction via Soroban RPC without broadcasting
    • Detailed SchemaDiffReport with human-readable summary and categorized changes
  • index.ts: Added export for the new module

  • upgrade-orchestrator.test.ts: Comprehensive tests covering:

    • Safe upgrades (identical schemas, adding keys)
    • Breaking change detection (removed required keys, type changes)
    • Dry-run simulation (success, RPC errors, simulation errors)
    • Edge cases (empty schemas, mixed changes)

Testing

✓ src/upgrade-orchestrator.test.ts  (16 tests)

Closes #770

…n safety verification

Co-authored-by: opencode <opencode@users.noreply.github.com>
@drips-wave

drips-wave Bot commented Jun 26, 2026

Copy link
Copy Markdown

@ayomidearegbeshola29-dev Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits.

You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀

Learn more about application limits

@temma02 temma02 merged commit f3f4dc7 into StellerCraft:main Jun 27, 2026
0 of 7 checks passed
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.

Implement Soroban Contract Upgrade Orchestration with State Migration Safety Verification

2 participants