百科.dev
全部条目在线工具AI 编程趋势榜开源项目技术资讯提交条目
登录
< 返回工具列表
O

ormsgpack

> 编程语言
开源

MessagePack 序列化库,源自 orjson,使用 PyO3 在 Rust 中编写

400 stars0 点赞0 次浏览
访问官网GitHub

工具介绍

MessagePack 序列化库,源自 orjson,使用 PyO3 在 Rust 中编写

ormsgpack

ormsgpack is a fast MessagePack serialization library for Python derived from orjson, with native support for various Python types.

ormsgpack follows semantic versioning and supports CPython, PyPy and GraalPy.

Links:

  • Repository
  • Documentation

Installation

pip

bash
pip install ormsgpack

uv

bash
uv add ormsgpack

Installing from a source distribution requires Rust 1.81 or newer and 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 <>, 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.

Issues· 6 开放

查看全部 Issues在 GitHub 打开

暂无开放 Issues,或尚未同步最近议题。

> 标签

Rustdataclassdataclassesextensionfast

暂无评论,来聊聊你的看法吧

> 工具信息

发布日期2026年8月1日
最后更新2026年9月17日
分类编程语言
定价开源

> 相关工具

T
TypeScript
JavaScript 的超集,为前端与全栈提供静态类型
P
Python
通用编程语言,广泛用于 Web、数据与 AI
G
Go
Google 推出的简洁高效系统语言