Closed lunactic closed 7 years ago
+1 , would expect to redirect job to stdout not stderr. stderr should only container ERROR related info. Furthermore some tools (galaxy...) consider a job failure if there is something is stderr (though can be configured not to do so...). Same in other places https://github.com/common-workflow-language/cwltool/blob/cf18555dec2be1943f6e27dd4235c00b7571d656/cwltool/job.py#L524
Hello @lunactic and thank you for your issue report.
The only output to stdout from a CWL runner should be the resulting output object. Here is a meta-description of our expectations for cwl-runner
s: https://github.com/common-workflow-language/common-workflow-language/pull/278/files#diff-ee814a9c027fc9750beb075c283a973cR41
If you need to process the output from the underlying tool you are welcome to capture the tool's stdout
via the CWL tool definition itself: http://www.commonwl.org/user_guide/05-stdout/
Thank you for this answer. With this I was actually able to figure out what I needed to do .
Expected Behavior
Tell us what should happen
I am using nodejs / typescript to run the cwltool with code like this:
I would expect that logging information about running the cwltool would be logged for me stating with "STDOUT", as it would be logged to the standard output.
Actual Behavior
When I run the cwltool like this:
cwltool --outdir /data_test/results/fuzzybighearteddotterel/data_0/ --debug --tmp-outdir-prefix /data_test/output/ --tmpdir-prefix /data_test/tmp/ --workdir /input /data_test/executables/evaluation/icdar2017hisdoclayoutcomplayoutevaluationtest/1/8d7ba5fdcdedc7908370924b366d266fc4c996e2.cwl /data_test/results/fuzzybighearteddotterel/data_0/data_0.yaml
My logging output looks like this:
So all logging information is sent to the stderr output. This seems to be the default behaviour as it is set here: https://github.com/common-workflow-language/cwltool/blob/9e1112fc7b1f08197b696be77bae6069034ba8eb/cwltool/job.py#L458
I wonder if this behaviour is intentional, and what would be the proper way to handle this differently.
Your Environment