fix(kitchen): resolve an @& reference whatever the case of the ingredient #323
No reviewers
Labels
No labels
bug
discussion
documentation
duplicate
enhancement
good first issue
help wanted
invalid
question
research
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
gram-lang/gram!323
Loading…
Reference in a new issue
No description provided.
Delete branch "fix/referenceable-case"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
@&flourlooked for an ingredient written earlier by its name as written, so after@Flour{100 g}it raised anUNDEFINED_REFERENCEerror, although the shopping list already merges@Flourand@flour(same registry id).gram formatlowercases ingredient ids, so formatting made the error vanish: a change of meaning, found by the fuzzer (format-preserves-meaning) while checking the pre-release 1.6 work.packages/kitchen/src/processor.ts: the names seen so far are kept by registry id (slug), as everywhere else.referenceable-case.test.ts(2 of 3 tests fail without the fix) andfuzz/regressions/referenceable-case.gram.The fuzz input mixed CR-only line endings into it, but they play no part: the minimal case is
Add @Flour{100 g}.thenMix @&flour..Type of change
Quality checklist
bun run lint:fix)bun run typecheck)bun test)bun run conformance)bun run change)bun run build)