feat(tooling): contract state export, migration & dependency analysis (#496, #497, #499)#545
Merged
Smartdevs17 merged 1 commit intoJun 27, 2026
Conversation
…sis (Smartdevs17#496, Smartdevs17#497, Smartdevs17#499) Adds a cohesive contract-lifecycle tooling suite under scripts/, each a dependency-free TypeScript CLI (runs on Node >= 22 via --experimental-strip-types) with a pure, unit-tested core. Smartdevs17#499 — scripts/state-exporter/ - Export user positions, pool configs, and governance to JSON/CSV. - Full snapshot + incremental change-data-capture (diff vs previous snapshot). - Verifiable: SHA-256 checksum + row-count manifest, integrity check command. - gzip compression. Pluggable StateSource (file source by default). Smartdevs17#497 — scripts/state-migrate/ - Declarative schema migrations: add/rename/remove/transform field. - Dry-run (never mutates), atomic checkpoint rollback on op error or failed verification, post-migration integrity checks, monotonic versioned history, heuristic per-op cost estimate, CLI. Smartdevs17#496 — scripts/dependency-analyzer/ - Scans the Rust/Soroban workspace, builds a contract dependency graph (call / import / library edges), transitive upgrade-impact + risk level, cycle detection, Graphviz DOT + JSON output. Verified against the real workspace (28 crates). Tests: 29 passing across the three cores node --experimental-strip-types --test scripts/**/**.test.ts Each tool's README documents covered acceptance criteria and the heavier infra follow-ups intentionally left out of this core (live RPC source, Parquet/SQL, S3/GCS, scheduling; on-chain gas metering; interactive D3 dashboard + CI wiring).
|
@Itodo-S is attempting to deploy a commit to the smartdevs17's projects Team on Vercel. A member of the Team first needs to authorize it. |
|
@Itodo-S 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! 🚀 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds a cohesive contract-lifecycle tooling suite under
scripts/, resolving three related issues in one PR. Each tool is a dependency-free TypeScript CLI (runs on Node ≥ 22 via--experimental-strip-types, matching the repo'sscripts/TS convention) with a pure, unit-tested core.#499 — State Exporter (
scripts/state-exporter/)--verifyintegrity command.StateSource(file source by default → runnable offline).#497 — State Migration Tool (
scripts/state-migrate/)addField/removeField/renameField/transformField.#496 — Dependency Analyzer (
scripts/dependency-analyzer/)Testing
node --experimental-strip-types --test \ scripts/state-exporter/exporter.test.ts \ scripts/state-migrate/migrator.test.ts \ scripts/dependency-analyzer/analyzer.test.ts # 29 passingEach tool has a README documenting its covered acceptance criteria.
Scope note
These are large (200-point) issues. This PR delivers a working, tested core for each in the prescribed paths; the heavier infra portions are intentionally left as documented follow-ups (each README lists them): live Soroban RPC source, Parquet/SQL + S3/GCS sinks and scheduled workers (#499); on-chain atomic execution + real gas metering (#497); interactive D3.js web dashboard + CI auto-generation (#496). Happy to follow up on any of these.
Closes #496
Closes #497
Closes #499