94 lines
3.1 KiB
Plaintext
94 lines
3.1 KiB
Plaintext
Metadata-Version: 2.4
|
|
Name: ormsgpack
|
|
Version: 1.12.1
|
|
Classifier: Development Status :: 5 - Production/Stable
|
|
Classifier: Intended Audience :: Developers
|
|
Classifier: License :: OSI Approved :: Apache Software License
|
|
Classifier: License :: OSI Approved :: MIT License
|
|
Classifier: Operating System :: MacOS
|
|
Classifier: Operating System :: Microsoft :: Windows
|
|
Classifier: Operating System :: POSIX :: Linux
|
|
Classifier: Programming Language :: Python :: 3
|
|
Classifier: Programming Language :: Python :: 3.10
|
|
Classifier: Programming Language :: Python :: 3.11
|
|
Classifier: Programming Language :: Python :: 3.12
|
|
Classifier: Programming Language :: Python :: 3.13
|
|
Classifier: Programming Language :: Python :: 3.14
|
|
Classifier: Programming Language :: Python :: Implementation :: CPython
|
|
Classifier: Programming Language :: Python :: Implementation :: GraalPy
|
|
Classifier: Programming Language :: Python :: Implementation :: PyPy
|
|
Classifier: Programming Language :: Python
|
|
Classifier: Programming Language :: Rust
|
|
Classifier: Typing :: Typed
|
|
License-File: LICENSE-APACHE
|
|
License-File: LICENSE-MIT
|
|
Summary: Fast, correct Python msgpack library supporting dataclasses, datetimes, and numpy
|
|
Keywords: fast,msgpack,dataclass,dataclasses,datetime
|
|
Author-email: Aviram Hassan <aviramyhassan@gmail.com>, Emanuele Giaquinta <emanuele.giaquinta@gmail.com>
|
|
License-Expression: Apache-2.0 OR MIT
|
|
Requires-Python: >=3.10
|
|
Description-Content-Type: text/markdown; charset=UTF-8; variant=GFM
|
|
Project-URL: Homepage, https://github.com/aviramha/ormsgpack
|
|
|
|
# ormsgpack
|
|
|
|

|
|

|
|

|
|
|
|
ormsgpack is a fast [MessagePack](https://msgpack.org/) serialization library for Python
|
|
derived from [orjson](https://github.com/ijl/orjson), with native support for various
|
|
Python types.
|
|
|
|
ormsgpack follows semantic versioning and supports CPython, PyPy and GraalPy.
|
|
|
|
Links:
|
|
|
|
- [Repository](https://github.com/aviramha/ormsgpack)
|
|
- [Documentation](https://ormsgpack.readthedocs.io/)
|
|
|
|
## Installation
|
|
|
|
pip
|
|
|
|
```sh
|
|
pip install ormsgpack
|
|
```
|
|
|
|
uv
|
|
|
|
```sh
|
|
uv add ormsgpack
|
|
```
|
|
|
|
Installing from a source distribution requires
|
|
[Rust](https://www.rust-lang.org/) 1.81 or newer and
|
|
[maturin](https://github.com/PyO3/maturin).
|
|
|
|
## Quickstart
|
|
|
|
This is an example of serializing and deserializing an object:
|
|
|
|
```python
|
|
>>> import ormsgpack, datetime, numpy
|
|
>>> event = {
|
|
... "type": "put",
|
|
... "time": datetime.datetime(1970, 1, 1),
|
|
... "uid": 1,
|
|
... "data": numpy.array([1, 2]),
|
|
... }
|
|
>>> ormsgpack.packb(event, option=ormsgpack.OPT_SERIALIZE_NUMPY)
|
|
b'\x84\xa4type\xa3put\xa4time\xb31970-01-01T00:00:00\xa3uid\x01\xa4data\x92\x01\x02'
|
|
>>> ormsgpack.unpackb(_)
|
|
{'type': 'put', 'time': '1970-01-01T00:00:00', 'uid': 1, 'data': [1, 2]}
|
|
```
|
|
|
|
## License
|
|
|
|
orjson was written by ijl <<ijl@mailbox.org>>, copyright 2018 - 2021, licensed
|
|
under both the Apache License, Version 2.0, and the MIT License.
|
|
|
|
ormsgpack was forked from orjson by Aviram Hassan and is now maintained by Emanuele Giaquinta (@exg), licensed
|
|
under both the Apache License, Version 2.0, and the MIT License.
|
|
|