Skip to main content

Rhodochrosite

Rhodochrosite is a Python 3.13+ library for loading and saving objects in the Ruby marshal format.

Support and limitations

Rhodochrosite supports nearly every feature of the Marshal library, up to Ruby 4.0. Some parts are not supported:

  • The writer never outputs object links, so both self-referential structures and identity equality are broken. Outputting object links will likely never be supported (reading them is supported)
  • Ruby strings with custom encodings are not supported; any string that does not mark itself as UTF-8 will be treated as a bytestring.
  • The "d" type (Data) will never be supported, as it related to native Ruby extensions which don't really make sense across the wire barrier

Some features may be supported in the future, but are not currently supported:

  • Regular expression types; Ruby uses a different regexp execution engine to Python so these would not be very useful beyond being opaque types.
  • Hashes with default values,
  • Module references.
  • Struct instances.

However, some esoteric features that are otherwise annoying to support are supported:

  • Strings, arrays, and hashes with custom instance variables.
  • Hashes with duplicate keys (requires passing return_native_dicts=False)
  • Unicode symbol names

Basic usage

Use read_object to turn a marshal stream into a single high-level Python object:

print(read_object(b'\x04\b"\babc'))  # => "abc"

Use write_object to turn a Python object into a marshal stream:

print(write_object([1, 2, 3]))  # => b"\x04\b[\bi\x06i\ai\b"

Metadata

Release files for rhodochrosite 26.0.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for rhodochrosite 26.0.2
File Size Uploaded Provenance Actions
rhodochrosite-26.0.2.tar.gz 38.2 kB Without provenance Details for rhodochrosite-26.0.2.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for rhodochrosite 26.0.2
File Interpreter ABI Platform Actions
rhodochrosite-26.0.2-py3-none-any.whl Python 3 none any Details for rhodochrosite-26.0.2-py3-none-any.whl

Total release size: 90.6 kB

Release files / rhodochrosite-26.0.2.tar.gz

Download URL rhodochrosite-26.0.2.tar.gz
Size 38.2 kB
Tags Source
SHA-256 checksum
How to use checksums
4cf9b8978b2abd695c45409136393971a224d6dffc6adac4ffdee6395bedc062
BLAKE2b-256 checksum
How to use checksums
7f8e3d4e3027b1594f770a60ec48288b0dbe907327b1d9b688fc29a62cac71c7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.12.8 {"installer":{"name":"uv","version":"0.12.8","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Gentoo","version":"2.18","id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

Release files / rhodochrosite-26.0.2-py3-none-any.whl

Download URL rhodochrosite-26.0.2-py3-none-any.whl
Size 52.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
2aa07492fe4b4c108e308bbbc7f6c64d62e6994d241e0de24fe23618a4b42ebb
BLAKE2b-256 checksum
How to use checksums
18489056dc00e21e3e9b09c5907a94c34eb7362cf4ef960751c5d5730c512f66
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.12.8 {"installer":{"name":"uv","version":"0.12.8","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Gentoo","version":"2.18","id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

Security for rhodochrosite 26.0.2

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page