Make it better!
Project description
项目介绍
这是一个 Python 和 Rust 混合编程的项目,主要目的是比较 Rust 和 Python 的性能差异。目前这个项目是 rshare
说明
目前已经支持 64 位操作系统,包括 Windows,Linux,macOS 和 ARM64 架构的 Linux 系统。
安装
通过 pip install rshare --upgrade -i https://pypi.org/simple
来安装 rshare
体验 Rust 的极致性能!
使用
import rshare as rk
# Rust 接口
fetch_title_str = rk.fetch_title(url="https://www.baidu.com")
print(fetch_title_str)
# Python 接口
fetch_name_str = rk.fetch_name(url="https://www.baidu.com")
print(fetch_name_str)
构建
maturin build
maturin develop --release
版本说明
目前主要是说明开发的软件版本:
- Python 3.11
- Rust 1.74.1
注意事项
需要重新编译部分内容
更新
- 推送到 main 分支
- 修改
Cargo.toml
中的版本号 - 打标签:
git tag v0.1.7
- 通过推送标签进行升级:
git push origin v0.1.7
镜像推送
- 基于原始镜像:
ghcr.io/rust-cross/manylinux2014-cross:aarch64
docker build -t jindaxiang/newopen .
docker tag local-image:tagname jindaxiang/new-repo:tagname
docker push jindaxiang/new-repo:tagname
查看
贡献代码
关注 .vscode
用于 debug 代码,新增 .vscode 文件夹
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
rshare-0.1.11.tar.gz
(20.3 kB
view hashes)
Built Distributions
Close
Hashes for rshare-0.1.11-cp38-abi3-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | d9aea24bb80cbe9118348213b999fee21b5095914c5c3efbd701bab46ec6e23b |
|
MD5 | be1124f12da3e4e97ce904b827f5c9f5 |
|
BLAKE2b-256 | 4b0176d5cf354bd8f94a6901cce79715f5726f3e6958d1a991628cb003f3edbf |
Close
Hashes for rshare-0.1.11-cp38-abi3-manylinux_2_34_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 1d0651244fc62e648325c4403e0fc6c66b440a8fb40733251e645988d9544bdb |
|
MD5 | 049b2e6fa20e1a29c3ffa82e1da3636e |
|
BLAKE2b-256 | a39c812c17c28f7a892a4d91e4d512c06833d42cd3d3982cc56e1d387890f291 |
Close
Hashes for rshare-0.1.11-cp38-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 5a474dbfff2227b6edb7b5d9ad38b57d15de26929466532ed2857e5324d2e11d |
|
MD5 | 114410442e185bb674102fd66a009f24 |
|
BLAKE2b-256 | d1a201b13c27e57943c21c799a6546e686b2b31298ca149d2dbcb9b87f0006cd |
Close
Hashes for rshare-0.1.11-cp38-abi3-macosx_11_0_arm64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 172138a0e3151a92f705b68d869627422276d7f4d90e7426a4e0e5ac0df685a6 |
|
MD5 | 905c1d9689c17a798e4072cbde604feb |
|
BLAKE2b-256 | c6acfb68c70b6573e2a9f1cc86ed7910e940d2e7d350c37ce9f1627b911bc642 |
Close
Hashes for rshare-0.1.11-cp38-abi3-macosx_10_7_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | ed04b73f4d8aa0618c88f997b565623ef1f499ea6047b198fbe58fb1fb30d2f5 |
|
MD5 | 6a45c2ea4cf16597cd14c5ec8c2a3eb9 |
|
BLAKE2b-256 | bd63c6ad389850d9621a56252b375601fb383bb56a1113b9fb71f5dbae659bb3 |