docs: correct completion caret and result ranges by dajiaohuang · Pull Request #496 · DTStack/dt-sql-parser · GitHub
Skip to content

docs: correct completion caret and result ranges - #496

Open
dajiaohuang wants to merge 1 commit into
DTStack:mainfrom
dajiaohuang:docs/completion-caret-ranges-20261021
Open

dajiaohuang wants to merge 1 commit into
DTStack:mainfrom
dajiaohuang:docs/completion-caret-ranges-20261021

Conversation

@dajiaohuang

Copy link
Copy Markdown

The English and Chinese README examples disagree with the current public FlinkSQL API:

  • The CREATE completion example uses column 16 for a seven-character string, returning null; use sql.length + 1 to obtain the listed keywords.
  • The English completion introduction names getAllEntities instead of getSuggestionAtCaretPosition.
  • WordRange output uses endIndex / endColumn, with the shown tb range ending at column 17.
  • Statement slices have exclusive end columns 13 and 18 for the two shown statements.

Only the two README files change. Parser implementations, grammars and generated files are unchanged.

Validation on Linux, Node 20.19.5 and pnpm 9.7.0 with the frozen lockfile:

  • Real FlinkSQL API output compared with the examples: nine original document-contract mismatches, zero after correction.
  • pnpm prettier-check, pnpm check-types, pnpm antlr4 --all --check, and pnpm build passed on the unchanged implementation.
  • pnpm run test --runInBand: 224 suites / 6,523 tests passed on that same implementation.
  • Pre-commit formatting and commitlint hooks passed; exact reviewed README contents and git diff --check verified.

Node 18 and hosted CI were not run locally.

@liuxy0551

Copy link
Copy Markdown
Collaborator

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants