Skip to content

catalog: guarantee scopes - #3

Merged
Kinflou merged 1 commit into
mainfrom
guarantee-scopes
Nov 9, 2026
Merged

Kinflou merged 1 commit into
mainfrom
guarantee-scopes

Conversation

@Kinflou

@Kinflou Kinflou commented Nov 9, 2026

Copy link
Copy Markdown
Member

Adds guarantee scopes to the catalog, for the granular @unverified proposal (docs#162): where a marker acknowledging a guarantee may sit, following from where its cause is.

Guarantee Comes from Scopes
schema_agreement, encoding_agreement handshake package, protocol
version_honesty policy package, protocol
encoding_conformance encoding package, protocol
bounded_size type protocol, function, argument, field, type
  • Schema: #Scopes/#Scope (package, protocol, function, argument, field, type, outermost to innermost) and a required non-empty scopes on #Guarantee. Two catalog checks in the style of the existing ones: scopes are in vocabulary order with no duplicates, and they follow the origin (a type-origin guarantee includes type; any other origin has nothing below protocol). Each was confirmed to reject a bad entry locally.
  • sets.scopes lists the vocabulary (single source: #Scopes).
  • comline-catalog: Scope (with as_str), Guarantee::scopes, Guarantee::allows_scope, sets::SCOPES, generated via catalog/rust.cue; tests for scopes present and ordered, bounded_size allowing field but not package, and the enum matching the set.
  • VERSION is not bumped: it moves for wire changes, and neither catalog PR so far (Add the catalog of shared names #1, Add the comline-catalog Rust crate #2) touched it; since is left unset.

Generated files come from specs/check.sh; the Rust crate was not built locally, CI covers it.

A guarantee says which of package, protocol, function, argument, field and
type may acknowledge it, from where its cause is. The schema holds the
scopes to their order and to the guarantee's origin; the comline-catalog
crate gains Scope, Guarantee::scopes and Guarantee::allows_scope.
@Kinflou
Kinflou merged commit 508f813 into main Nov 9, 2026
2 checks passed
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