refactor(server): drop dead snapshotAll; quote identifiers in trigger DDL#13
Merged
Merged
Conversation
… DDL `snapshotAll` had zero callers in src/ or tests/ and was never exported from src/server/index.ts — deleting it removes an unquoted table-name interpolation that modelled the wrong habit. `installTriggers` now double-quotes every identifier position (trigger name, table name, pk column) for consistency with sql-compiler.ts and ensureTriggers' existing DROP. The regex gate (assertValidCollection) remains the real safety net; quoting just makes the helper safe even if a future caller bypasses the registry. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This was referenced Jun 13, 2026
Merged
grrowl
added a commit
that referenced
this pull request
Jun 13, 2026
Bug-fix batch from the deep-audit follow-up (audit-excluded SSR topic aside): client reconnect-wedge fix (#12), wire-input hardening + error sanitization (#15, ADR-0012), catch-up N+1 batching (#14), plus expanded error/wire test coverage (#11) and dead-code/identifier-quoting cleanup (#13). Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
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.
Lands plan-006 on main (0.3.2 patch).
snapshotAll— zero callers in src/ or tests/, not exported; superseded bycompileSubsetQueryinhandleSuband never removed.installTriggers' CREATE TRIGGER DDL (table/pk), matching the discipline the rest of the codebase already follows. Safe today (identifiers are regex-validated at registration), but makes the helper robust if a future caller bypasses the registry.Identifier values stay bound/single-quoted; the regex remains the real gate.
sqlite_masterstores the same unquoted name either way, soensureTriggers' orphan-reaping set-diff is unaffected.No new tests: deletion proven by grep+typecheck; quoting fully pinned by the existing trigger suites (cdc/compaction/schema-evolution/ensure-triggers). Validated on main: typecheck + full suite (153 passed) + build green. Supersedes feat/ssr PR #7.
🤖 Generated with Claude Code