hallowed-plastic-91664
01/26/2022, 5:28 AMfast-nail-55400
01/26/2022, 6:03 AMhallowed-plastic-91664
01/26/2022, 2:54 PMhundreds-father-404
01/26/2022, 6:35 PMhallowed-plastic-91664
01/26/2022, 6:44 PMDefine a _scala_protobuf_sources target type with a dependency on its protobuf_sources target. (This would be used internally to wrap generated Scala sources, and would not be exposed to the user.)
target_types.py
?hundreds-father-404
01/27/2022, 1:16 AMhallowed-plastic-91664
01/27/2022, 1:40 AMfast-nail-55400
01/27/2022, 9:44 AMhallowed-plastic-91664
03/30/2022, 12:15 AMhundreds-father-404
03/30/2022, 12:16 AMhallowed-plastic-91664
03/30/2022, 12:16 AMhundreds-father-404
03/30/2022, 12:18 AMpants.backend.experimental.codegen.protobuf.go
will have tailor
add protobuf_sources
options for you
We still need to add docs for this new feature, but I think other than activating the backend & running tailor
, you need to make sure each relevant file sets option go_package
, and then I think your go.mod
and go.sum
include the relevant modules like <http://github.com/golang/protobuf|github.com/golang/protobuf>
fast-nail-55400
03/30/2022, 12:33 AMhallowed-plastic-91664
03/30/2022, 2:04 AMpants.backend.experimental.codegen.protobuf.go
backend but reports a “ModuleNotFoundError”
[GLOBAL]
pants_version = "2.11.0rc1"
backend_packages = [
"pants.backend.experimental.go",
"pants.backend.experimental.codegen.protobuf.go"
]
[golang]
expected_version = "1.18"
Traceback (most recent call last):
File "/Users/cest-la-vie/.cache/pants/setup/bootstrap-Darwin-x86_64/pants.rHDk1N/install/lib/python3.9/site-packages/pants/init/extension_loader.py", line 130, in load_backend
module = importlib.import_module(backend_module)
File "/usr/local/Cellar/python@3.9/3.9.12/Frameworks/Python.framework/Versions/3.9/lib/python3.9/importlib/__init__.py", line 127, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "<frozen importlib._bootstrap>", line 1030, in _gcd_import
File "<frozen importlib._bootstrap>", line 1007, in _find_and_load
File "<frozen importlib._bootstrap>", line 972, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 228, in _call_with_frames_removed
File "<frozen importlib._bootstrap>", line 1030, in _gcd_import
File "<frozen importlib._bootstrap>", line 1007, in _find_and_load
File "<frozen importlib._bootstrap>", line 984, in _find_and_load_unlocked
ModuleNotFoundError: No module named 'pants.backend.experimental.codegen.protobuf.go'
08:52:53.67 [ERROR] Failed to load the pants.backend.experimental.codegen.protobuf.go.register backend: ModuleNotFoundError("No module named 'pants.backend.experimental.codegen.protobuf.go'")
fast-nail-55400
04/01/2022, 2:10 PM