Skip to main content

Fast rustup shims for python

Project description

[!WARNING] Always check the repository for latest readme information.

Rustbin

Fast rustup shims for python



🔥 Description

Rustbin provides rustup and all of its proxies cargo, rustc.. (1) (2) in a convenient python package.

# After installation
$ tree .venv
.venv
├── bin
   ├── cargo
   ├── rustc
   └── rustup-init
(...)

✅ Also check out Rustman, for python methods, easy cross compilation, management and automation!

Note: This is a community repackaging effort with no affiliation to the Rust project.

📦 Installation

Rustbin is available on PyPI and can be added to your pyproject.toml or pip installed directly:

[project]
dependencies = ["rustbin"]

Versioning of the package will follow:

  • Same as rustup, without rushes to match all upstream releases (at least a month stable).
  • Broken releases might be deleted and re-uploaded as 'post' within a week, if needed.
  • New platforms might be added post-release at any time, and with no version bump.
  • Ancient versions might be removed to save space, in case a size grant is not given.

[!IMPORTANT]

As mapping system information from Python/Wheels to a Rust Triple is non-trivial, and that the package needs rust to build from source, attempting to pip install on "unknown" platforms without prebuilt wheels on pypi will make an empty one from source without rustup or shims.

Your best path is to install rustup externally in such cases, this package essentially becomes a no-op.

Open issues to tell interest in platforms that are actually used, so the package doesn't balloon in size!

🚀 Speeds

Rustbin bundles a small (rust) program to spawn shims faster than [project.scripts] ever could:

✅ Less than a millisecond overhead, compared to ~105ms for a python script

# Note: /bin/cargo is effectively a zero-cost symlink
$ RUSTUP_FORCE_ARG0=cargo hyperfine /bin/rustup
  Time (mean ± σ):      30.6 ms ±   0.8 ms    [User: 21.5 ms, System: 8.9 ms]
  Range (min  max):    29.5 ms   36.0 ms    100 runs

# Shims calling .venv/bin/rustup-init
$ hyperfine .venv/bin/cargo
  Time (mean ± σ):      31.2 ms ±   0.4 ms    [User: 21.7 ms, System: 9.2 ms]
  Range (min  max):    30.5 ms   32.7 ms    100 runs

Note: Full benchmark command was nice -20 taskset -c 2 hyperfine -w 50 -r 100 -N (command)

⚖️ License

Rustbin is dual-licensed under the MIT or Apache-2.0 license, at your option.

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

rustbin-1.28.2.tar.gz (10.5 kB view details)

Uploaded Source

Built Distributions

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

rustbin-1.28.2-py3-none-win_arm64.whl (7.2 MB view details)

Uploaded Python 3Windows ARM64

rustbin-1.28.2-py3-none-win_amd64.whl (8.3 MB view details)

Uploaded Python 3Windows x86-64

rustbin-1.28.2-py3-none-musllinux_2_17_x86_64.whl (10.9 MB view details)

Uploaded Python 3musllinux: musl 2.17+ x86-64

rustbin-1.28.2-py3-none-manylinux_2_17_x86_64.whl (10.6 MB view details)

Uploaded Python 3manylinux: glibc 2.17+ x86-64

rustbin-1.28.2-py3-none-manylinux_2_17_i686.whl (10.0 MB view details)

Uploaded Python 3manylinux: glibc 2.17+ i686

rustbin-1.28.2-py3-none-manylinux_2_17_aarch64.whl (10.5 MB view details)

Uploaded Python 3manylinux: glibc 2.17+ ARM64

rustbin-1.28.2-py3-none-macosx_11_0_arm64.whl (7.1 MB view details)

Uploaded Python 3macOS 11.0+ ARM64

rustbin-1.28.2-py3-none-macosx_10_9_x86_64.whl (7.7 MB view details)

Uploaded Python 3macOS 10.9+ x86-64

File details

Details for the file rustbin-1.28.2.tar.gz.

File metadata

  • Download URL: rustbin-1.28.2.tar.gz
  • Upload date:
  • Size: 10.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.9.4

File hashes

Hashes for rustbin-1.28.2.tar.gz
Algorithm Hash digest
SHA256 409718d5b72efb3fc8d2dd17ca60f5aa659d235be1d6fc720c5e37bb37da85c4
MD5 f887b71019592bab3c22ad83bcdab2b7
BLAKE2b-256 63d8a6d3af4dbe38e9ec45e9641e93185fce77c0ad3b487a713306e02882efa8

See more details on using hashes here.

File details

Details for the file rustbin-1.28.2-py3-none-win_arm64.whl.

