Open aherrmann opened 6 months ago
This passes for me:
diff --git a/src/test/java/net/starlark/java/eval/MethodLibraryTest.java b/src/test/java/net/starlark/java/eval/MethodLibraryTest.java
index 933c951b1d..d2d34877b7 100644
--- a/src/test/java/net/starlark/java/eval/MethodLibraryTest.java
+++ b/src/test/java/net/starlark/java/eval/MethodLibraryTest.java
@@ -756,6 +756,7 @@ public final class MethodLibraryTest {
.testIfErrorContains("18", "fail(18)")
.testIfErrorContains("1 2 3", "fail(1, 2, 3)")
.testIfErrorContains("1, 2, 3", "fail(1, 2, 3, sep=', ')")
+ .testIfErrorContains("1 2 3", "fail(*(1, 2, 3))")
.testIfErrorContains("attribute foo: 1 2 3", "fail(1, 2, 3, attr='foo')") // deprecated
.testIfErrorContains("0 1 2 3", "fail(1, 2, 3, msg=0)"); // deprecated
}
I suspect that the root cause is something else here: Maybe the fail
does work, but the resulting failure is swallowed somewhere in the transition logic (the stack trace looks like this) and results in an NPE at a later point?
Description of the bug:
Bazel crashes when
fail()
is applied to a tuple using the splat operator, i.e.fail(*some_tuple)
.Which category does this issue belong to?
No response
What's the simplest, easiest way to reproduce this bug? Please provide a minimal example if possible.
Checkout https://github.com/aherrmann/rules_zig/commit/c2f9bb6b97a6a7b429f99d81dde74167ba61c49a. Then run
Which operating system are you running Bazel on?
Ubuntu 22.04
What is the output of
bazel info release
?release 7.1.1
If
bazel info release
returnsdevelopment version
or(@non-git)
, tell us how you built Bazel.No response
What's the output of
git remote get-url origin; git rev-parse HEAD
?No response
Is this a regression? If yes, please try to identify the Bazel commit where the bug was introduced.
not that I know
Have you found anything relevant by searching the web?
No response
Any other information, logs, or outputs that you want to share?
fail
is invoked here in the example