MSSQL spike: check dependencies (mssql, node-sql-parser, antlr4, T-SQL grammar) #311

Closed
opened 2026-11-10 08:17:17 +00:00 by david · 1 comment
Owner

Summary

Check the new npm dependencies and the ANTLR T-SQL grammar before any code is written, and record the findings in a spike note.

Background

The MSSQL pi extension (extensions/mssql/) will use the mssql driver (built on tedious) and one of two T-SQL parsers as its only write block: node-sql-parser (transactsql dialect) or the ANTLR4 T-SQL grammar from antlr/grammars-v4 with the antlr4 JS runtime. New dependencies must be vetted first ([BEST PRACTICE]; supply-chain risk). This is Stage 0 and has no code. Its output feeds the Stage 1 spike result.

Documentation Required

Reference docs are vendored under the folders below (already on main). Read them before starting; if a folder is missing on your branch, fetch the source URLs.

Implementation Details

Create extensions/mssql/spike/dependency-check.md (create the spike/ directory if absent). For each of mssql, node-sql-parser and antlr4, record: current npm version (npm view <pkg> version), licence, known advisories (npm audit on a scratch install, plus GitHub advisories), last-release date and maintenance state. For the T-SQL grammar, confirm sql/tsql/ exists in antlr/grammars-v4 and has a JavaScript or TypeScript target (check the grammar for Java-specific actions that would need removal), and record the grammar file sizes. Do not edit the root package.json in this step. Do not add code.

Acceptance Criteria

  • extensions/mssql/spike/dependency-check.md exists.
  • It lists version, licence, advisories and maintenance state for mssql, node-sql-parser and antlr4.
  • It states whether the ANTLR4 T-SQL grammar exists with a JS/TS target, and notes any Java-only actions.
  • It records any blocker or advisory explicitly (or states "none found" with the date checked).
  • No package.json change and no code is added.

Test Plan

Open the note and confirm each dependency row is filled and dated. Re-run npm view <pkg> version license for each package and confirm the values match.

## Summary Check the new npm dependencies and the ANTLR T-SQL grammar before any code is written, and record the findings in a spike note. ## Background The MSSQL pi extension (`extensions/mssql/`) will use the `mssql` driver (built on `tedious`) and one of two T-SQL parsers as its only write block: `node-sql-parser` (`transactsql` dialect) or the ANTLR4 T-SQL grammar from `antlr/grammars-v4` with the `antlr4` JS runtime. New dependencies must be vetted first ([BEST PRACTICE]; supply-chain risk). This is Stage 0 and has no code. Its output feeds the Stage 1 spike result. ## Documentation Required Reference docs are vendored under the folders below (already on `main`). Read them before starting; if a folder is missing on your branch, fetch the source URLs. - `docs/reference/mssql/` — https://raw.githubusercontent.com/tediousjs/node-mssql/master/README.md : driver API: pool config, stream mode, `request.cancel()`, parameters. - `docs/reference/node-sql-parser/` — https://raw.githubusercontent.com/taozhi8833998/node-sql-parser/master/README.md : `transactsql` dialect and `astify` usage. - `docs/reference/antlr4/` — https://raw.githubusercontent.com/antlr/antlr4/dev/doc/javascript-target.md : ANTLR4 JavaScript target and runtime. - `docs/reference/grammars-v4-tsql/` — https://raw.githubusercontent.com/antlr/grammars-v4/master/sql/tsql/README.md : notes for the T-SQL grammar in grammars-v4. ## Implementation Details Create `extensions/mssql/spike/dependency-check.md` (create the `spike/` directory if absent). For each of `mssql`, `node-sql-parser` and `antlr4`, record: current npm version (`npm view <pkg> version`), licence, known advisories (`npm audit` on a scratch install, plus GitHub advisories), last-release date and maintenance state. For the T-SQL grammar, confirm `sql/tsql/` exists in `antlr/grammars-v4` and has a JavaScript or TypeScript target (check the grammar for Java-specific actions that would need removal), and record the grammar file sizes. Do not edit the root `package.json` in this step. Do not add code. ## Acceptance Criteria - [ ] `extensions/mssql/spike/dependency-check.md` exists. - [ ] It lists version, licence, advisories and maintenance state for `mssql`, `node-sql-parser` and `antlr4`. - [ ] It states whether the ANTLR4 T-SQL grammar exists with a JS/TS target, and notes any Java-only actions. - [ ] It records any blocker or advisory explicitly (or states "none found" with the date checked). - [ ] No `package.json` change and no code is added. ## Test Plan Open the note and confirm each dependency row is filled and dated. Re-run `npm view <pkg> version license` for each package and confirm the values match.
david closed this issue 2026-11-10 22:24:13 +00:00
Author
Owner

pi-loop opened and merged a pull request for this issue: #334

pi-loop opened and merged a pull request for this issue: https://git.excelera.net/david/pi-extensions-and-skills/pulls/334
Sign in to join this conversation.
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
david/pi-extensions-and-skills#311
No description provided.