Skip to content

chore(syntax-cases): mark a disputed form's cases documented only for its positives - #196

Merged
kvlonge merged 3 commits into
mainfrom
fix/syntax-documented-mark
Nov 12, 2026
Merged

kvlonge merged 3 commits into
mainfrom
fix/syntax-documented-mark

Conversation

@kvlonge

@kvlonge kvlonge commented Nov 12, 2026

Copy link
Copy Markdown
Contributor

Why

When Snowflake refused every documented positive of a form, every observed case of the form was marked documented, intended rejections too, so their receipts were never judged. The DCM ENVIRONMENT hand rows also used an identifier where the docs take a bind variable.

Changes

  • In such a form, a case is documented only when its SQL renders one of the form's positives; its intended rejections are judged by their receipts. An empty-clause positive keeps its intent; a mapped case citing a positive stays documented.
  • The DCM ENVIRONMENT rows use ( ? ). Four of six statements then parse and are no longer documented; two still fail at the configuration arguments.
  • Evidence is pinned to 780c1ad3 (account, listing, integration, policy keyword, user and warehouse receipts). 374 not-submitted entries now list a receipted case and are removed; two name quoted listing cases without a receipt.
baseline main sweep only this branch
satisfied obligations 78,535 78,558 78,979
documented cases 769 713 709
parsed cases 26,608 26,608 26,789
refused cases 627 627 631
syntax errors rejected 30,876 30,876 31,075
syntax errors accepted 2,399 2,399 2,519
receipt contradictions 3,402 3,402 3,526
unjudged receipts 36 36 42

"Sweep only" uses main's receipts. None are lost. The parser is unchanged: the added accepted syntax errors are newly receipted cases.

The 56 swept cases in 19 forms: 13 settle reject and the parser agrees, 33 settle reject and the parser accepts, 10 settle accept at the semantic stage. A comment lists them by form.

Verification

  • A test of one disputed form: positives stay documented, rejections settle reject. It fails on the old rule.
  • The generator reproduces the pinned cases exactly.
  • make check-ci and make verify-recorded pass.

… its positives

When Snowflake refuses every documented positive of a form, every
observed case of the form was marked documented, intended rejections
too. That hid real negative evidence: an unquoted reserved word or a
missing operand that Snowflake rejected could never be judged.

A case in such a form is now documented only when it renders one of
the form's positives. Its other cases are judged by their receipts
like any other observed case. An observed rendering keeps the expect
it replaced, so a positive observed for an empty clause still counts
as a positive. Marks are regenerated.
…variable

EXECUTE DCM PROJECT ... ENVIRONMENT takes a bind variable, so the hand
rows use ( ? ) instead of an identifier. Four of the six statements
then parse and fail only on the placeholder source, so they are no
longer documented contradictions and their receipts settle them. The
two that still fail at the configuration arguments stay documented.
…ases

Pins evidence 780c1ad3: the cases regenerated with documented marks
only on positives and with the DCM ENVIRONMENT bind variable, on top of
the syntax receipts for security integrations, Snowpark package lists,
account, external consumer, listing, policy keyword, unnamed user and
warehouse cases. 374 not_submitted entries now list a case with a
receipt and are removed. Two more now name the double-quoted reserved
word listing cases, which still have no receipt. Marks and the syntax
baseline are regenerated.

kvlonge commented Nov 12, 2026

Copy link
Copy Markdown
Contributor Author

Cases the sweep stops marking documented, measured on the previous receipts (56 cases, 19 forms). The one positive of these forms, ALTER SEQUENCE v1 SET ;, stays documented.

form reject, parser agrees reject, parser accepts accept (semantic)
sf.ddl.alter-event-routing-table.set-rule-region-group-regions 0 5 0
sf.ddl.alter-event-routing-table.set-rules-region-group-regions 0 5 0
sf.ddl.alter-listing.listing 0 1 0
sf.ddl.alter-restricted-session-scope.add-as 1 1 2
sf.ddl.alter-restricted-session-scope.remove-as 1 1 2
sf.ddl.alter-sequence.sequence 0 1 0
sf.ddl.alter-table.constraintaction 0 2 0
sf.ddl.alter-tag.unset-data-movement-policy 0 1 0
sf.ddl.create-event-routing-table 0 7 0
sf.ddl.create-procedure.create-procedure 1 1 0
sf.ddl.show-rules-in-event-routing-table 0 1 0
sf.ddl.truncate-materialized-view 0 1 0
sf.functions.get-path.colon.syntax 2 1 0
sf.security_admin.alter-organization-account.set-password-session-policy 0 1 0
sf.security_admin.alter-organization-account.set-tag 2 1 2
sf.security_admin.alter-organization-account.unset-password-session-policy 0 0 2
sf.security_admin.alter-organization-account.unset-tag 0 1 1
sf.security_admin.alter-security-integration-saml2.refresh 0 1 0
sf.utility.execute-dbt-project.project-2 6 1 1

