Add pos supervisor#64
Open
Slashek wants to merge 11 commits into
Open
Conversation
This commit introduces a new test suite for the _canonicalUri function, ensuring its behavior aligns with expected properties such as idempotency, proper handling of Windows drive letters, and tolerance for non-URI strings. The tests cover various scenarios, including empty input, backslash handling, and percent-decoded path segments, to maintain robustness and prevent regressions.
…SP checks and adding warm-up for LSP initialization
…ogic; add unit tests for argument parsing and directory resolution
- Is registered as the single MCP tool over stdio; the bin boots and advertises it.
- Validates input against the zod schema: file_path (string), content (string), mode (full|quick, optional).
- Logs the call to stderr, then returns a well-formed but empty ValidateCodeResult:
- status: 'ok', must_fix_before_write: false
- errors: [], warnings: [], infos: [], proposed_fixes: [], clusters: [], scorecard: []
- next_step: 'Stub handler — real validation lands in TASK-7.10.'
- parse_error: null, tips: [], domain_guide: null, structural: null
- Serializes that as one JSON text block in the MCP content envelope.
It does not lint, parse, enrich, or look at the project — the same response comes back regardless of content.
Replace the stub handler with real linting. validate_code now resolves the
file path, lints the buffer through the check-node lintBuffer seam (check()
with the buffer overlaid on the on-disk project — no LSP, no subprocess),
maps each Offense to a ValidateCodeDiagnostic (0-based -> 1-based line and
column), and buckets results into errors/warnings/infos with a status +
must_fix_before_write gate.
Lint-only slice: enrichment (hints/confidence/fix translation), advisories,
clustering, scorecard, tips, domain_guide and structural are intentionally
deferred (left empty/null); mode is a no-op for now.
- lint/lint.ts: runLint() + Offense -> diagnostic mapping
- result/assemble.ts: pure bucketing + status/must_fix derivation
- transport/validate-code.ts: handler wired to runLint -> assembleResult
- tests: assemble (pure, 5), lint adapter (temp project, 3), stdio smoke
asserts real diagnostics end to end (3); package suite 31/31, guards 12/12
Refs TASK-7.6, TASK-7.9, TASK-7.10.
docs/mcp-supervisor/salvage/ (139 files, ~956K) was ~68% of the branch diff. Untrack it and add it to .gitignore to keep PRs reviewable. Files remain on disk and are recoverable from history at 69aa9e4 (git checkout 69aa9e4 -- docs/mcp-supervisor/salvage). TASK-7.11 and TASK-8.5 carry recovery notes for restoring the fixtures and parity baselines into the package test tree.
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.
No description provided.