Skip to content

Schema refs on fast path - #16

Merged
Tyler-Sch merged 7 commits into
mainfrom
schema_refs_on_fast_path
Sep 20, 2026
Merged

Tyler-Sch merged 7 commits into
mainfrom
schema_refs_on_fast_path

Conversation

@Tyler-Sch

Copy link
Copy Markdown
Owner

Adds schema references on fast path

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot review overview

🟡 Changes recommended

Address the schema dependency-ordering, deprecated documentation example, and GIL-handling findings.

Get a fresh assessment by requesting another Copilot review.

Review effort: Lite
Findings: 1 Medium severity

Open (1)
What changed in this PR

Adds named Avro schema-reference support across fast encode/decode paths, schema resolution, and Python schema-to-Arrow conversion.

Changes:

  • Adds multi-document schema parsing and reference resolution.
  • Updates serialization and deserialization to use resolved schemas.
  • Adds Python schema APIs, map metadata fixes, tests, and documentation.
File Summary
src/​lib.rs Adds Python schema APIs; moderate concern about holding the GIL during schema translation.
ruhvro/​src/​serialize.rs Uses resolved schemas during serialization.
ruhvro/​src/​serialization_containers.rs Separates original and resolved schemas.
ruhvro/​src/​schema/​translate.rs Updates schema translation and map metadata.
ruhvro/​src/​schema/​resolve.rs Adds named-reference resolution.
ruhvro/​src/​schema/​mod.rs Adds schema-list parsing; moderate concern about dependency ordering.
ruhvro/​src/​lib.rs Updates public schema exports and examples.
ruhvro/​src/​fast_encode.rs Integrates the updated schema translation.
ruhvro/​src/​fast_decode.rs Integrates the schema module for decoding.
ruhvro/​src/​deserialize.rs Resolves references during fast decoding.
ruhvro/​README.md Documents schema lists; nits concern dependency ordering and deprecated API usage.
README.md Documents schema references; nit concerning dependency-ordering guidance.
CLAUDE.md Updates repository architecture guidance.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread src/lib.rs
Comment on lines +90 to 95
#[pyfunction]
fn avro_to_arrow_schema(schema: SchemaArg) -> PyResult<PyArrowType<ArrowSchema>> {
let parsed_schema = get_or_parse_schema(&schema)?;
let arrow_schema = ruhvro::schema::to_arrow_schema(&parsed_schema).map_err(to_py_err)?;
Ok(PyArrowType(arrow_schema))
}
@Tyler-Sch
Tyler-Sch merged commit aea49d5 into main Sep 20, 2026
13 checks passed
@Tyler-Sch
Tyler-Sch deleted the schema_refs_on_fast_path branch September 20, 2026 21:58
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.

2 participants