Repository navigation
Show the code of messages in the editor font and link the lines they name - #193
Open
CatarinaGamboa wants to merge 2 commits into
Open
CatarinaGamboa wants to merge 2 commits into
CatarinaGamboa wants to merge 2 commits into
Conversation
…name The server sends each diagnostic's message notes and the source references of its notes and hints. The panel shows the notes under Found, and renders every message line (headline, notes, hints, declared-here gloss) with the code the verifier marks in backticks in the editor font and each reference, such as `line 134`, as a link that opens that line. Needs a liquidjava-verifier release with liquid-java/liquidjava#528, #530 and #533. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
CatarinaGamboa
added a commit
that referenced
this pull request
Nov 10, 2026
Collaborator
Author
Clean-code reviewI audited this diff with the clean-code-principles checklist. Fixed
Declined
|
Collaborator
Author
Codex review, round 1
That is the unreleased 0.0.38, as stated in the body. Locally, the server tests pass (40) against #533 installed as 0.0.38 in an isolated Maven repository. The loop ends here: nothing to fix. |
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.
Closes #192
Stacked on #191 (base
feat/181-declaration-notes): it renders #191's declared-here gloss, and it needs the same 0.0.38 bump. Retarget this PR tomainbefore #191 is merged with--delete-branch.What changes
Server
LJDiagnosticDTOnow sends two more fields for every diagnostic:messageNotes, fromgetMessageNotes();references, fromgetReferences(), asSourceReferenceDTO(message, text, start, position). The position counts lines and columns from 0, like the other DTO positions.LJDiagnosticAPI. New notes and references therefore show up with no extension change.Panel (Verification tab)
Origin: line 134, …, are shown under Found and the Counterexample. Before this PR the panel did not show notes at all.webview/message-text.ts: the header message, notes, hints and the declared-here gloss.textPreformat).Code.renderparses them: the same run-of-backticks pattern, and one space of padding stripped.line 134,ArrayListRefinements.java:162) is a link that opens that file at that line. It is placed at the reference'sstart; the text is not searched for, as the verifier asks. It reuses the panel's existinglocation-linkhandler.Hover and Problems: unchanged by this PR. See the two options below.
Verifier version
Needs a release (0.0.38 or later) containing liquid-java/liquidjava#528, #530 and #533, on top of #517 and #525 (both on main).
getReferences(),SourceReferenceand the backticks come from #533.I tested against #533's head (
1e94930), installed as 0.0.38 into an isolated Maven repository. Like #191, CI's server build fails until 0.0.38 is on Maven Central.Panel at the study width: before (#191) → after (this PR)
Both use verifier #533, with Hints open. The notes are new, the code is set apart, and
line 134is a link.Clicking
line 134in A1_38 opens line 134,new BufferedInputStream(stream):Panel text of the notes (verifier #533):
A1_09 has no Origin note.
Hover: the two options
VS Code shows a diagnostic's message as plain text. So the diagnostic hover and the Problems view keep the backticks.
proto/192-markdown-hover, not in this PR):HoverProvideradds a markdown block with the notes and the counterexample: code spans, andline 134as a link.Recommendation: A for the study.
Overlap with open PRs
sections.ts: both change the imports at the top.errors.ts(imports, and next to the Expected lines) and instyles.ts(separate rules, so unlikely).LJErrorDTOand the error types intypes/diagnostics.ts; this PR editsLJDiagnosticDTOandBaseDiagnostic.Checks
npm run test:unit(126 passed; the new panel test fails on the base),npm run test:typecheck,npm run lint, servermvn -B test(40 passed, against #533 as 0.0.38; the new converter test fails on the base).🤖 Generated with Claude Code