Repository navigation
Conversation
Names, physical types and the manifest, with no pyspiral; nothing calls it yet. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Warning Review limit reached
This review includes 3 billable files and costs up to $0.75.
Reviews can continue after your included limit without a manual trigger. An admin must approve usage-based billing. Or wait 3 minutes for your next included review. View limit details
|
… codec (ITL-1446) Sibling names are compared as stored, with a hook for probe P1; tests for the review findings. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Codecov Report❌ Patch coverage is
... and 4 files with indirect coverage changes 🚀 New features to boost your workflow:
|
…ed types (ITL-1446) One refusal table; timestamps and times as integers; a draft format tag. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
eywalker
marked this pull request as ready for review
November 24, 2026 19:31
eywalker
marked this pull request as draft
November 24, 2026 19:36
This was referenced Nov 24, 2026
Contributor
Author
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.
Part of ITL-1446: PR 2 of the SpiralDB store design (#542 at
3526f026, sections 3.1 to 3.3, 3.7 and 11). The codec of a store table, as pure functions in one new module,orcapod/databases/spiral_store.py.Nothing calls it, it imports no pyspiral, and no existing code changes. No hash, stored path, layout or golden value moves (
generate_golden_hashes.py --checkis clean); the manifest digest is in the hash site inventory, "in a name". No changelog fragment: nothing is visible to users yet.Decisions this rests on
Implemented as recommended; the developer reviews them later.
read_manifest: two headers are refused, also when they agreeNULL_STRUCT, raised byencode_rowsWhat it does
encode_name(injective). Nothing decodes a name:decode_rowslooks for exactly the stored names the manifest lists, at every depth, and refuses a missing, extra or repeated one. Names that are not UTF-8 and repeated siblings are refused.empty_rowsis what a table with a manifest and no value columns reads as.require_stored_schemaserves the read-back of a first commit.REFUSALS, each with its reason; lifting a type is moving one entry to_NATIVE.Live evidence used
Reported by the live worker (P1 and P3); this PR ran no live SpiralDB. It goes beyond the design text at
3526f026, which still refuses several of these.float16/32/64(-0.0and NaN payloads included),decimal128/256,date32/64, text, binary, a null column, lists, fixed-size lists, maps, structs, and these nested in one another. Names differing in case or normal form stay apart, so no folding rule or escape is added.datetime.max) or a time outside one day.decimal32/64are written as thedecimal128the service gives back, and restored; a map'skeys_sortedand struct field order are restored from the manifest.fixed_size_binary,duration, intervals, a struct with no fields, a null struct, a write of no rows. Substitutes that held and are not used yet:large_binary,int64. NUL,.,$and a leading__are escaped.Held
The second review holds the persisted manifest format. The format tag here is
orcapod.spiral_store.draft, version 0: no table may be written with it outside tests; version 1 is fixed with the creation and recovery rules (PR 6).Held as a draft: the move to spiral-sdk
Orcapod moves to spiral-sdk, to be tested first (developer, 2026-11-24). What rests on pyspiral or the service as measured through it, and must be measured again:
_NOT_PLAIN,_ESCAPED, the__prefix); the key column may start with__; no folding; no length limit_NATIVE; the entries ofREFUSALSwhose reason is the service or client; integers for timestamps and times;decimal128fordecimal32/64; all physical fields nullable; large variants and other list item names on read; struct fields matched by name_MAX_ENTRIES,_MAX_PAIR_BYTES, so_CHUNK_BYTES); chunks and header can be written in two callsThe module imports no client; each dependence above is one constant, table or branch.
Choices the design leaves open
ARROW:extension:*keys are written behind a mark (orcapod:key:) in the recorded schema. Otherwise reading a manifest builds whatever extension type is registered, and fails on one that refuses its storage.Tests
tests/test_databases/test_spiral_store.py, 355 tests: 210,000 adversarial names; every row of the type matrix; each kept type at each nesting depth, over slices, chunks, column orders, sorted struct fields and small or large variants.test_a_stored_name_never_matches_a_logical_name,test_the_key_is_not_a_value_column_of_the_same_name,test_stored_names_come_from_the_manifest_not_from_the_ruletest_rows_that_are_not_what_was_written_are_refusedtest_a_lone_surrogate_is_refused,test_a_name_that_is_not_utf8_is_refused_at_every_depth,test_a_path_component_the_store_cannot_name_is_refusedtest_duplicate_sibling_names_are_refused_at_every_depthtest_a_struct_parent_must_be_valid_also_in_a_logical_types_storage,test_a_null_key_is_refused_whatever_the_schema_saystest_a_manifest_that_cannot_be_read_in_full_is_an_error,test_chunks_in_another_order_are_refused,test_a_manifest_of_another_path_is_refused,test_two_headers_are_refused_also_when_they_agreetest_a_table_with_a_manifest_and_no_rows_reads_as_no_rowstest_names_that_differ_only_in_case_or_normal_form_are_kept_aparttest_datetime_max_and_min_are_kept,test_every_time32_is_kept,test_every_time64_is_kept,test_no_rows_are_never_writtentest_every_type_at_every_nesting_depth,test_a_logical_type_is_kept_by_its_identifier🤖 Generated with Claude Code
Posted by a Claude Code agent on behalf of @eywalker.