Lambe 0.7.1#5
Merged
Merged
Conversation
Error messages, REPL prompts, MCP responses, and playground
suggestions now display the intent-level `as(csv)` form instead of
the raw `to_entries` / `{items: .}` fragment. The template that
runs is unchanged, so every surface tells the same 0.6.0 shape
story: `as(<format>)` bridges shape mismatches inside the query
language.
- lib/src/shape/check.dart: Remediation gains a `withDisplay`
factory that decouples display from the runtime template. The
four curated remediations become format-parameterized factories
(`_toEntriesAsRows(fmt)`, `_wrapItems(fmt)`, etc.) that emit
`display: 'as(<fmt>)'` while the template still points at the
raw AST. The explanation names the underlying mechanism for
transparency.
- test/shape_check_test.dart, test/apply_surfaces_test.dart:
assertions updated to the new display form. 962 tests pass.
- README.md: the two opening error-message examples updated to
reflect the new display; added a line about the explanation
naming the raw fragment.
- doc/lam.1.md / doc/lam.1: source bumped to Lambë 0.7.1.
- doc/getting-started.md: REPL banner v0.7.0 → v0.7.1, pubspec
example updated.
- CHANGELOG.md: new 0.7.1 entry (Changed + Why sections).
No breaking API changes; Remediation.new still sets
display = source (default behaviour unchanged), and the template
AST continues to be the raw fragment so applyBridge() consumers
are unaffected.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
UX polish on top of 0.7.0. Remediation suggestions now surface the intent-level
as(<format>)form in every bridge-offering surface (CLI errors, REPL, MCP, playground) instead of the rawto_entries/{items: .}fragment. The template that runs is unchanged, so composed queries produce identical output.Changed
as(<format>)in error suggestions.$ lam --to csv '.deps' file.yamlnow saysTry appending | as(csv)with an explanation that names the underlying mechanism (to_entries) for transparency.Remediation.displayandRemediation.templatedecouple. NewRemediation.withDisplay()factory lets display text differ from the runtime AST's source.Remediation()unchanged.Test plan
shape_check_test.dartandapply_surfaces_test.dartto reflect the new display)dart analyze --fatal-infos: cleandart format --set-exit-if-changed .: cleandart doc --dry-run: 0 warnings, 0 errorsdart pub publish --dry-run: 0 warningspana: 160/160lam --to csv .dependencies pubspec.yamlprints the new| as(csv)suggestionlam --to csv '.dependencies | as(csv)' pubspec.yamlstill produces correct outputv0.7.1anddart pub publishafter mergeNot breaking
Remediation()constructor unchanged (still setsdisplay = source).Remediation.templatestill the raw AST, soapplyBridge()consumers see no change.Docs
README.md: opening example and Shape-aware-output example updated to show new display form; added one line about the explanation naming the raw fragment for transparency.CHANGELOG.md: new 0.7.1 entry.ROADMAP.md: 0.7.1 added to shipped section.doc/lam.1.md,doc/lam.1,doc/getting-started.md: version bumps.