Skip to content

Removing unnecessary warning due to generation field #525

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
Aug 17, 2017

Conversation

kapilkd13
Copy link
Contributor

setting generation field after schema validation and removing this generation field from the final output.

closes #382

@kapilkd13
Copy link
Contributor Author

Output will be something like this

Resolved 'E:\GitHub\gsoc\common-workflow-language\v1.0\v1.0\dir.cwl' to 'file:///E:/GitHub/gsoc/common-workflow-language/v1.0/v1.0/dir.cwl'
We are on Microsoft Windows and not all components of this CWL description have a
container specified. This means that these steps will be executed in the default container,
which is frolvlad/alpine-bash.

Note, this could affect portability if this CWL description relies on non-POSIX features
or commands in this container. For best results add the following to your CWL
description's hints section:

hints:
  DockerRequirement:
    dockerPull: frolvlad/alpine-bash

[job dir.cwl] initializing from file:///E:/GitHub/gsoc/common-workflow-language/v1.0/v1.0/dir.cwl
[job dir.cwl] {
    "indir": {
        "class": "Directory", 
        "location": "file:///e:/GitHub/gsoc/common-workflow-language/v1.0/v1.0/testdir", 
        "basename": "testdir"
    }
}
[job dir.cwl] path mappings is {
    "file:///e:/GitHub/gsoc/common-workflow-language/v1.0/v1.0/testdir/c/d": [
        "E:\\GitHub\\gsoc\\common-workflow-language\\v1.0\\v1.0\\testdir\\c\\d", 
        "/var/lib/cwl/stg3206b963-d87a-4b99-8450-a611fe2f01aa/testdir/c/d", 
        "File", 
        false
    ], 
    "file:///e:/GitHub/gsoc/common-workflow-language/v1.0/v1.0/testdir": [
        "E:\\GitHub\\gsoc\\common-workflow-language\\v1.0\\v1.0\\testdir", 
        "/var/lib/cwl/stg3206b963-d87a-4b99-8450-a611fe2f01aa/testdir", 
        "Directory", 
        true
    ], 
    "file:///e:/GitHub/gsoc/common-workflow-language/v1.0/v1.0/testdir/a": [
        "E:\\GitHub\\gsoc\\common-workflow-language\\v1.0\\v1.0\\testdir\\a", 
        "/var/lib/cwl/stg3206b963-d87a-4b99-8450-a611fe2f01aa/testdir/a", 
        "File", 
        false
    ], 
    "file:///e:/GitHub/gsoc/common-workflow-language/v1.0/v1.0/testdir/b": [
        "E:\\GitHub\\gsoc\\common-workflow-language\\v1.0\\v1.0\\testdir\\b", 
        "/var/lib/cwl/stg3206b963-d87a-4b99-8450-a611fe2f01aa/testdir/b", 
        "File", 
        false
    ], 
    "file:///e:/GitHub/gsoc/common-workflow-language/v1.0/v1.0/testdir/c": [
        "E:\\GitHub\\gsoc\\common-workflow-language\\v1.0\\v1.0\\testdir\\c", 
        "/var/lib/cwl/stg3206b963-d87a-4b99-8450-a611fe2f01aa/testdir/c", 
        "Directory", 
        false
    ]
}
[job dir.cwl] command line bindings is [
    {
        "position": [
            0, 
            0
        ], 
        "datum": "cd"
    }, 
    {
        "position": [
            0, 
            1
        ], 
        "valueFrom": "$(inputs.indir.path)"
    }, 
    {
        "shellQuote": false, 
        "valueFrom": "&&", 
        "position": [
            0, 
            2
        ]
    }, 
    {
        "position": [
            0, 
            3
        ], 
        "datum": "find"
    }, 
    {
        "position": [
            0, 
            4
        ], 
        "datum": "."
    }, 
    {
        "shellQuote": false, 
        "valueFrom": "|", 
        "position": [
            0, 
            5
        ]
    }, 
    {
        "position": [
            0, 
            6
        ], 
        "datum": "sort"
    }
]
[job dir.cwl] c:\users\kapilk~1\appdata\local\temp\tmpdjdafk$ docker \
    run \
    -i \
    --volume=/C/users/kapilk~1/appdata/local/temp/tmpdjdafk:/var/spool/cwl:rw \
    --volume=/C/users/kapilk~1/appdata/local/temp/tmpbipmg2:/tmp:rw \
    --volume=/E/GitHub/gsoc/common-workflow-language/v1.0/v1.0/testdir:/var/lib/cwl/stg3206b963-d87a-4b99-8450-a611fe2f01aa/testdir:ro \
    --workdir=/var/spool/cwl \
    --read-only=true \
    --log-driver=none \
    --user=1000:50 \
    --rm \
    --env=TMPDIR=/tmp \
    --env=HOME=/var/spool/cwl \
    frolvlad/alpine-bash \
    /bin/sh \
    -c \
    'cd' '/var/lib/cwl/stg3206b963-d87a-4b99-8450-a611fe2f01aa/testdir' && 'find' '.' | 'sort' > c:\users\kapilk~1\appdata\local\temp\tmpdjdafk\output.txt
[job dir.cwl] completed success
[job dir.cwl] {
    "outlist": {
        "checksum": "sha1$13cda8661796ae241da3a18668fb552161a72592", 
        "basename": "output.txt", 
        "nameext": ".txt", 
        "nameroot": "output", 
        "http://commonwl.org/cwltool#generation": 0, 
        "location": "file:///C:/users/kapilk%7E1/appdata/local/temp/tmpdjdafk/output.txt", 
        "class": "File", 
        "size": 20
    }
}
[job dir.cwl] Removing input staging directory c:\users\kapilk~1\appdata\local\temp\tmplkjnub
[job dir.cwl] Removing temporary directory c:\users\kapilk~1\appdata\local\temp\tmpbipmg2
Copying C:\users\kapilk~1\appdata\local\temp\tmpdjdafk\output.txt to E:/GitHub/gsoc/cwltool/output.txt
Final process status is success
{
    "outlist": {
        "checksum": "sha1$13cda8661796ae241da3a18668fb552161a72592", 
        "basename": "output.txt", 
        "nameext": ".txt", 
        "nameroot": "output", 
        "location": "file:///E://GitHub/gsoc/cwltool/output.txt", 
        "path": "E:\\GitHub\\gsoc\\cwltool\\output.txt", 
        "class": "File", 
        "size": 20
    }
}

Process finished with exit code 0

@mr-c mr-c requested a review from tetron August 15, 2017 15:57
@mr-c
Copy link
Member

mr-c commented Aug 15, 2017

LGTM, I'd like @tetron to verify this

cwltool/main.py Outdated
@@ -915,6 +915,9 @@ def locToPath(p):

visit_class(out, ("File", "Directory"), locToPath)

# Unsetting the Generation fron final output object
visit_class(out,("File"), MutationManager().unset_generation)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think you want ("File",) to make it a 1-item tuple.

Copy link
Member

@tetron tetron left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good.

@mr-c mr-c changed the title Removing unnecessary warning genrated due to genration field Removing unnecessary warning due to generation field Aug 17, 2017
@mr-c mr-c merged commit b7f87da into common-workflow-language:master Aug 17, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

removal of warning due to updatable inputs feature
3 participants