Skip to main content

Adapter which implements a subset of rpds-py using pyrsistent. Mostly meant for PyPy.

Project description

pyrsistent-as-rpds-py

Run tests

what is this?

This is a thin adapter library which implements a subset of rpds-py using pyrsistent. The provided functionality is sufficient to run the jsonschema test cases successfully.

why is this?

In 2023, the jsonschema devs replaced the pure-Python pyrsistent library dependency with a binary dependency called rpds-py. This replacement was done for very reasonable speed reasons. However, PyPy users may still prefer the pure-Python version both for speed reasons and also to avoid the hassle of building binary packages.

(The rpds-py API also just feels better than the pyrsistent one, in my humble opinion. If I wanted to build something with persistent data structures, I would probably either use this module or rpds-py.)

how to use

Pip doesn't seem to have a way to override or substitute dependencies (at least without disabling dependency resolution entirely). Therefore, I suggest running something like this:

pip install --no-index --no-build-isolation .  # install package "pyrsistent-as-rpds-py"
cd extra/fake_rpds
pip install --no-index --no-build-isolation .  # install fake and empty "rpds" package to make pip happy

Now you can install jsonschema or other packages that depend on rpds-py normally.

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

pyrsistent-as-rpds-py-1.1.0.tar.gz (13.8 kB view details)

Uploaded Source

Built Distribution

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

pyrsistent_as_rpds_py-1.1.0-py3-none-any.whl (5.4 kB view details)

Uploaded Python 3

File details

Details for the file pyrsistent-as-rpds-py-1.1.0.tar.gz.

File metadata

  • Download URL: pyrsistent-as-rpds-py-1.1.0.tar.gz
  • Upload date:
  • Size: 13.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.2

File hashes

Hashes for pyrsistent-as-rpds-py-1.1.0.tar.gz
Algorithm Hash digest
SHA256 43d0c13403777f466955622275485b61e76f7464e701843a177e423e19e5bcbf
MD5 45577efc6248c0270c156a8fb30b2aca
BLAKE2b-256 ed170ee23173af5b523f346a84a6a7fea4473695f898e1e51f928300cfdd1b2b

See more details on using hashes here.

File details

Details for the file pyrsistent_as_rpds_py-1.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for pyrsistent_as_rpds_py-1.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 75186252a93af81dce80eebba6bdebfb12ecb2c2b88e359ff8ef804abf190572
MD5 61e91d23db0be0111cb5a81faa31dea3
BLAKE2b-256 b3b48fa60d23bdc32d280bc74f9db3d48b20dc05ccdbce9b250c14f000454e55

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