Child of #386, M1.
What does not work
src/choudoufu-member.ts's hasLiveBlock is the choudoufu member's probe (choudoufuSpec.probe, src/choudoufu-live.ts): a regex ^\s*live\s*\{ over the root's *.tf files. choudoufu's leading declaration is now the sidecar:
# estate.chdf.hcl
estate = "prod-networking"
record_store "ssm" {
key_prefix = "tofu-records/prod-networking"
}
(choudoufu site/content/docs/use/reference.md, "Two places to write it, one dialect"; the live block inside terraform {} remains supported, both at once is an error.) Every tools/estate-gen cohort and every migrated terralith uses the sidecar. Rendered the s3 cohort and ran behold doctor on it: "no chant.config.ts here, and no estate members declared". memberKindOf returns undefined for it.
What to build
- The probe accepts either form:
estate.chdf.hcl present in the directory, or a root *.tf with a live { block. Rename to what it now means (isChoudoufuEstate or similar); update the call sites that import hasLiveBlock (src/choudoufu-live.ts, src/server.ts) and the expects text: "an estate.chdf.hcl sidecar or a live { estate = … } block in a root *.tf file".
- The doctor line and AGENTS.md's "Adding a member kind" example (
a regex over a root file) and the choudoufu member's own doc comments say sidecar first.
- No
-estate flag anywhere: choudoufu reads the sidecar itself, and -estate beside a declaration is refused (src/choudoufu-live.ts header).
Definition of done
src/project.test.ts (the probe and the object form) and src/choudoufu-member.test.ts cover: sidecar only, live block only, both absent, a .tf mentioning live { in a comment is NOT a false positive only if it already was not (keep the current regex behaviour, do not widen it).
behold doctor on a directory holding only estate.chdf.hcl and *.tf reports the choudoufu member, not "no chant.config.ts".
just check green.
Child of #386, M1.
What does not work
src/choudoufu-member.ts'shasLiveBlockis the choudoufu member's probe (choudoufuSpec.probe, src/choudoufu-live.ts): a regex^\s*live\s*\{over the root's*.tffiles. choudoufu's leading declaration is now the sidecar:(choudoufu
site/content/docs/use/reference.md, "Two places to write it, one dialect"; theliveblock insideterraform {}remains supported, both at once is an error.) Everytools/estate-gencohort and every migrated terralith uses the sidecar. Rendered the s3 cohort and ranbehold doctoron it: "no chant.config.ts here, and no estate members declared".memberKindOfreturns undefined for it.What to build
estate.chdf.hclpresent in the directory, or a root*.tfwith alive {block. Rename to what it now means (isChoudoufuEstateor similar); update the call sites that importhasLiveBlock(src/choudoufu-live.ts, src/server.ts) and theexpectstext: "anestate.chdf.hclsidecar or alive { estate = … }block in a root *.tf file".a regex over a root file) and the choudoufu member's own doc comments say sidecar first.-estateflag anywhere: choudoufu reads the sidecar itself, and-estatebeside a declaration is refused (src/choudoufu-live.ts header).Definition of done
src/project.test.ts(the probe and the object form) andsrc/choudoufu-member.test.tscover: sidecar only, live block only, both absent, a.tfmentioninglive {in a comment is NOT a false positive only if it already was not (keep the current regex behaviour, do not widen it).behold doctoron a directory holding onlyestate.chdf.hcland*.tfreports the choudoufu member, not "no chant.config.ts".just checkgreen.