File metadata

File hashes

Hashes for rustbin-1.28.2-py3-none-win_arm64.whl
Algorithm Hash digest
SHA256 897c0f5e6a7b7785a4876af97db9ae1f87d0e60a927b920e99e7252b874e019b
MD5 33028413ca23b3d5aaab85c22c72e788
BLAKE2b-256 202c9438e07664cd768f12ea6de278f712c7ccf115916f39b2c1a47a51603361

See more details on using hashes here.

File details

Details for the file rustbin-1.28.2-py3-none-win_amd64.whl.

File metadata

  • Download URL: rustbin-1.28.2-py3-none-win_amd64.whl
  • Upload date:
  • Size: 8.3 MB
  • Tags: Python 3, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.9.4

File hashes

Hashes for rustbin-1.28.2-py3-none-win_amd64.whl
Algorithm Hash digest
SHA256 b071f25b286ff3594201b033836b7c0233cd58ffdf7145a34b746d79b2720ec4
MD5 d99b492951d4f57fcbd08c4799c89302
BLAKE2b-256 d4d8a5bd2ed6fa56b2c40807ddf34917387eb4f6d568255fe38cabaffe8b0852

See more details on using hashes here.

File details

Details for the file rustbin-1.28.2-py3-none-musllinux_2_17_x86_64.whl.

File metadata

File hashes

Hashes for rustbin-1.28.2-py3-none-musllinux_2_17_x86_64.whl
Algorithm Hash digest
SHA256 5a1b4bde111ae41f691707d110e9553aa0e18ace95b5727167e4e2f5ed4a8958
MD5 29e1baa26104934715176c8084398c48
BLAKE2b-256 95033c05460434bb061e267e5f03f30413a72138f830f70cc455acca03b4e8d2

See more details on using hashes here.

File details

Details for the file rustbin-1.28.2-py3-none-manylinux_2_17_x86_64.whl.

File metadata

File hashes

Hashes for rustbin-1.28.2-py3-none-manylinux_2_17_x86_64.whl
Algorithm Hash digest
SHA256 e309d30311248ca3bb506a14f8ed6829bde39d5dc185942915a33ac7443e4113
MD5 c45de8f27fb6a17c591e7b32a8c2b6d7
BLAKE2b-256 7123ec3bb0860a7bed7c2cd89aaab28f6dfc5a5c11cc28ab8e00a80f3a1717fb

See more details on using hashes here.

File details

Details for the file rustbin-1.28.2-py3-none-manylinux_2_17_i686.whl.

File metadata

File hashes

Hashes for rustbin-1.28.2-py3-none-manylinux_2_17_i686.whl
Algorithm Hash digest
SHA256 a72bf6342aa3ff5a11b95158261e0e9b1256982125436955665a7635401cfc3c
MD5 51f57a9e0d316b3481c9c1405f2f8134
BLAKE2b-256 cd743232a3c2bc927b6f6723d9b7f762b98a7936502601e46bd90ce538860935

See more details on using hashes here.

File details

Details for the file rustbin-1.28.2-py3-none-manylinux_2_17_aarch64.whl.

File metadata

File hashes

Hashes for rustbin-1.28.2-py3-none-manylinux_2_17_aarch64.whl
Algorithm Hash digest
SHA256 5272ed5b1cba1258aa7d4da3ca4866fddf1d48eb4885919630b3d13743fc9c57
MD5 a5c682c4f9d85dd1c12dd404836e84af
BLAKE2b-256 e20de4e6601caeaeab3b84cdf73e28f77d4b9697869399c6405c5d3c149249c8

See more details on using hashes here.

File details

Details for the file rustbin-1.28.2-py3-none-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for rustbin-1.28.2-py3-none-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 ee395662a1178ec224f55e7baf1bb74f8aeaf2371bd3146c21126a6fb85640fb
MD5 c01be8575e2bfa1cb716dc4d6c64068f
BLAKE2b-256 83e6b5d40b81161628f8871bc1ab07437a5e6cae478def3d6f28b0afddef13ec

See more details on using hashes here.

File details

Details for the file rustbin-1.28.2-py3-none-macosx_10_9_x86_64.whl.

File metadata

File hashes

Hashes for rustbin-1.28.2-py3-none-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 a32c5197e29b2ee19d35ea8a3b33b10265fc17d8007290eed7e1cabeb8a2f9dd
MD5 107c5835844053161563ee38f4361762
BLAKE2b-256 9de32e3b6e988430806f5290db75aee7b4e05d8ee32aa563d31376e526369162

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