mirror of
https://github.com/open-policy-agent/opa.git
synced 2026-08-24 09:15:31 -06:00
wasm_sdk: non-halt topdown errors in host-builtins are 'undefined' (#3321)
Before, the consequence of a non-halt host-builtin error was that the entire eval result was undefined. Now, only the result of evaluating the builtin itself is undefined. Fixes #3320. Signed-off-by: Stephan Renatus <stephan.renatus@gmail.com>
This commit is contained in:
+12
@@ -0,0 +1,12 @@
|
||||
cases:
|
||||
- data:
|
||||
modules:
|
||||
- |
|
||||
package test
|
||||
foo = units.parse_bytes("1KB")
|
||||
bar = units.parse_bytes("foo") # undefined
|
||||
note: functionerrors/undefined builtin result
|
||||
query: data.test = x
|
||||
want_result:
|
||||
- x:
|
||||
foo: 1000
|
||||
Reference in New Issue
Block a user