AST version migrations
Introduces a registry of pure, chained migration functions that upgrade old ASTs (for example v1 to v2 to v3) when operators are renamed or node shapes change. Bookmarks, saved views and stored queries keep working across library upgrades.
Planned. This page shows the specification from issue #182. The live example, source for every framework and the API reference replace it when the feature ships.
Live example
A version picker with sample v1, v2 and v3 ASTs and a migration log panel.
Expected behavior
Migrating v1 runs v1→v2 and then v2→v3. Each step's diff is displayed. The final AST validates against the current schema.
Planned API surface
migrateQuery()registerMigration()currentAstVersionMigrationReportMIGRATION_MISSINGAcceptance criteria
- Migrations are pure functions and do not mutate their input (pending)
- Chains run in strict ascending order with no skipped versions (pending)
- A missing step yields MIGRATION_MISSING, never a partial result (pending)
- Each built-in migration ships with before and after fixtures (pending)