Small project developed by me to learn PyO3 library.
Project description
Rython
To build local package use
maturin develop --release
Use text_signature to create python type
/// Formats the sum of two numbers as string.
#[pyfunction(text_signature = "(a: int, b: int) -> str")]
fn sum_as_string(a: usize, b: usize) -> PyResult<String> {
Ok((a + b).to_string())
}
Add .pyi file using mypy
Keep in mind that is only works for #[pyfunction]. Macros like #[pyclass] and #[pymethods] are still unsupported.
For autocompletion .pyi in bash type:
stubgen -p rython.calc -o python
It will produce calc.pyi with:
def sum_as_string(a: int, b: int) -> str: ...
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
Built Distributions
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file rython_calc-0.5.3.tar.gz.
File metadata
- Download URL: rython_calc-0.5.3.tar.gz
- Upload date:
- Size: 20.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: maturin/1.7.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3fbe231b3376b5a44a96be9826760ed856fe49ca399429ec81f4c8db7f4d6c49
|
|
| MD5 |
1d37a4393026daa923e7294c758794a5
|
|
| BLAKE2b-256 |
9e6ce3b8786499e55740b9a075dc58fd3bd55e0aad53b355673f88ee1c6030af
|
File details
Details for the file rython_calc-0.5.3-cp312-none-win_amd64.whl.
File metadata
- Download URL: rython_calc-0.5.3-cp312-none-win_amd64.whl
- Upload date:
- Size: 121.4 kB
- Tags: CPython 3.12, Windows x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: maturin/1.7.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6b3d7aa6c5cbb59f85de03d2736a31d83f48223b78569bdace35cd1c94cdc4d6
|
|
| MD5 |
2362cde88fc07c9eec86f1b1bc128949
|
|
| BLAKE2b-256 |
2219f9f3e7c51710a3521ef2f5e51c56b8b70dd031f595c1d6360b89f11aa164
|
File details
Details for the file rython_calc-0.5.3-cp312-none-win32.whl.
File metadata
- Download URL: rython_calc-0.5.3-cp312-none-win32.whl
- Upload date:
- Size: 116.0 kB
- Tags: CPython 3.12, Windows x86
- Uploaded using Trusted Publishing? Yes
- Uploaded via: maturin/1.7.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5e0534038b5bc4ed4e11a55671ff4b9c7da244966b50f4b8ab2309699495d3fb
|
|
| MD5 |
ae8db78f3b3b0d5fe6e36b4f3cdf13d8
|
|
| BLAKE2b-256 |
a1201352e8f8414e648388a3eaad8141a303664837faae703e0f3bb1a71eb688
|
File details
Details for the file rython_calc-0.5.3-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.
File metadata
- Download URL: rython_calc-0.5.3-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
- Upload date:
- Size: 234.8 kB
- Tags: CPython 3.12, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: maturin/1.7.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c7fa96531acd491cf636a6ac1544aa662d4d8f3504268323fe1f4ee6b2c07278
|
|
| MD5 |
301ca4be1d29e6fa952660688ee7935f
|
|
| BLAKE2b-256 |
24f63106326cb0325387871ac842ef1083698a7a5a5d5b7c365ce91e65eac333
|
File details
Details for the file rython_calc-0.5.3-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl.
File metadata
- Download URL: rython_calc-0.5.3-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl
- Upload date:
- Size: 314.9 kB
- Tags: CPython 3.12, manylinux: glibc 2.17+ s390x
- Uploaded using Trusted Publishing? Yes
- Uploaded via: maturin/1.7.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
84e837d16852d8ba8549579b1e20dd7ed1473479fc945e0c620e5f0aca87050d
|
|
| MD5 |
41b0f9a4121c3f3fbcaf722fbc0e660a
|
|
| BLAKE2b-256 |
4aca0dbb1aa529d05058ebcfe6a373378c58d5667da8955b78251d6d44610cca
|
File details
Details for the file rython_calc-0.5.3-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl.
File metadata
- Download URL: rython_calc-0.5.3-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl
- Upload date:
- Size: 261.3 kB
- Tags: CPython 3.12, manylinux: glibc 2.17+ ppc64le
- Uploaded using Trusted Publishing? Yes
- Uploaded via: maturin/1.7.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ca75a3943a9286a8c52368c46ad51388dda0c51a5e587aa896a7df95f98b5499
|
|
| MD5 |
5acacab31f2d14e547d8138d2dcef33f
|
|
| BLAKE2b-256 |
fd9ea579617e75dce68c7882594bcd20d3442fb1fca8ed502993120bf76436f4
|
File details
Details for the file rython_calc-0.5.3-cp312-cp312-manylinux_2_17_armv7l.manylinux2014_armv7l.whl.
File metadata
- Download URL: rython_calc-0.5.3-cp312-cp312-manylinux_2_17_armv7l.manylinux2014_armv7l.whl
- Upload date:
- Size: 245.9 kB
- Tags: CPython 3.12, manylinux: glibc 2.17+ ARMv7l
- Uploaded using Trusted Publishing? Yes
- Uploaded via: maturin/1.7.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3eab5be4a9f97ede9badacd8ecebc755fb0264462d17a73d0a7ac42bf714ecd6
|
|
| MD5 |
7acae30f628fa789f94ca66eddb0b4fd
|
|
| BLAKE2b-256 |
49f99c3cb19207e26260e4053919d2ecb28c9a3fbaa89fa4cde7af056458c0f6
|
File details
Details for the file rython_calc-0.5.3-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.
File metadata
- Download URL: rython_calc-0.5.3-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
- Upload date:
- Size: 232.0 kB
- Tags: CPython 3.12, manylinux: glibc 2.17+ ARM64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: maturin/1.7.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
b857846ab75da195a018f5a420b1f77c4302adbe33e7fc56ee7a44019072ecf0
|
|
| MD5 |
3599e5ff036714b3d8ef0cc58c42a1be
|
|
| BLAKE2b-256 |
7c5d6d8bbd1e7b820c3a9ce69172aae3f0555ac1c5acfd1c9334e943cb592509
|
File details
Details for the file rython_calc-0.5.3-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.whl.
File metadata
- Download URL: rython_calc-0.5.3-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.whl
- Upload date:
- Size: 248.5 kB
- Tags: CPython 3.12, manylinux: glibc 2.5+ i686
- Uploaded using Trusted Publishing? Yes
- Uploaded via: maturin/1.7.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6e6da293fcc72cb1912e83f6de2cc531a33fc8fcf174259e75cdeb9f706da86f
|
|
| MD5 |
55c63032332dcd49dd9e9ce5bb9328ee
|
|
| BLAKE2b-256 |
5dbfd89714ffb62789ad6b0307687c9d14cbc49bae1c6d9dfb28f3639dc796b6
|
File details
Details for the file rython_calc-0.5.3-cp312-cp312-macosx_11_0_arm64.whl.
File metadata
- Download URL: rython_calc-0.5.3-cp312-cp312-macosx_11_0_arm64.whl
- Upload date:
- Size: 211.0 kB
- Tags: CPython 3.12, macOS 11.0+ ARM64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: maturin/1.7.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
1b948c2e7843dbb83128357568e3fe49bbae7c1aa92e07e5eb9921de2dd03f60
|
|
| MD5 |
2650d76ab25b0de3377d93eb78788dda
|
|
| BLAKE2b-256 |
c414efa3ff30e04c357ca5a451accd5753e167ce00f673222c5cd9142f81b681
|
File details
Details for the file rython_calc-0.5.3-cp312-cp312-macosx_10_12_x86_64.whl.
File metadata
- Download URL: rython_calc-0.5.3-cp312-cp312-macosx_10_12_x86_64.whl
- Upload date:
- Size: 218.1 kB
- Tags: CPython 3.12, macOS 10.12+ x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: maturin/1.7.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
10a7d581be2403a1731fdd89d8284299063a9e6adf24e865c37e3fd7938ea528
|
|
| MD5 |
6ef1ecc2b32a72260133c74d504b2bb6
|
|
| BLAKE2b-256 |
e4daafd83e6745e7ff37870ff23cc4355c1b855aa6e762816f4afc69c3ea27e5
|