fixed missing pyi files in python wheel

This commit is contained in:
Ovizro
2023-08-16 23:02:09 +08:00
parent 4184ed9410
commit 60e1218d40
3 changed files with 11 additions and 2 deletions
+9
View File
@@ -0,0 +1,9 @@
# Byte-compiled / optimized / DLL files
__pycache__/
*.py[cod]
*$py.class
/py_grpc/build/
/py_grpc/dist/
/py_grpc/tinode_grpc/GIT_VERSION
*.egg-info/
+1 -1
View File
@@ -19,6 +19,6 @@ pip install tinode_grpc
Don't modify included files directly. If you want to make changes, you have to install protobuffers tool chain and gRPC then generate the Python bindings from [`pbx/model.proto`](https://github.com/tinode/chat/tree/master/pbx/model.proto) (your path to `model.proto` may be different):
```
python -m grpc_tools.protoc -I../pbx --python_out=. --grpc_python_out=. ../pbx/model.proto
python -m grpc_tools.protoc -I../pbx --python_out=. --pyi_out=. --grpc_python_out=. ../pbx/model.proto
```
The generated `model_pb2_grpc.py` imports `model_pb2.py` as a module instead of a package which is incompatible with python3 packaging system. Use `../pbx/py_fix.py` to apply a fix. This is only needed if you want to repackage the generated files.
+1 -1
View File
@@ -23,7 +23,7 @@ setuptools.setup(
license="Apache 2.0",
keywords="chat messaging messenger im tinode",
package_data={
"": ["GIT_VERSION"],
"": ["GIT_VERSION", "*.pyi"],
},
classifiers=[
"Programming Language :: Python :: 2",