Skip to content

Remove accidental Lake and Lean imports from generated challenges - #668

Merged
kim-em merged 1 commit into
mainfrom
weird-imports
Nov 1, 2026
Merged

kim-em merged 1 commit into
mainfrom
weird-imports

Conversation

@kim-em

@kim-em kim-em commented Nov 1, 2026 •

Copy link
Copy Markdown
Collaborator

Generated challenges explicitly imported Lake.Toml, Lake.Util.Message, and Lean because EvalTools.Markers exposed those implementation dependencies. This broke consumers that reuse challenges, including Comparator's finite graph Ramsey preset.

Source modules still receive these implementation dependencies transitively through the marker implementation; the standalone generated headers now omit them.

Keep the compatibility marker module limited to LeanEvalGenerator.Core.Markers, which the generator already omits, and regenerate all 312 workspaces. This removes the accidental imports from 499 files across 307 workspaces. Add regression checks for marker-only modules and the narrow Ramsey import header. Rename an implicitly used commuting-probability binder to clear an existing linter warning in its generated solution wrapper.

Validation:

  • All 137 generator unit tests pass.
  • All 307 affected workspaces compile with warnings treated as errors, excluding intentional sorry holes; the commuting-probability wrapper also passes after the binder fix.
  • Full source compilation and declaration inventory validation pass.
  • For the two Init-only workspaces, source/generated statements, 172 declaration types, and 68 definition values are definitionally equal.
  • All regenerated Lean files match the compiled snapshot; generated catalog validation and git diff --check pass.

@kim-em
kim-em merged commit 85a88c3 into main Nov 1, 2026
13 checks passed
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