Comments (3)
Hi @drtechniko thanks for trying this out. I've been looking for a solution to pull in python dependencies from pypi within bazel. There is not an existing solution yet, but @yugui is making good headway with https://github.com/gengo/rules_pypi.
My experiments with this so far show that it is possible to pull in the grpcio python dependency with rules_pypi, but I have to hack the source to not disable platform-specific compilation, and even then I'm getting import errors related to cython or something like that. Bottom line: not working yet.
The workaround is that you have to pip install grpcio
on your local python install to make it globally available. Also, there were a few bugs in my example that have hopefully been fixed with 342e241. If you upgrade to this version I'd be interested to hear your results.
Note that rules_protobuf is not testing the examples/helloworld/python
rules in travis due to it's experimental nature.
from rules_protobuf.
Note that experimental support for rules_pypi is on that branch (not yet functional): https://github.com/pubref/rules_protobuf/tree/rules_pypi
from rules_protobuf.
Thank you. Unfortunately I didn't get notified for some reason by github that you updated the ticket so I spent today to work around this to get moving in building my code using setup.py to generate protobufs. I also spent many hours using the gengo/rules_pypi to install grpcio. But I had no luck. They were also not working for me due to compilation errors in Python.h (tried it on a Docker from scratch to make sure my local env was not corrupted). I'm going to give this a shot again tomorrow with your new commit and see how it works. I can survive with having to install grpcio manually for now.
Also, I'm new to Bazel but I'd like to contribute PRs to the project. I expect our teams to use grpc with python extensively. If you have any suggestions on where to get started let me know.
from rules_protobuf.
Related Issues (20)
- Can't build GRPC when using cpp_proto_repositories HOT 5
- py_proto_library fails when taking input from a genrule HOT 1
- Not work with rules_go v0.13.0 HOT 3
- Dart support? HOT 4
- Go rules HOT 1
- Can't resolve @go_googleapis//google/api HOT 1
- Custom protoc generators HOT 1
- using imports in py_proto_compile fails: _pb2.py and pb2_grpc.py not created HOT 1
- gogo_proto_library with the "well known types" (google/protobuf) HOT 12
- Non repeatable build for grpc_cli HOT 1
- Update rules_protobuf to rules_go 0.16.0 HOT 7
- Addition of protoc-gen-grpc-web HOT 2
- 32-bit C++ compilation HOT 3
- including well known protos in ruby_proto_compile HOT 4
- support latest grpc version HOT 1
- Bazel deprecated native http_archive rule HOT 2
- Unable to load package for 'org_pubref_rules_protobuf/java/rules.bzl' HOT 1
- name 'FileType' is not defined HOT 2
- BUG: Error in label: label() got unexpected keyword argument 'single_file' HOT 2
- file '//protobuf:rules.bzl' does not contain symbol 'proto_compile'
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from rules_protobuf.