{"action":"created","issue":{"url":"https://api.github.com/repos/Duke-GCB/lando/issues/96","repository_url":"https://api.github.com/repos/Duke-GCB/lando","labels_url":"https://api.github.com/repos/Duke-GCB/lando/issues/96/labels{/name}","comments_url":"https://api.github.com/repos/Duke-GCB/lando/issues/96/comments","events_url":"https://api.github.com/repos/Duke-GCB/lando/issues/96/events","html_url":"https://github.com/Duke-GCB/lando/issues/96","id":273533511,"number":96,"title":"cwlreport.py expects `path` in file objects, may be `location`","user":{"login":"dleehr","id":2752599,"avatar_url":"https://avatars3.githubusercontent.com/u/2752599?v=4","gravatar_id":"","url":"https://api.github.com/users/dleehr","html_url":"https://github.com/dleehr","followers_url":"https://api.github.com/users/dleehr/followers","following_url":"https://api.github.com/users/dleehr/following{/other_user}","gists_url":"https://api.github.com/users/dleehr/gists{/gist_id}","starred_url":"https://api.github.com/users/dleehr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dleehr/subscriptions","organizations_url":"https://api.github.com/users/dleehr/orgs","repos_url":"https://api.github.com/users/dleehr/repos","events_url":"https://api.github.com/users/dleehr/events{/privacy}","received_events_url":"https://api.github.com/users/dleehr/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":{"login":"dleehr","id":2752599,"avatar_url":"https://avatars3.githubusercontent.com/u/2752599?v=4","gravatar_id":"","url":"https://api.github.com/users/dleehr","html_url":"https://github.com/dleehr","followers_url":"https://api.github.com/users/dleehr/followers","following_url":"https://api.github.com/users/dleehr/following{/other_user}","gists_url":"https://api.github.com/users/dleehr/gists{/gist_id}","starred_url":"https://api.github.com/users/dleehr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dleehr/subscriptions","organizations_url":"https://api.github.com/users/dleehr/orgs","repos_url":"https://api.github.com/users/dleehr/repos","events_url":"https://api.github.com/users/dleehr/events{/privacy}","received_events_url":"https://api.github.com/users/dleehr/received_events","type":"User","site_admin":false},"assignees":[{"login":"dleehr","id":2752599,"avatar_url":"https://avatars3.githubusercontent.com/u/2752599?v=4","gravatar_id":"","url":"https://api.github.com/users/dleehr","html_url":"https://github.com/dleehr","followers_url":"https://api.github.com/users/dleehr/followers","following_url":"https://api.github.com/users/dleehr/following{/other_user}","gists_url":"https://api.github.com/users/dleehr/gists{/gist_id}","starred_url":"https://api.github.com/users/dleehr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dleehr/subscriptions","organizations_url":"https://api.github.com/users/dleehr/orgs","repos_url":"https://api.github.com/users/dleehr/repos","events_url":"https://api.github.com/users/dleehr/events{/privacy}","received_events_url":"https://api.github.com/users/dleehr/received_events","type":"User","site_admin":false}],"milestone":null,"comments":1,"created_at":"2017-11-13T18:37:30Z","updated_at":"2017-11-13T18:52:28Z","closed_at":null,"author_association":"OWNER","body":"[cwlreport.py](https://github.com/Duke-GCB/lando/blob/5456fe3ef698496614d143b7c5aafb40db9f0761/lando/worker/cwlreport.py#L166) attempts to extract the `path` of each output file in the CWL output, JSON , but the current build of lando worker with cwltoil 3.10.1 does not produce this key in file objects. It includes `location`, which is [also valid CWL](http://www.commonwl.org/v1.0/CommandLineTool.html#File)\r\n\r\n> The `location` property of a File is a URI that uniquely identifies the file. Implementations must support the file:// URI scheme and may support other schemes such as http://. The value of `location` may also be a relative reference, in which case it must be resolved relative to the URI of the document it appears in. Alternately to `location`, implementations must also accept the `path` property on File, which must be a filesystem path available on the same host as the CWL runner (for inputs) or the runtime environment of a command line tool execution (for command line tool outputs).\r\n\r\nNote that while `path` is a simple path, `location` is a URI.\r\n\r\nExample from lando worker VM:\r\n\r\n```\r\n{\r\n    \"checksum\": \"sha1$xx\", \r\n    \"basename\": \"XXXXXX-dedup.bam\", \r\n    \"nameext\": \".bam\", \r\n    \"nameroot\": \"XXXXXX-dedup\", \r\n    \"http://commonwl.org/cwltool#generation\": 0, \r\n    \"location\": \"file:///work/data_for_job_1/working/results/bams-markduplicates/XXXXXX-dedup.bam\", \r\n    \"secondaryFiles\": [\r\n        {\r\n            \"checksum\": \"sha1$yyy\", \r\n            \"basename\": \"XXXXXX-dedup.bai\", \r\n            \"nameroot\": \"XXXXXX-dedup\", \r\n            \"nameext\": \".bai\", \r\n            \"http://commonwl.org/cwltool#generation\": 0, \r\n            \"location\": \"file:///work/data_for_job_1/working/results/bams-markduplicates/XXXXXX-dedup.bai\", \r\n            \"class\": \"File\", \r\n            \"size\": 999\r\n        }\r\n    ], \r\n    \"class\": \"File\", \r\n    \"size\": 9999\r\n}\r\n```\r\n\r\n```\r\nTraceback (most recent call last):\r\n  File \"/usr/local/lib/python2.7/dist-packages/lando/worker/worker.py\", line 184, in run\r\n    self.func(working_directory, self.payload)\r\n  File \"/usr/local/lib/python2.7/dist-packages/lando/worker/worker.py\", line 101, in run_workflow\r\n    workflow.run(payload.cwl_file_url, payload.workflow_object_name, payload.job_order)\r\n  File \"/usr/local/lib/python2.7/dist-packages/lando/worker/cwlworkflow.py\", line 154, in run\r\n    results_directory.add_files(process)\r\n  File \"/usr/local/lib/python2.7/dist-packages/lando/worker/cwlworkflow.py\", line 263, in add_files\r\n    self._create_report(cwl_process)\r\n  File \"/usr/local/lib/python2.7/dist-packages/lando/worker/cwlworkflow.py\", line 296, in _create_report\r\n    workflow_info.update_with_job_order(job_order_path=os.path.join(workflow_directory, self.job_order_filename))\r\n  File \"/usr/local/lib/python2.7/dist-packages/lando/worker/cwlreport.py\", line 158, in update_with_job_order\r\n    input_param.set_value(self._create_str_value(val))\r\n  File \"/usr/local/lib/python2.7/dist-packages/lando/worker/cwlreport.py\", line 168, in _create_str_value\r\n    return ','.join([WorkflowInfo._create_str_value(part) for part in val])\r\n  File \"/usr/local/lib/python2.7/dist-packages/lando/worker/cwlreport.py\", line 166, in _create_str_value\r\n    return val['path']\r\nKeyError: 'path'\r\n```\r\n"},"comment":{"url":"https://api.github.com/repos/Duke-GCB/lando/issues/comments/344019414","html_url":"https://github.com/Duke-GCB/lando/issues/96#issuecomment-344019414","issue_url":"https://api.github.com/repos/Duke-GCB/lando/issues/96","id":344019414,"user":{"login":"dleehr","id":2752599,"avatar_url":"https://avatars3.githubusercontent.com/u/2752599?v=4","gravatar_id":"","url":"https://api.github.com/users/dleehr","html_url":"https://github.com/dleehr","followers_url":"https://api.github.com/users/dleehr/followers","following_url":"https://api.github.com/users/dleehr/following{/other_user}","gists_url":"https://api.github.com/users/dleehr/gists{/gist_id}","starred_url":"https://api.github.com/users/dleehr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dleehr/subscriptions","organizations_url":"https://api.github.com/users/dleehr/orgs","repos_url":"https://api.github.com/users/dleehr/repos","events_url":"https://api.github.com/users/dleehr/events{/privacy}","received_events_url":"https://api.github.com/users/dleehr/received_events","type":"User","site_admin":false},"created_at":"2017-11-13T18:52:28Z","updated_at":"2017-11-13T18:52:28Z","author_association":"OWNER","body":"Actually from the tests it looks like we were already expecting the field `location`, but expecting it to be a path (not a URI) "}}
{"actor":{"display_login":"dleehr"}}