You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Neither scalapb.ScalaPbCodeGenerator.run() (ScalaPB <= 0.9.8) nor scalapb.ScalaPbCodeGenerator.process() (ScalaPB >= 0.11.17) catch Throwable and convert it to an error response. When an exception occurs, the Future running either of these methods fails to resolve. It never writes a response to the protoc-bridge pipe, causing builds to hang.
I've opened bazelbuild/rules_scala#1648, which contains bazelbuild/rules_scala@de8214b. That commit contains wrappers for both scalapb.ScalaPbCodeGenerator implementations that catch Throwable and allow the build to fail with an error.
If it's desirable, I'm happy to contribute these changes, or a better implementation if suggested, to ScalaPB itself (for any or all of the 0.9.x, 0.11.x, and 1.0.x branches).
Background: I've been Bzlmodifying rules_scala per bazelbuild/rules_scala#1482, and as a side quest, I've diagnosed hanging build issues related to ScalaPB in bazelbuild/rules_scala#1647. That issue contains extensive details, and has a table at the top showing which versions of ScalaPB are compatible with which versions of Scala and the protobuf Bazel module.
The text was updated successfully, but these errors were encountered:
Neither
scalapb.ScalaPbCodeGenerator.run()
(ScalaPB <= 0.9.8) norscalapb.ScalaPbCodeGenerator.process()
(ScalaPB >= 0.11.17) catchThrowable
and convert it to an error response. When an exception occurs, theFuture
running either of these methods fails to resolve. It never writes a response to theprotoc-bridge
pipe, causing builds to hang.I've opened bazelbuild/rules_scala#1648, which contains bazelbuild/rules_scala@de8214b. That commit contains wrappers for both
scalapb.ScalaPbCodeGenerator
implementations that catchThrowable
and allow the build to fail with an error.If it's desirable, I'm happy to contribute these changes, or a better implementation if suggested, to ScalaPB itself (for any or all of the 0.9.x, 0.11.x, and 1.0.x branches).
Background: I've been Bzlmodifying
rules_scala
per bazelbuild/rules_scala#1482, and as a side quest, I've diagnosed hanging build issues related to ScalaPB in bazelbuild/rules_scala#1647. That issue contains extensive details, and has a table at the top showing which versions of ScalaPB are compatible with which versions of Scala and the protobuf Bazel module.The text was updated successfully, but these errors were encountered: