-
Notifications
You must be signed in to change notification settings - Fork 3
fix(game): 剥离运行时模块对生成器依赖 #324
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from 1 commit
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
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
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
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
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
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
40 changes: 40 additions & 0 deletions
40
.../public/runtime-generator-boundary/todos/runtime-generator-boundary-tracking.md
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,40 @@ | ||
| # Runtime / Generator Boundary Tracking | ||
|
|
||
| ## Goal | ||
|
|
||
| Keep runtime, abstractions, and meta-package modules free from source-generator project references, source-generator | ||
| attributes, and leaked NuGet dependencies. | ||
|
|
||
| ## Current Recovery Point | ||
|
|
||
| - Recovery point: RGB-RP-001 | ||
| - Phase: remove `GFramework.Game` generator coupling and add repository guardrails | ||
| - Focus: | ||
| - delete `GFramework.Game`'s dependency on `GFramework.Core.SourceGenerators.Abstractions` | ||
| - remove unused `[GenerateEnumExtensions]` usage from `GFramework.Game` | ||
| - add static and packed-package validation so runtime packages cannot regress | ||
|
|
||
| ## Active Risks | ||
|
|
||
| - A runtime package can still compile locally if it references a non-packable generator helper project, so regressions are | ||
| easy to miss without an explicit guard. | ||
| - A leaked package dependency may only surface when a consumer restores from NuGet, not during normal repository builds. | ||
|
|
||
| ## Completed In This Stage | ||
|
|
||
| - Confirmed `GFramework.Game` was the direct runtime offender and `GeWuYou.GFramework.Game` leaked | ||
| `GFramework.Core.SourceGenerators.Abstractions` into its nuspec dependency graph. | ||
| - Confirmed the two `[GenerateEnumExtensions]` usages inside `GFramework.Game` do not need generated output and can be | ||
| removed outright. | ||
|
|
||
| ## Validation Target | ||
|
|
||
| - `python3 scripts/validate-runtime-generator-boundaries.py` | ||
| - `dotnet build GFramework.Game/GFramework.Game.csproj -c Release` | ||
| - `dotnet build GFramework.Godot/GFramework.Godot.csproj -c Release` | ||
| - `dotnet pack GFramework.sln -c Release -p:PackageVersion=<local>` | ||
|
|
||
| ## Next Recommended Resume Step | ||
|
|
||
| Run the new boundary validator plus minimal Release build and pack validation, then inspect `GeWuYou.GFramework.Game` | ||
| and transitive runtime packages to confirm no `SourceGenerators` dependency remains. |
21 changes: 21 additions & 0 deletions
21
...an/public/runtime-generator-boundary/traces/runtime-generator-boundary-trace.md
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,21 @@ | ||
| # Runtime / Generator Boundary Trace | ||
|
|
||
| ## 2026-05-05 | ||
|
|
||
| ### RGB-RP-001 Runtime package boundary repair | ||
|
|
||
| - Trigger: | ||
| - external consumers restoring `GeWuYou.GFramework.Game` failed because NuGet looked for | ||
| `GFramework.Core.SourceGenerators.Abstractions` | ||
| - repository inspection showed `GFramework.Game` had a direct project reference to a non-packable generator | ||
| abstractions project and used `[GenerateEnumExtensions]` | ||
| - Decisions: | ||
| - treat the issue as a runtime/generator boundary violation, not as a missing publish target | ||
| - remove the runtime-side attribute usage instead of turning generator abstractions into public runtime packages | ||
| - add repository guardrails at both source-validation time and packed-package validation time | ||
| - Expected implementation: | ||
| - `GFramework.Game` removes the generator abstractions project reference | ||
| - `GFramework.Game` removes the two unused enum generator attributes | ||
| - CI and publish workflows run a dedicated boundary validator script | ||
| - Immediate next step: | ||
| - complete implementation and run Release build plus pack verification |
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
Oops, something went wrong.
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.