Skip to main content

Polars 0.20.10 hash function as a plugin library

Project description

Polars legacy hash

For a specific project, I needed to preserve the hashing behaviour of polars 0.20.10 (or the underlying ahash 0.8.7), whilst also wanting to upgrade polars itself.

For now this plugin specifically caters to 0.20.10, but in principle could be generalised. See also Polars Hash which is a more general solution to this, which is coupled to a specific point in time in the history of polars. If there ever comes a use case for this, I expect to move to some version of versioning akin to stub libraries e.g. 0.20.10.20250415 and deploy these from seperate branches to avoid having to bundle multiple polars binaries into the same wheel.

Usage

import polars as pl
import polars_legacy_hash as plh
df = pl.DataFrame({"a": [-42, 13], "b": [-42, 0]})
result = pl.select(plh.oldhash(df.to_struct("test")))

For correctness checking, the CI runs test_expectations.py under polars 0.20.10 to confirm that the test values in the fixtures (defined in tests/conftest.py) are consistent with polars itself.

Development

The plugin is built with maturin, and uv is setup to rebuild an editable install whenever the rust part of the plugin changes. This means the simplest way to run the tests is uv run pytest -rP

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

polars_legacy_hash-0.0.2.tar.gz (34.4 kB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

polars_legacy_hash-0.0.2-cp38-abi3-win_amd64.whl (2.9 MB view details)

Uploaded CPython 3.8+Windows x86-64

polars_legacy_hash-0.0.2-cp38-abi3-win32.whl (2.5 MB view details)

Uploaded CPython 3.8+Windows x86

polars_legacy_hash-0.0.2-cp38-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (3.8 MB view details)

Uploaded CPython 3.8+manylinux: glibc 2.17+ x86-64

polars_legacy_hash-0.0.2-cp38-abi3-macosx_11_0_arm64.whl (3.1 MB view details)

Uploaded CPython 3.8+macOS 11.0+ ARM64

polars_legacy_hash-0.0.2-cp38-abi3-macosx_10_12_x86_64.whl (3.4 MB view details)

Uploaded CPython 3.8+macOS 10.12+ x86-64

File details

Details for the file polars_legacy_hash-0.0.2.tar.gz.

File metadata

  • Download URL: polars_legacy_hash-0.0.2.tar.gz
  • Upload date:
  • Size: 34.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: maturin/1.8.3

File hashes

Hashes for polars_legacy_hash-0.0.2.tar.gz
Algorithm Hash digest
SHA256 65e77740084516a987274dfdb8054fd0100d2fd3fc5a4c6b1dcda39e82dbae14
MD5 d9b9297e60a710cc3d71331e6ab76f46
BLAKE2b-256 ef9bda6a5bbb62468d7f65773f5b0d988657f08ba1c60dbc62b6ed4d65976aaa

See more details on using hashes here.

File details

Details for the file polars_legacy_hash-0.0.2-cp38-abi3-win_amd64.whl.

File metadata

File hashes

Hashes for polars_legacy_hash-0.0.2-cp38-abi3-win_amd64.whl
Algorithm Hash digest
SHA256 3df5fa9918ca8a3abde9e7398e641d5c04b4c3325c5e0cd2401130c9eda6ef69
MD5 81cb7ff7a2e3af5340ba43b12d1ab40f
BLAKE2b-256 012cd5db2de1bde65ef6352e2fe67bb205efa2ad770545372bd70811c9b00ce2

See more details on using hashes here.

File details

Details for the file polars_legacy_hash-0.0.2-cp38-abi3-win32.whl.

File metadata

File hashes

Hashes for polars_legacy_hash-0.0.2-cp38-abi3-win32.whl
Algorithm Hash digest
SHA256 a17bab42d6544294760d0d9489f48e9c4717f68f49d5a3fae75dc178b1784f96
MD5 ed629b7348699026e1419bd8c66d12e7
BLAKE2b-256 f22d3a92c93512ac61e9a75321bf4a47e5e99a5246a93f31ab7b0d3b8a82e18b

See more details on using hashes here.

File details

Details for the file polars_legacy_hash-0.0.2-cp38-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for polars_legacy_hash-0.0.2-cp38-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 b4fa45927bc698578ac4b0de687fb354b0a093ca367cac54b9d1ffa9fd407dac
MD5 85682fe973d8ba2e3db13609e00c840b
BLAKE2b-256 8373ef094c19e7a1aebabb76a7520aa82349da73ef1e7687b93805e260eaa508

See more details on using hashes here.

File details

Details for the file polars_legacy_hash-0.0.2-cp38-abi3-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for polars_legacy_hash-0.0.2-cp38-abi3-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 be49f98304b660b8d4395f5ab7adb18d00be489d537803a8a5744a99ece4951a
MD5 56fe83eec76ab30417f4a51c46633a05
BLAKE2b-256 3bea51645f596f3c6333a894f84d0d25e0eef8bebf06a533fe3c06184386e537

See more details on using hashes here.

File details

Details for the file polars_legacy_hash-0.0.2-cp38-abi3-macosx_10_12_x86_64.whl.

File metadata

File hashes

Hashes for polars_legacy_hash-0.0.2-cp38-abi3-macosx_10_12_x86_64.whl
Algorithm Hash digest
SHA256 18b8cc9eeea5cfbd31e80117fdc49411881bdc4880e61176516402e928b2c752
MD5 f5c2c78167c3d3e7e68ede979dcaa7a7
BLAKE2b-256 9931ee4ac722f0741c882e2d93f0db9639dd2a4d9d311f39047a8891a58370c1

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page