Skip to content

[Types] spring-split - #7290

Closed
keithharvey wants to merge 4 commits into
beyond-all-reason:fmtfrom
keithharvey:mig-spring-split
Closed

[Types] spring-split#7290
keithharvey wants to merge 4 commits into
beyond-all-reason:fmtfrom
keithharvey:mig-spring-split

Conversation

@keithharvey

@keithharvey keithharvey commented Mar 31, 2026

Copy link
Copy Markdown
Collaborator

Part of BAR type-error cleanup. Rebuilds idempotently from master via just bar::fmt-mig-generate.

What it does: Splits the monolithic Spring table into Engine.Synced / Engine.Unsynced / Engine.Shared, rewriting each Spring.X to the bucket that actually declares X per the generated API stubs — so synced/unsynced-only calls type-check in the right context.

# spring-split - split Spring into Engine.Synced, Engine.Unsynced, and Engine.Shared
bar-lua-codemod spring-split --path "$BAR_DIR" --library "$BAR_DIR/recoil-lua-library/src" --exclude common/luaUtilities

See RecoilEngine#2799 for the Engine.Synced/Engine.Unsynced/Engine.Shared type split on the engine side.

Branch Topology

All branches in the BAR type-error cleanup stack. Regenerated deterministically by just bar::fmt-mig-generate. Generated 2026-06-11 10:24:54 UTC.

Leaves — each targets master, mergeable independently:

Branch Command Diff vs parent Units
fmt stylua 1450 files, +183025 −187662 ✅ pass
mig-bracket bar-lua-codemod bracket-to-dot 342 files, +7653 −7653 ✅ pass
mig-rename-aliases bar-lua-codemod rename-aliases 173 files, +362 −362 ✅ pass
mig-detach-bar-modules bar-lua-codemod detach-bar-modules 178 files, +1694 −1562 ✅ pass
mig-i18n bar-lua-codemod i18n-kikito 20 files, +121 −1198 ✅ pass
mig-spring-split bar-lua-codemod spring-split 782 files, +10019 −10010 ✅ pass
mig-integration-tests <hand curated> 22 files, +140 −90 ✅ pass
mig-busted-types <hand curated> 12 files, +1501 −0 ✅ pass

Rollups — composite branches stacking the leaves and (for fmt-llm) the env + LLM layers:

Branch Diff vs master Diff vs parent Units
mig 1480 files, +193205 −197222 897 files, +21353 −20733 ✅ pass
fmt-llm-source 1486 files, +193710 −197492 55 files, +575 −340 ✅ pass
fmt-llm 1487 files, +193804 −197514 51 files, +117 −45 ✅ pass

@github-actions

github-actions Bot commented Mar 31, 2026

Copy link
Copy Markdown
Contributor

Integration Test Results

0 tests   0 ✅  0s ⏱️
0 suites  0 💤
0 files    0 ❌

Results for commit 5873f39.

♻️ This comment has been updated with latest results.

…ring

Renames spec/builders/{spring->engine}_{,un}synced_builder.lua + their
builder_specs, Builders.Spring->Builders.EngineSynced,
Builders.SpringUnsynced->Builders.EngineUnsynced, @Class names, and all
call sites. The renamed builders own every Engine-related test edit so no
two prereqs touch one file:
  - engine_synced_builder.lua: gamedata/system.lua defs mock aliases
    Engine.{Shared,Synced,Unsynced} + BAR to the _G.Spring/_G.BAR mocks
  - engine_unsynced_builder.lua: widget sandbox gets env.Engine; capture
    spies install on Engine.Shared.*
Prefix branch -> lands in fmt once, every leaf+mig inherits it.
- spec_helper.lua: Engine.{Synced,Unsynced,Shared} proxy to the current
  _G.Spring mock (metatable, resolved per access) so global/gadget code and
  tests that swap _G.Spring resolve correctly.
- spring_unsynced_builder.lua: inject env.Engine into the widget sandbox
  (widgets call Engine.Shared.X after spring-split); capture spies install on
  Engine.Shared.* to match.
@keithharvey

Copy link
Copy Markdown
Collaborator Author

Closing: the spring-split transform was dropped from the fmt-mig pipeline (BAR-Devtools d12b5b9) — it needs the generated recoil-lua-library and was holding up a clean merge. The migration stack proceeds without it; see the tracking issue #7408 for the current topology.

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