[grpc-io] Re: How to use/distribute proto files in Python packages

2022-12-14 Thread Shareef Jalloq
Looks like this has been an issue since 2014 with various work arounds and hacks. https://github.com/protocolbuffers/protobuf/issues/1491 On Tuesday, 13 December 2022 at 14:24:31 UTC Shareef Jalloq wrote: > I can hack this to work by prepending sys.path but that feels horrible: > > #

[grpc-io] Re: How to use/distribute proto files in Python packages

2022-12-13 Thread Shareef Jalloq
I can hack this to work by prepending sys.path but that feels horrible: # __init__.py import os, sys sys.path.insert(0, os.path.dirname(__file__)) On Tuesday, 13 December 2022 at 14:09:26 UTC Shareef Jalloq wrote: > At the moment I've started with the following directory structure: >

[grpc-io] Re: How to use/distribute proto files in Python packages

2022-12-13 Thread Shareef Jalloq
a package using the auto-generated Python. On Tuesday, 13 December 2022 at 11:07:06 UTC Shareef Jalloq wrote: > Hi all, > > this is more of a request for best practice advice. > > I'm trying to work out how to use proto files across projects. I've seen > examples of

[grpc-io] How to use/distribute proto files in Python packages

2022-12-13 Thread Shareef Jalloq
Hi all, this is more of a request for best practice advice. I'm trying to work out how to use proto files across projects. I've seen examples of people suggesting to submodule in the proto files to all projects that use them. That works nicely for most use cases where you have a pure Git

[grpc-io] Is there a way to install gRPC via CMake without requiring sudo?

2022-12-13 Thread Shareef Jalloq
I'm working in an environment where we don't always have sudo access, managed remote compute clusters, and trying to install locally via CMake. However, passing CMAKE_INSTALL_PREFIX works for all dependencies aside from zlib. Is that by design or is there a way to override it and force

[grpc-io] Re: How to build archive libraries using bazel?

2022-12-07 Thread Shareef Jalloq
After doing some more research, this is just a limitation of Bazel. To work around it I found a nice rule that can build a static library: https://gist.github.com/shareefj/4e314b16148fded3a8ec874e71b07143 On Monday, 5 December 2022 at 16:10:02 UTC Shareef Jalloq wrote: > Hi, > > I

[grpc-io] Re: Linker error when compiling callback example

2022-12-05 Thread Shareef Jalloq
was assuming that I just needed to pass this archive to my top level compilation flow but it seems that I need the archive AND all service.grpc.pb.{cc,h} and service.pb.{cc,h} files. On Monday, 28 November 2022 at 18:30:48 UTC Shareef Jalloq wrote: > Sorry, I fixed the missing reflection library, i

[grpc-io] How to build archive libraries using bazel?

2022-12-05 Thread Shareef Jalloq
Hi, I'm trying to generate all the required C++ archive libraries for grpc++ but can't find them after running bazel build :all and I don't see any standout target names. How do I do this? Building with CMake works but I'm trying to use Bazel. -- You received this message because you are

[grpc-io] Re: Linker error when compiling callback example

2022-11-28 Thread Shareef Jalloq
Sorry, I fixed the missing reflection library, it's jus the helloworld::Greeter::Service::Service() issues. But these are defined in the auto-generated output of the protocol buffer compiler. On Monday, 28 November 2022 at 18:13:54 UTC Shareef Jalloq wrote: > Hi, > > I've be

[grpc-io] Linker error when compiling callback example

2022-11-28 Thread Shareef Jalloq
Hi, I've been trying to integrate the simple C++ callback example into my application to make sure I can compile it successfully before implementing my full protocol. However, I'm getting linker errors and can't spot what I might have missed. I've really just copied the

[grpc-io] C++: how to handle blocking code from callback reactor

2022-11-23 Thread Shareef Jalloq
Hi, I'm new to gRPC and am struggling to find examples of how to call application code that blocks when using the callback API. I found the documentation here: https://github.com/grpc/proposal/blob/master/L67-cpp-callback-api.md and noted that it recommend that code in any reaction must not