Open leozc opened 2 months ago
This is because the Python protobuf plugin is inferring a dependency from the protobuf_sources
target to the protobuf
distribution, and then the Java backend is trying to build a classpath entry out of this, and obviously cannot.
As a workaround you can turn the dep inference off with
[python-protobuf]
infer_runtime_dependency = false
in pants.toml. But then your Python side may not work, and you'll have to manually add back that dep from the relevant python_sources
so it gets pulled in. Again, this is just a workaround until I figure out something more robust.
@leozc can you add some python code that uses the python-generated protobuf code (generated from the same Event.proto) to the example repo? I'd like to see more closely how those interact.
will do
@leozc best to @ me here and/or on Slack when this is ready, thanks!
Describe the bug A python protobuf_sources dependency is checked, and reported error by JVM
Pants version https://github.com/leozc/test_pants_proto/blob/main/README.md
OS MacOs, Apple Silicon
Additional info https://github.com/leozc/test_pants_proto/blob/main/README.md