Every case:

  • sf.ddl.alter-event-routing-table.set-rule-region-group-regions
    • k40064d130d59 negative_neighbour: settled reject, parser accepts
    • k50943d5046db identifier_class: settled reject, parser accepts
    • k73a54f0de89b identifier_class: settled reject, parser accepts
    • k86a2812ae304 identifier_class: settled reject, parser accepts
    • kb8992b67b5b1 negative_neighbour: settled reject, parser accepts
  • sf.ddl.alter-event-routing-table.set-rules-region-group-regions
    • k0bd2bb36daba identifier_class: settled reject, parser accepts
    • k372ec8f0872a negative_neighbour: settled reject, parser accepts
    • k496e15db9da8 identifier_class: settled reject, parser accepts
    • k676ab4b2f8db negative_neighbour: settled reject, parser accepts
    • kdf3d7530e2a1 identifier_class: settled reject, parser accepts
  • sf.ddl.alter-listing.listing
    • kc36cdea7f8bf identifier_class: settled reject, parser accepts
  • sf.ddl.alter-restricted-session-scope.add-as
    • k00ba4acdeaef negative_neighbour: settled accept (semantic), satisfied
    • ka24cd1d6ee49 required_operand_missing: settled accept (semantic), satisfied
    • ka56c238e791f negative_neighbour: settled reject, parser agrees
    • kc3d5517ba3c6 identifier_class: settled reject, parser accepts
  • sf.ddl.alter-restricted-session-scope.remove-as
    • k276538aafb23 required_operand_missing: settled accept (semantic), satisfied
    • k30b359e569e1 negative_neighbour: settled reject, parser agrees
    • k56a66cfddb5a negative_neighbour: settled accept (semantic), satisfied
    • k609d77a7b2ce identifier_class: settled reject, parser accepts
  • sf.ddl.alter-sequence.sequence
    • kaded8b547206 identifier_class: settled reject, parser accepts
  • sf.ddl.alter-table.constraintaction
    • k32a148f042dd identifier_class: settled reject, parser accepts
    • k69e2f256f86d identifier_class: settled reject, parser accepts
  • sf.ddl.alter-tag.unset-data-movement-policy
    • k7152734c3ffe identifier_class: settled reject, parser accepts
  • sf.ddl.create-event-routing-table
    • k0888119cdec9 identifier_class: settled reject, parser accepts
    • k0ff480e35bd7 negative_neighbour: settled reject, parser accepts
    • k13c14eaf0378 identifier_class: settled reject, parser accepts
    • k57b51d9a7b40 identifier_class: settled reject, parser accepts
    • kacbadf684923 required_operand_missing: settled reject, parser accepts
    • kde33f16151bc required_operand_missing: settled reject, parser accepts
    • kf1ca890f9788 negative_neighbour: settled reject, parser accepts
  • sf.ddl.create-procedure.create-procedure
    • k3c8bdc84d11b negative_neighbour: settled reject, parser agrees
    • k8eb3cab5cf7b identifier_class: settled reject, parser accepts
  • sf.ddl.show-rules-in-event-routing-table
    • kaa719365c2e3 identifier_class: settled reject, parser accepts
  • sf.ddl.truncate-materialized-view
    • k1997c93fb53d identifier_class: settled reject, parser accepts
  • sf.functions.get-path.colon.syntax
    • k92da4d7f7c29 identifier_class: settled reject, parser accepts
    • kaedd7ab98c36 negative_neighbour: settled reject, parser agrees
    • keae9d348bd95 negative_neighbour: settled reject, parser agrees
  • sf.security_admin.alter-organization-account.set-password-session-policy
    • k95164778c741 identifier_class: settled reject, parser accepts
  • sf.security_admin.alter-organization-account.set-tag
    • k49db490a2fef identifier_class: settled reject, parser accepts
    • k4f4f186d5ce8 negative_neighbour: settled reject, parser agrees
    • k965913368318 negative_neighbour: settled accept (semantic), satisfied
    • kd7ff58e98953 boundary_above: settled reject, parser agrees
    • ke4f67d4d8253 required_operand_missing: settled accept (semantic), satisfied
  • sf.security_admin.alter-organization-account.unset-password-session-policy
    • k2bb9a0c93ea1 negative_neighbour: settled accept (semantic), satisfied
    • k53e02403e223 negative_neighbour: settled accept (semantic), satisfied
  • sf.security_admin.alter-organization-account.unset-tag
    • kb532e5e75bbe required_operand_missing: settled accept (semantic), satisfied
    • ke3b1a8f67c2a identifier_class: settled reject, parser accepts
  • sf.security_admin.alter-security-integration-saml2.refresh
    • k951e0a4c7acc identifier_class: settled reject, parser accepts
  • sf.utility.execute-dbt-project.project-2
    • k050a81e5ed9c negative_neighbour: settled reject, parser agrees
    • k1ddbb9b9bfab negative_neighbour: settled reject, parser agrees
    • k2c549bba9d13 identifier_class: settled reject, parser accepts
    • k775fc575cd57 required_operand_missing: settled reject, parser agrees
    • k7c00fe064dd8 negative_neighbour: settled accept (semantic), satisfied
    • k85d060a46637 negative_neighbour: settled reject, parser agrees
    • k9a39d3b2c6f2 negative_neighbour: settled reject, parser agrees
    • kafca97afd0d8 negative_neighbour: settled reject, parser agrees

@kvlonge
kvlonge added this pull request to the merge queue Nov 12, 2026
Merged via the queue into main with commit acec2bc Nov 12, 2026
13 checks passed
@kvlonge
kvlonge deleted the fix/syntax-documented-mark branch November 12, 2026 09:32
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.

1 participant