lang: funcs: dage: Make error clearer

The implementation of the specific function is sending a nil value,
which is not allowed. This is a bug in the code of that function.
This commit is contained in:
James Shubin
2025-06-05 20:36:15 -04:00
parent ac3a131a9f
commit 499b8f2732

View File

@@ -1290,9 +1290,10 @@ func (obj *Engine) Run(ctx context.Context) (reterr error) {
for value := range node.output { // read from channel
if value == nil {
// bug!
obj.Logf("func `%s` got nil value", node)
panic("got nil value")
// bug in implementation of that func!
s := fmt.Sprintf("func `%s` sent nil value", node)
obj.Logf(s)
panic(s)
}
obj.tableMutex.RLock()