Skip to content

feat: make init.jsonc canonical and nudge config drift#966

Merged
huangzesen merged 3 commits into
mainfrom
feat/nudge-migration-prompts-livebase-20260716
Jul 17, 2026
Merged

feat: make init.jsonc canonical and nudge config drift#966
huangzesen merged 3 commits into
mainfrom
feat/nudge-migration-prompts-livebase-20260716

Conversation

@huangzesen

@huangzesen huangzesen commented Jul 16, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • make kernel-owned src/lingtai/init.jsonc the single canonical config-shape source, with explicit canonical/current shapes plus read-only compatibility shapes
  • route boot and refresh through one real typed reader with FULLY_EFFECTIVE, READ_OK_WITH_IGNORED_FIELDS, and READ_FAILED outcomes, including safe effective/failure details
  • compare local init.json against the canonical/compatibility layers and emit a typed init_config_shape Nudge; never rewrite or migrate the file automatically
  • apply the shared global Nudge controls LINGTAI_NUDGE_ENABLED and LINGTAI_NUDGE_REPEAT_INTERVAL to all Nudge kinds
  • add the complete environment-variable catalogue and mechanically enforce bidirectional links with every source-derived owning ANATOMY.md
  • keep compatibility rationale/retirement conditions in adjacent Contracts and use Git—not a runtime migration registry—as history

Behavior contract

  • canonical shape: accepted for current use and new writes
  • compatibility-only shape: accepted for reading and reported as a Nudge
  • canonical/compatibility conflict: blocked and reported
  • unknown/failure: fail closed with repair context and effective fallback when available
  • dismissal acknowledges a Nudge; rerunning the same real reader with zero findings resolves it
  • no code in this PR mechanically edits init.json

Validation

  • fresh exact-head checkout at ffda3739d457df4b5a43c425ac4299364acb4593
  • GitHub Native Windows / PowerShell 7: success
  • candidate-focused suite: 327 passed; the two remaining failures were classified independently:
    • the vision expectation reproduces unchanged on exact live base a3f172ff571c39792ae219b76611e38feb673de4
    • the preset test passes when the intentionally isolated test HOME is replaced with the normal authenticated HOME
  • decisive reader/schema/Nudge/environment-catalogue suite: 125 passed
  • combined local integration suite before the final documentation follow-up: 811 passed, 2 known baseline deselections
  • changed-module py_compile: PASS
  • git diff --check: PASS
  • final checkout remained clean
  • prior independent Terra review and explicit Claude Opus 4.8 exact-candidate review completed

Scope

This PR owns the kernel reader, canonical shape source, Nudge semantics/policy, prompt/manual guidance, Contracts, Anatomies, and regression gates. The TUI's byte-identical projection and retirement of TUI/Portal runtime migration callers remain in the separate TUI PR.

It does not automatically modify user config, release, deploy, publish, or delete user data.

@huangzesen huangzesen changed the title feat: add typed migration nudge prompts feat: make init.jsonc canonical and nudge config drift Jul 17, 2026
@huangzesen
huangzesen merged commit bf3b972 into main Jul 17, 2026
1 check 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