refactor!: Remove bulk of IO and serialization logic - #379
Merged
Oliver Borchert (borchero) merged 13 commits intoJul 31, 2026
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## remove-to-polars #379 +/- ##
===================================================
Coverage 100.00% 100.00%
===================================================
Files 56 46 -10
Lines 3413 2604 -809
===================================================
- Hits 3413 2604 -809 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
Oliver Borchert (borchero)
marked this pull request as ready for review
July 30, 2026 00:32
Oliver Borchert (borchero)
requested review from
Andreas Albert (AndreasAlbertQC) and
Daniel Elsner (delsner)
as code owners
July 30, 2026 00:32
Contributor
There was a problem hiding this comment.
Pull request overview
This PR implements the direction of #367 by removing most of dataframely’s built-in I/O and schema/collection serialization logic (including metadata roundtrips and delta support), and simplifying persistence to lightweight parquet helpers for Collection and FailureInfo without implicit validation or schema metadata.
Changes:
- Removed schema/collection serialization and metadata-driven read/scan behavior; removed related exceptions and helpers.
- Removed delta / fsspec-based storage backends and associated optional dependencies and tests (including S3/moto fixtures).
- Reworked
Collectionparquet persistence andFailureInfoparquet persistence to store only minimal metadata (rule-columns) and require explicit validation by users.
Reviewed changes
Copilot reviewed 47 out of 48 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
| tests/test_serialization.py | Removed tests for schema JSON decoding/serialization. |
| tests/test_deprecation.py | Removed deprecation tests tied to deprecated I/O methods slated for removal. |
| tests/storage/test_fsspec.py | Removed fsspec-specific storage helper tests. |
| tests/storage/test_delta.py | Removed delta-backend storage tests. |
| tests/schema/test_storage.py | Removed schema storage/metadata/implicit-validation tests. |
| tests/schema/test_serialization.py | Removed schema serialization roundtrip and deserialization failure tests. |
| tests/schema/test_read_write_parquet.py | Removed schema parquet metadata tests and mkdir behavior tests tied to schema I/O. |
| tests/failure_info/test_storage.py | Updated FailureInfo persistence tests to parquet-only and new metadata expectations. |
| tests/conftest.py | Removed S3/moto fixtures used for storage backends. |
| tests/column_types/test_enum.py | Simplified enum test to assert persisted configuration flags directly (no dict roundtrip). |
| tests/collection/test_storage.py | Updated collection storage tests to parquet-only directory layout and no implicit validation behavior. |
| tests/collection/test_serialization.py | Removed collection serialization/deserialization tests. |
| skills/SKILL.md | Removed I/O conventions section that is no longer applicable after I/O removal. |
| pyproject.toml | Dropped fsspec/s3/deltalake dependencies and removed pytest S3 marker/warning filters. |
| pixi.toml | Dropped fsspec/s3/moto/boto3/deltalake from pixi environments and optionals. |
| docs/guides/features/serialization.md | Rewritten to “Persisting data” with explicit “no schema metadata / no implicit validation” guidance. |
| docs/api/schema/io.rst | Removed schema I/O API docs. |
| docs/api/schema/index.rst | Removed schema I/O section from schema docs index. |
| docs/api/filter_result/failure_info.rst | Removed delta I/O entries for FailureInfo. |
| docs/api/errors/index.rst | Removed ValidationRequiredError from documented errors. |
| docs/api/collection/io.rst | Removed delta I/O and collection serialization metadata API entries. |
| dataframely/testing/storage.py | Removed test-only storage abstraction layer for parquet/delta/fsspec backends. |
| dataframely/schema.py | Removed schema serialization + schema I/O APIs and metadata-driven validation logic; FailureInfo no longer carries schema. |
| dataframely/filter_result.py | Simplified FailureInfo (no schema), removed delta support, and implemented parquet-only persistence with rule_columns metadata. |
| dataframely/exc.py | Removed I/O-related exceptions (ValidationRequiredError, DeserializationError). |
| dataframely/columns/struct.py | Removed dict (de)serialization hooks now that schema serialization is removed. |
| dataframely/columns/list.py | Removed dict (de)serialization hooks now that schema serialization is removed. |
| dataframely/columns/enum.py | Updated comment to reflect removal of dict roundtripping concerns. |
| dataframely/columns/array.py | Removed dict (de)serialization hooks now that schema serialization is removed. |
| dataframely/columns/_registry.py | Removed column_from_dict deserialization factory. |
| dataframely/columns/_base.py | Removed as_dict / from_dict and check-expression conversion utilities used for serialization. |
| dataframely/columns/init.py | Stopped exporting removed column_from_dict. |
| dataframely/collection/filter_result.py | Updated FailureInfo construction to match new signature (no schema). |
| dataframely/collection/collection.py | Removed collection serialization and metadata-driven I/O; implemented direct parquet write/read/scan per member file. |
| dataframely/collection/init.py | Removed exports for removed collection (de)serialization and metadata readers. |
| dataframely/_typing.py | Removed Validation type alias now that validation-on-read is removed. |
| dataframely/_storage/parquet.py | Removed parquet storage backend implementation. |
| dataframely/_storage/delta.py | Removed delta storage backend implementation. |
| dataframely/_storage/constants.py | Removed metadata-key constants used by storage backends. |
| dataframely/_storage/_fsspec.py | Removed fsspec file-prefix helper. |
| dataframely/_storage/_exc.py | Removed storage metadata assertion helper. |
| dataframely/_storage/_base.py | Removed storage-backend abstraction interface. |
| dataframely/_storage/init.py | Removed storage package exports. |
| dataframely/_serialization.py | Removed schema/collection JSON encoder/decoder utilities. |
| dataframely/_rule.py | Removed rule dict (de)serialization factory utilities. |
| dataframely/_compat.py | Removed deltalake + partition-sink compatibility shims now that delta I/O is removed. |
| dataframely/init.py | Removed exports for removed (de)serialization and metadata readers, and removed Validation/DeserializationError exports. |
Comments suppressed due to low confidence (1)
dataframely/filter_result.py:208
- Same
metadatatype-assumption issue as inwrite_parquet:{**metadata, ...}will raise aTypeErrorfor non-dict metadata values (e.g.None). Validatingmetadataavoids a confusing failure mode.
metadata = kwargs.pop("metadata", {})
self._lf.sink_parquet(
file,
metadata={**metadata, "rule_columns": json.dumps(self._rule_columns)},
**kwargs,
Oliver Borchert (borchero)
changed the base branch from
main
to
remove-to-polars
July 30, 2026 19:48
This was referenced Jul 30, 2026
Closed
Andreas Albert (AndreasAlbertQC)
approved these changes
Jul 31, 2026
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.
Motivation
Implements #367.