mirror of
https://github.com/GeWuYou/GFramework.git
synced 2026-05-06 16:16:44 +08:00
- 修复 runtime-generator 边界校验对独立与带参数 attribute 的漏报问题,并过滤注释示例误报 - 新增 Python 回归测试覆盖独立、限定名、多 attribute 与文档示例场景 - 更新贡献文档与 ai-plan 记录,移除面向用户文档中的内部治理段落并补充验证结果
2.1 KiB
2.1 KiB
Runtime / Generator Boundary Trace
2026-05-05
RGB-RP-001 Runtime package boundary repair
- Trigger:
- external consumers restoring
GeWuYou.GFramework.Gamefailed because NuGet looked forGFramework.Core.SourceGenerators.Abstractions - repository inspection showed
GFramework.Gamehad a direct project reference to a non-packable generator abstractions project and used[GenerateEnumExtensions]
- external consumers restoring
- 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.Gameremoves the generator abstractions project referenceGFramework.Gameremoves the two unused enum generator attributes- CI and publish workflows run a dedicated boundary validator script
- PR review follow-up:
- verified CodeRabbit and Greptile findings against local source before acting on them
- accepted the validator regex finding because the original pattern missed standalone
[GenerateEnumExtensions]declarations in runtime code - added comment-line filtering after the first regex repair surfaced false positives from XML documentation examples
such as
/// [ContextAware] - rejected the documentation reposition suggestion as stated and removed the
代码生成器边界block fromdocs/zh-CN/contributing.mdbecause it documents internal governance rather than reader-facing contributor guidance - added a Python regression test covering standalone, parameterized, fully qualified, and multi-attribute matches
- Validation milestone:
python3 scripts/test_validate_runtime_generator_boundaries.pypassedpython3 scripts/validate-runtime-generator-boundaries.pypassedpython3 scripts/license-header.py --checkpasseddotnet build GFramework.Game/GFramework.Game.csproj -c Releasepassed with 0 warnings and 0 errors
- Immediate next step:
- push the PR follow-up commit and resolve the remaining review threads