[Swift-devel] Could not convert value to boolean: null

David Kelly davidk at ci.uchicago.edu
Tue Nov 1 14:38:23 CDT 2011


I've noticed that with 0.93, I will occasionally see this error message "Could not convert value to boolean: null." The error is sporadic. It happens in maybe 1 out of every 50 attempts. When the error occurs, it happens immediately and exits. I've seen this with a few different scripts, but here is one from the test suite that just failed.

0723-simplemapper-nopadding.swift
----
type messagefile;

(messagefile t) write() { 
    app {
        echo @filename(t) stdout=@filename(t);
    }
}

messagefile outfile[] <simple_mapper;
                     prefix="0723-simplemapper-nopadding.",
                     suffix=".out",
                     padding="0">;

outfile[0] = write();
outfile[5] = write();
outfile[75943] = write();
---

I added a dumpStack() to location that was printing the error to get a little more detail.
----
Swift svn swift-r5262 cog-r3314 (cog modified locally)

RunID: 20111101-1414-r4ut0gjf
Progress:  time: Tue, 01 Nov 2011 14:14:08 -0500
java.lang.Exception: Stack trace
	at java.lang.Thread.dumpStack(Thread.java:1249)
	at org.globus.cog.karajan.util.TypeUtil.toBoolean(TypeUtil.java:127)
	at org.griphyn.vdl.karajan.lib.Mark.function(Mark.java:30)
	at org.griphyn.vdl.karajan.lib.VDLFunction.post(VDLFunction.java:62)
	at org.globus.cog.karajan.workflow.nodes.AbstractSequentialWithArguments.completed(AbstractSequentialWithArguments.java:194)
	at org.globus.cog.karajan.workflow.nodes.FlowNode.complete(FlowNode.java:214)
	at org.globus.cog.karajan.workflow.nodes.FlowContainer.post(FlowContainer.java:58)
	at org.globus.cog.karajan.workflow.nodes.functions.AbstractFunction.post(AbstractFunction.java:28)
	at org.globus.cog.karajan.workflow.nodes.Sequential.startNext(Sequential.java:29)
	at org.globus.cog.karajan.workflow.nodes.Sequential.executeChildren(Sequential.java:20)
	at org.globus.cog.karajan.workflow.nodes.FlowContainer.execute(FlowContainer.java:63)
	at org.globus.cog.karajan.workflow.nodes.FlowNode.restart(FlowNode.java:139)
	at org.globus.cog.karajan.workflow.nodes.FlowNode.start(FlowNode.java:197)
	at org.globus.cog.karajan.workflow.FlowElementWrapper.start(FlowElementWrapper.java:227)
	at org.globus.cog.karajan.workflow.events.EventBus.start(EventBus.java:104)
	at org.globus.cog.karajan.workflow.events.EventTargetPair.run(EventTargetPair.java:40)
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
	at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
	at java.util.concurrent.FutureTask.run(FutureTask.java:138)
	at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
	at java.lang.Thread.run(Thread.java:662)
Execution failed:
	Could not convert value to boolean: null
-----

It looks like the error is somehow related to Karajan getting null values from the stack. I have this as bug 585 (https://bugzilla.mcs.anl.gov/swift/show_bug.cgi?id=585)

David



More information about the Swift-devel mailing list