pypi pyjanitor 0.32.81
v0.32.81

2 days ago

Version v0.32.81

This release introduces powerful new capabilities for reading and processing files inside zip and tar archives, with improved error handling, performance, and user experience. The new read_archive function enables seamless access to multiple file formats within archives, interactive member selection, and robust handling of edge cases.

New Features

  • Added read_archive function to read CSV, JSON, Excel, and Parquet files directly from zip and tar archives using pandas or polars. Supports passing reader keyword arguments and interactive member selection. (aebc7a) (Cursor Agent, HASSAIM, Eric Ma)
  • Improved archive member name handling: treats tar members with a leading ./ as equivalent to plain filenames, ensuring compatibility with common tar creation methods. Duplicate member checks are now faster. (4257a5) (Cursor Agent, Eric Ma)
  • Enhanced read_archive selection logic: now fails only on duplicate selected member names, warns when unsupported members are skipped, and enforces a maximum member size limit for memory safety. Each archive is opened only once for efficiency. (9124d1) (Cursor Agent, Eric Ma)
  • When all members are selected in read_archive, the function now returns a dictionary mapping member names to DataFrames, ensuring one frame per member. AppleDouble sidecar files from macOS are automatically skipped. (569bb3) (Cursor Agent, Eric Ma)
  • Archive members are now parsed only after selection, improving performance and memory usage. Member names are listed before prompting for selection, and parse failures now include the member name for easier debugging. (60b7d9) (Cursor Agent, Eric Ma)
  • Documented read_archive in the I/O API. Archive read failures now raise ValueError with the relevant member or archive name, while missing dependencies raise ImportError. (7b9d2e) (Cursor Agent, Eric Ma)

Bug Fixes

None in this release.

Deprecations

None in this release.

Don't miss a new pyjanitor release

NewReleases is sending notifications on new releases.