Add minimal identifier escaping#856
Conversation
|
Warning Review limit reached
More reviews will be available in 57 minutes and 37 seconds. Learn how PR review limits work. Your organization has run out of usage credits. Purchase more in the billing tab. ⌛ How to resolve this issue?After more reviews become available, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans include higher PR review limits than trial, open-source, and free plans. In all cases, reviews become available again over time. During sustained high-volume PR review activity, CodeRabbit may temporarily slow when the next review becomes available. Please see our Fair Usage Limits Policy for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (11)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Summary
identifierEscapeTarget: "minimal"soSqlFormattercan remove identifier quotes only when the resulting bare token remains a plain identifier.current_user,current_timestamp,session_user, anduser, plus tokenizer-recognized keywords such aslateral,window, and typed-literal words such asdate.users.current_userto parse as column references.Verification
pnpm --filter rawsql-ts test -- tests/transformers/SqlFormatter.identifier-minimal.test.ts tests/transformers/FormatOptionResolver.test.ts tests/literal.test.ts tests/parsers/FullNameParser.test.tspnpm --filter rawsql-ts testpnpm --filter rawsql-ts lintpnpm --filter rawsql-ts buildpnpm --filter rawsql-ts benchmarkpnpm demo:complex-sqlgit diff --checkpnpm testwas attempted and failed outside this change inpackages/ztd-cli/packages/transfer; the same workspace test failure reproduces onorigin/maininC:\Users\mssgm\CodexApp\rawsql-ts-base-verifydue missing built package entries for@rawsql-ts/testkit-postgres,@rawsql-ts/driver-adapter-core, and related ztd-cli lint failures.Merge Readiness
Tracking issue: not needed; no baseline exception requested.
Scoped checks run: not needed; no baseline exception requested.
Why full baseline is not required: full baseline exception path not used for this PR.
Self Review
Self-review workflow: developer-self-review skill; consistency review and human acceptance review completed after implementation and verification.
Self-review result: no unresolved self-review blockers; tokenizer-dictionary drift found during review was fixed before PR.
Concept-review workflow: package boundary review against
packages/core/AGENTS.mdand DBMS-neutral parser/formatter scope.Concept-review result: no unresolved concept or package-boundary violations; behavior remains parser/formatter-owned and does not branch by dialect.
CLI Surface Migration
No-migration rationale: not selected for this PR.
Upgrade note: not selected for this PR.
Deprecation/removal plan or issue: not selected for this PR.
Docs/help/examples updated: not selected for this PR.
Release/changeset wording: not selected for this PR.
Scaffold Contract Proof
No-proof rationale: not selected for this PR.
Non-edit assertion: not selected for this PR.
Fail-fast input-contract proof: not selected for this PR.
Generated-output viability proof: not selected for this PR.