Repository navigation
v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag + openapi.dag — remaining-formats bundle (L-2 spec-first, // Anchor: version-pinned, C5-fidelity; csv-rectangularity = operator-pending defer under named trigger) #3205
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
117 commits
Select commit
Hold shift + click to select a range
174dd39
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls 700c74a
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls 216af43
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls fb09806
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls 66bf52b
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls 12316a3
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls 8869853
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls ef7c008
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls 14984e5
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls 6f8e0c3
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls c9134d3
Merge remote-tracking branch 'origin/main' into session/sunny-stag-440
briansrls 24ca488
Merge remote-tracking branch 'origin/main' into session/sunny-stag-440
briansrls 4fdd101
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls 0be85f6
fix: register P5 SG-0 receipt for v4 formats Lane C smoke harness
briansrls e8900f8
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls fcab72e
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls b2ad598
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls 38ddab2
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls 9ed2876
fix(csv): RFC4180-nullary dialect + reconcile header with rectangular…
briansrls 66920f3
fix(openapi): add contact_extensions for Contact Object spec extensions
briansrls 8a7649a
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls 867fb99
docs(openapi): receipt by_status key shape under Deferred (1)
briansrls 0d1234b
fix(openapi): align Responses key receipts with OAS 1XX…5XX lexemes
briansrls 717df00
Merge remote-tracking branch 'origin/main' into session/sunny-stag-440
briansrls e65b81e
fix(json_schema): model type-array uniqueness with Set<T>
briansrls 9dce99d
Merge remote-tracking branch 'origin/main' into session/sunny-stag-440
briansrls 028e5b0
fix(openapi): OpenApiPathsSlot for optional root paths field
briansrls d61c7ea
chore(openapi): wrap DECLARATIVE-NOW paths prose line
briansrls 38f1772
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls 2c34b18
Merge remote-tracking branch 'origin/main' into session/sunny-stag-440
briansrls ae4db20
fix(openapi): add Response Object content/headers/links slots
briansrls 4bb5614
fix(json_schema): correct Deferred §6.5.3 required vs properties note
briansrls f89b405
fix(openapi): split root spec extensions vs deferred fixed members
briansrls d911423
fix(openapi): split path/operation deferred fields vs spec extensions
briansrls ccc65c6
fix(openapi): split Media Type and Components deferred vs spec extens…
briansrls 96de2c5
Merge remote-tracking branch 'origin/main' into session/sunny-stag-440
briansrls 8bce07d
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls d9148e1
fix(openapi): add OpenApiSchema wrapper for OAS Schema Object
briansrls 7584b9c
fix(openapi): split Info deferred fixed members vs spec extensions
briansrls d36a657
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls b792bd8
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls dbd2cbc
fix(json_schema): wire properties/required P2 presence slots on Instance
briansrls e82a867
fix(openapi): align Owns header with OpenApiDocument root carrier
briansrls 027332c
fix(json_schema): narrow Deferred validate note for Draft 2020-12 app…
briansrls 5918d91
Merge remote-tracking branch 'origin/main' into session/sunny-stag-440
briansrls 85d6929
Merge remote-tracking branch 'origin/main' into session/sunny-stag-440
briansrls 67979c5
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls 16f1581
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls 043bfd9
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls 215f781
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls 53d77a0
chore(v4-formats): strict de-prose Lane C .dag (operator msg_ba1a791a)
briansrls 1053c28
fix(csv): restore RFC anchor + named rectangularity receipt in Scope …
briansrls 73adc87
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls b6199ba
fix(openapi): key responses by closed OpenApiResponseKey, not String
briansrls 8c3ff2e
fix(openapi): enforce non-empty responses + root paths|components|web…
briansrls a3cb73e
fix(csv): Peano spine rows; drop decoupled width vs List<String> arity
briansrls 78fe67e
docs(v4-formats): pin JSON Schema + OpenAPI spec URLs in Scope lines
briansrls 2058c59
fix(json_schema): key additional_members by closed keyword sum (P2)
briansrls 65df8f4
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls f0f8726
fix(openapi): Paths.routes keys use OpenApiPathTemplateKey (/ prefix)
briansrls 6300272
chore(v4-formats): align openapi Scope with Responses shape; import Map
briansrls a994064
chore(openapi): drop phantom Owns entries (Practice 5 / P2)
briansrls 01346e7
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls 8174dd4
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls 1af4d75
fix(openapi): typed headers/links/refs + closed deferred/extension keys
briansrls 5471eba
docs(openapi): Scope receipt for path-template lexical deferral
briansrls b9807aa
Merge remote-tracking branch 'origin/main' into session/sunny-stag-440
briansrls 328b642
fix(openapi): model document root as coordinate slots, not 7-way sum
briansrls 4bddb42
fix(v4): Practice 9 headers + T-4.6 disposition ledger
briansrls af1ed2d
Merge remote-tracking branch 'origin/main' into session/sunny-stag-440
briansrls f8f995d
Merge remote-tracking branch 'origin/main' into session/sunny-stag-440
briansrls b95c1d6
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls 6ace419
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls 414d82c
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls 75ef827
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls 5e8f644
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls 21516d0
fix(csv): bring comment ratio under 20% gate
briansrls 8cbd188
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls 100bfaa
fix(csv): revert blank-line padding in csv.dag
briansrls 7640b17
feat(csv): RFC 4180 witness carriers for Lane C ratio + ledger
briansrls 4d1ca9f
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls 4d7744a
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls b198592
fix(v4): model OAS 3.1 components.pathItems and path item $ref
briansrls 90fe4e1
chore(v4): align Lane C .dag headers with Practice 9
briansrls 2d4710e
Merge remote-tracking branch 'origin/main' into session/sunny-stag-440
briansrls ac70fc6
Merge remote-tracking branch 'origin/main' into session/sunny-stag-440
briansrls a01ccac
Merge remote-tracking branch 'origin/main' into session/sunny-stag-440
briansrls fe31c7b
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls ab300de
fix(v4): structurally rectangular CSV + unique OpenAPI response keys
briansrls 9c56fab
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls 96fe3f3
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls a3dc760
Merge remote-tracking branch 'origin/main' into session/sunny-stag-440
briansrls c4a1aff
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls 2772d40
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls d950497
fix(v4): ground JsonSchema keyword sum in draft-2020-12 meta-schema
briansrls e0bde81
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls dae282b
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls 831e3e5
Merge remote-tracking branch 'origin/main' into session/sunny-stag-440
briansrls 616b723
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls 15be3b6
fix(v4): restore DECISIONS.md Part 6 dropped in 616b7238b
briansrls 9c4230f
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls 4bc24e1
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls f9539c6
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls b02e73a
fix(v4): drop OpenApiDocumentRoot prose block for Practice 9
briansrls f67a891
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls f0542be
fix(v4): pair HeaderDeprecatedSlot with T-4.6-P4 row; trim Practice-9…
briansrls 55dc1f0
fix(v4): encode non-empty JSON Schema `type` union in JsonSchemaTypeSlot
briansrls 919441f
fix(v4): add T-4.6-P4 rows for OpenApiResponseKeyNonDefault and Defau…
briansrls 5949e93
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls 9e4fbc4
Merge remote-tracking branch 'origin/main' into session/sunny-stag-440
briansrls a86f319
Merge remote-tracking branch 'origin/main' into session/sunny-stag-440
briansrls 9539203
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls 471efe6
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls 4279377
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls 89266b4
WIP: v4 T-4.6 Lane C: model extdeps/formats/csv.dag + json_schema.dag…
briansrls 17c4f60
fix(decisions): align T-4.6-CSV ledger with csv.dag MIME facts
briansrls 1c0d20a
Merge remote-tracking branch 'origin/main' into session/sunny-stag-440
briansrls File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,29 +1,78 @@ | ||
| // src/v4/extdeps/formats/csv.dag | ||
| // | ||
| // Scope: CSV (Comma-Separated Values) data format model — direction-agnostic. | ||
| // Anchor: https://datatracker.ietf.org/doc/html/rfc4180 (RFC 4180) | ||
| // | ||
| // Owns: | ||
| // - CsvDocument { width: PositiveInt, header: Option<Row>, records: List<Row> } | ||
| // - Row = a field sequence whose length is STRUCTURALLY == width | ||
| // (rectangularity is an invariant of the type, not a convention — | ||
| // RFC 4180 §1: "each line should contain the same number of fields". | ||
| // `List<List<String>>` is rejected: it admits ragged records and | ||
| // header-width drift, an illegal state. Ragged input is a parse | ||
| // Diagnostic, never a representable CsvDocument — fail-closed.) | ||
| // - parse(String, Dialect) -> Result<CsvDocument, Diagnostic> | ||
| // (width fixed by header if present, else by the first record; any | ||
| // record whose arity != width is a Diagnostic, not a truncation/pad) | ||
| // - emit(CsvDocument, Dialect) -> String | ||
| // - Dialect { delimiter: Char, quote: Char, escape: Option<Char>, line_terminator: String } | ||
| // | ||
| // Consumes: | ||
| // - std/node.dag, std/diagnostic.dag, std/collection.dag, std/text.dag | ||
| // | ||
| // Status: scaffold — fill per TASKS.md T-4.6 | ||
| // Brief: see BRIEF_TEMPLATE.md; this file's I/O contract is the immutable | ||
| // contract for the worker. Splitting this file requires explicit operator | ||
| // ratification (substrate extension = stop signal). | ||
| // Scope: RFC 4180 CSV; Lane C format slice (TASKS.md T-4.6). | ||
| // Owns: CsvDialect, CsvHeaderPresence, CsvRow, CsvDocument, CsvRfc4180CommaFieldSep, CsvRfc4180DoubleQuoteEnclosure, CsvRfc4180EscapeDoubledQuote, CsvRfc4180RecordLineBreak, CsvRfc4180LastRecordEndingLineBreakOptional, CsvRfc4180HeaderRowOptional, CsvRfc4180NewlineInsideQuotedFieldOnly, CsvRfc4180UnquotedFieldTextdataVsTab, CsvRfc4180EmptyFieldBetweenCommas, CsvRfc4180RegisteredTextCsvMime | ||
| // Consumes: std/node.dag, std/diagnostic.dag, std/collection.dag, std/text.dag | ||
| // Status: scaffold — TASKS.md T-4.6 | ||
| // Anchor: https://datatracker.ietf.org/doc/html/rfc4180 | ||
|
|
||
| module v4.extdeps.formats.csv | ||
|
|
||
|
|
||
| type CsvDialect | ||
| = CsvDialectRfc4180 {} | ||
|
|
||
| // 🟡 coproduct dissolution — DECISIONS.md T-4.6-P4-CsvHeaderPresence | ||
| type CsvHeaderPresence | ||
| = HeaderPresent { row: CsvRow } | ||
| | HeaderAbsent | ||
|
|
||
| // 🟡 coproduct dissolution — DECISIONS.md T-4.6-P4-CsvRow | ||
| type CsvRow | ||
| = CsvRowZ | ||
| | CsvRowS { field: String, tail: CsvRow } | ||
|
|
||
| // Singleton witnesses: normative RFC slice facts are **inhabitance-only** (no Bool negation). | ||
|
|
||
| type CsvRfc4180FieldsSeparatedByCommaU002cWitness {} | ||
|
|
||
| type CsvRfc4180HorizontalTabRejectedAsFieldSeparatorWitness {} | ||
|
|
||
| type CsvRfc4180CommaFieldSep { | ||
| fields_separated_by_comma_u002c: CsvRfc4180FieldsSeparatedByCommaU002cWitness, | ||
| horizontal_tab_is_rejected_separator_for_this_slice: CsvRfc4180HorizontalTabRejectedAsFieldSeparatorWitness, | ||
| } | ||
|
|
||
| type CsvRfc4180DquoteMayEncloseEntireFieldWitness {} | ||
|
|
||
| type CsvRfc4180EnclosedFieldMayContainCommaCrlfOrLfWitness {} | ||
|
|
||
| type CsvRfc4180DoubleQuoteEnclosure { | ||
| dquote_u0022_may_enclose_entire_field: CsvRfc4180DquoteMayEncloseEntireFieldWitness, | ||
| enclosed_field_may_contain_comma_crlf_or_lf: CsvRfc4180EnclosedFieldMayContainCommaCrlfOrLfWitness, | ||
| } | ||
|
|
||
| type CsvRfc4180EscapeDoubledQuote {} | ||
|
|
||
| type CsvRfc4180RecordsSeparatedByAsciiCrlfPerRfc4180Witness {} | ||
|
|
||
| type CsvRfc4180GeneratorEmitsCrlfBetweenRecordsWitness {} | ||
|
|
||
| type CsvRfc4180RecordLineBreak { | ||
| records_separated_by_ascii_crlf_u000d_u000a_per_rfc4180: CsvRfc4180RecordsSeparatedByAsciiCrlfPerRfc4180Witness, | ||
| generator_should_emit_crlf_between_records_per_rfc4180: CsvRfc4180GeneratorEmitsCrlfBetweenRecordsWitness, | ||
| } | ||
|
|
||
| // RFC 4180 §2: last record may omit the ending line break; unrelated to COMMA after the last field (forbidden). | ||
| type CsvRfc4180LastRecordEndingLineBreakOptional {} | ||
|
|
||
| type CsvRfc4180HeaderRowOptional {} | ||
|
|
||
| type CsvRfc4180NewlineInsideQuotedFieldOnly {} | ||
|
|
||
| type CsvRfc4180SpU0020TextdataOutsideUnquotedFieldWitness {} | ||
|
|
||
| type CsvRfc4180TabRejectedOutsideUnquotedFieldWitness {} | ||
|
|
||
| type CsvRfc4180UnquotedFieldTextdataVsTab { | ||
| ascii_sp_u0020_outside_unquoted_field_is_textdata_field_char: CsvRfc4180SpU0020TextdataOutsideUnquotedFieldWitness, | ||
| horizontal_tab_u0009_outside_unquoted_field_is_rejected_not_textdata: CsvRfc4180TabRejectedOutsideUnquotedFieldWitness, | ||
| } | ||
|
|
||
| type CsvRfc4180EmptyFieldBetweenCommas {} | ||
|
|
||
| type CsvRfc4180RegisteredTextCsvMime {} | ||
|
|
||
| type CsvDocument { | ||
| header: CsvHeaderPresence, | ||
| records: List<CsvRow>, | ||
|
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. BLOCKING: CsvDocument.records is a possibly-empty List, but RFC 4180 file grammar requires a record after the optional header, so empty/header-only documents become representable (extdeps fidelity/P2; https://datatracker.ietf.org/doc/html/rfc4180#section-2). |
||
| } | ||
Oops, something went wrong.
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
BLOCKING: CsvRow admits CsvRowZ as a standalone zero-field row even though RFC 4180 defines a record as at least one field, so invalid CSV rows inhabit the substrate (extdeps fidelity/P2; https://datatracker.ietf.org/doc/html/rfc4180#section-2).