bazel test //... --test_output=all --sandbox_debug
INFO: Analyzed 5 targets (0 packages loaded, 0 targets configured).
INFO: Found 4 targets and 1 test target...
FAIL: //tools/thing:mypy_test_foo (see /private/var/tmp/_bazel_jonathon/fafac219b6b0ff0ed453a7d553f169f1/execroot/bazel_mypy_integration_issue_36/bazel-out/darwin-fastbuild/testlogs/tools/thing/mypy_test_foo/test.log)
INFO: From Testing //tools/thing:mypy_test_foo:
==================== Test output for //tools/thing:mypy_test_foo:
tools/thing/proto/bling_api_pb2.pyi:26: error: syntax error in type comment [syntax]
In the internal code that hit this issue, the error is:
Use --sandbox_debug to see verbose messages from the sandbox
tools/foo/proto/foo_api_pb2.py: error: Duplicate module named 'tools.foo.proto.foo_api_pb2' (also at 'tools/foo/proto/foo_api_pb2.pyi')
Found 1 error in 1 file (errors prevented further checking)
INFO: Elapsed time: 2.294s, Critical Path: 1.98s
INFO: 5 processes: 5 internal.
FAILED: Build did NOT complete successfully
Is there a workaround for this? this prevents me from using mypy build-time aspect checks because it breaks as soon as I introduce a protobuf + python target with this error.
Reproduction in https://github.com/thundergolfer/bazel-python-mypy-protobuf/tree/master/bazel_mypy_integration_issue_36
I'm getting:
In the internal code that hit this issue, the error is:
In that internal error, the integration should be letting the
.pyi
file 'win', as is stated in the documentation: https://mypy.readthedocs.io/en/stable/stubs.html#:~:text=Mypy%20uses%20stub%20files%20stored,to%20type%20check%20your%20code.