twirp python sdk generator
python-betterproto 生成的代码只能配合 grpc 使用,但生成的 message 确实很香。所以我重写了 service 代码生成逻辑,使其支持 twirp 协议。
我发现可以上传到 pypi,包名是 betterproto-twirp
安装
-
本地源码安装:
pip install .
-
从 pypi 安装:
pip install betterproto-twirp 安装失败的话先安装 pip install 'betterproto-twirp[compiler]'
使用
protoc -I . --python_betterproto_out=. service.proto
Metadata
Release files for betterproto-twirp 1.2.13
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| betterproto-twirp-1.2.13.tar.gz | 177.8 kB | Without provenance | Details for betterproto-twirp-1.2.13.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| betterproto_twirp-1.2.13-py3-none-any.whl | Python 3 | none | any | Details for betterproto_twirp-1.2.13-py3-none-any.whl |
Total release size: 391.5 kB
Release files / betterproto-twirp-1.2.13.tar.gz
| Download URL | betterproto-twirp-1.2.13.tar.gz |
|---|---|
| Size | 177.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
1d311e167977d02711e775d017d7e96d077114b868a51f76241e97a54fd96134
|
|
BLAKE2b-256 checksum How to use checksums |
1880c4f126050a760aa1977a3fce0ca773c68a802a4fa0371fb1521d271e8d54
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.2.0 pkginfo/1.5.0.1 requests/2.23.0 setuptools/40.6.2 requests-toolbelt/0.9.1 tqdm/4.48.2 CPython/3.6.8
|
Release files / betterproto_twirp-1.2.13-py3-none-any.whl
| Download URL | betterproto_twirp-1.2.13-py3-none-any.whl |
|---|---|
| Size | 213.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
676848b15b4337746b899b2b4c68eb8298bfb2ef64aec277c902bc978cfd9c28
|
|
BLAKE2b-256 checksum How to use checksums |
2d76c06e75973014b56aa9c477aab3c6e4f34ac42db59f940eecbd52d7bd8525
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.2.0 pkginfo/1.5.0.1 requests/2.23.0 setuptools/40.6.2 requests-toolbelt/0.9.1 tqdm/4.48.2 CPython/3.6.8
|
Security for betterproto-twirp 1.2.13
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.