-
-
Notifications
You must be signed in to change notification settings - Fork 22
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
Clarify process id field ($graph only) #166
Conversation
Website failed to render after this change. Will take a look later 👍 🕐 🛌 |
I guess it is the matter of document generation rather than the schema itself because |
23c5fdd
to
8460d79
Compare
Hadn't had to play with schema salad yet (looks like I have a lot to learn about it), but here's the command to reproduce the website build error: schema-salad-tool --debug CommonWorkflowLanguage.yml The error, basically, is: “schema_salad.avro.schema.SchemaParseException: Field name id already in use” I couldn't find a way to define the The last commit adds a comment about the Bruno |
Also not sure if the text is explaining it well to users. Are there other levels where the |
In my understanding, there are no way to override the definition (including document) of specific fields. |
Thank you for clarifying that @tom-tan 🙇 I guess documenting the |
So it will be tricky to adjust the documentation field in Your initial try at 2579e8a works with common-workflow-language/schema_salad#535 so I would suggest you wait for that to get approved & released and then it will be easier to re-write doc fields |
Agreed! Thanks @mr-c |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@kinow schema-salad
https://github.com/common-workflow-language/schema_salad/releases/tag/8.3.20220518163624 has been released, which allows narrowing (and new doc fields) for inherited types. Please make use of that for this PR
d504568
to
8bce022
Compare
Tested the latest commit with the following command: $ pip install schema-salad==8.3.20220525163636 -U
...
$ schema-salad-tool CommonWorkflowLanguage.yml
/home/kinow/Development/python/workspace/cwl-v1.2/venv/bin/schema-salad-tool Current version: 8.3.20220525163636
Schema `CommonWorkflowLanguage.yml` is valid To confirm it's indeed working as expected, I downgraded $ pip install schema-salad==8.2.20220204150214
...
Installing collected packages: schema-salad
Attempting uninstall: schema-salad
Found existing installation: schema-salad 8.3.20220525163636
Uninstalling schema-salad-8.3.20220525163636:
Successfully uninstalled schema-salad-8.3.20220525163636
Successfully installed schema-salad-8.2.20220204150214
$ schema-salad-tool CommonWorkflowLanguage.yml
/home/kinow/Development/python/workspace/cwl-v1.2/venv/bin/schema-salad-tool Current version: 8.2.20220204150214
Schema `CommonWorkflowLanguage.yml` error:
Union item must be a valid Avro schema: {'type': 'record', 'name': 'org.w3id.cwl.cwl.CommandLineTool', 'extends': 'https://w3id.org/cwl/cwl#Process', (...)'doc': 'Exit codes that indicate the process failed due to a permanent logic error, where executing the process with the same runtime environment and same inputs is expected to always fail.\nIf not specified, all exit codes except 0 are considered permanent failure.'}]} So as @mr-c pointed out, the latest release of Thanks! |
@kinow Did you make a local rendering and look over the changes? Guess we should add that to the CI :-) |
Not this time. But I think I still have the website checked out (if not, it's a good time to sync it). Will post the rendered output in a bit. That'll be good too to validate what it looks like with the new schema-salad. |
I applied the following patch to diff --git a/site/cwlsite.cwl b/site/cwlsite.cwl
index 08b841f..3a41f1f 100755
--- a/site/cwlsite.cwl
+++ b/site/cwlsite.cwl
@@ -61,7 +61,7 @@ requirements:
hints:
DockerRequirement:
- dockerPull: quay.io/commonwl/cwltool_module:main
+ dockerPull: quay.io/commonwl/cwltool_module:3.1.20220607081835
steps:
make_rdfs:
diff --git a/website.sh b/website.sh
index 628444c..7956423 100755
--- a/website.sh
+++ b/website.sh
@@ -18,9 +18,9 @@ done
repo=https://github.com/common-workflow-language/cwl-v1.2 \
bn=$(basename $repo)
if [[ -d $bn ]] ; then
- (cd $bn && git fetch origin && git reset --hard origin/main)
+ (cd $bn && git fetch origin && git reset --hard origin/clarify-process-id)
else
- git clone $repo && pushd $bn; git checkout main ; git show --no-patch ; popd
+ git clone $repo && pushd $bn; git checkout clarify-process-id ; git show --no-patch ; popd
fi
Then searched for “Only useful for ”. Here's screenshots of where it was rendered in the Command Line Tool page. And here's in the Workflow page. @mr-c I was going to ask if these looked like the correct places to have this comment… but then I realized that the I'm trying to understand what's going on now. Good thing you asked for the rendered output @mr-c 👍 |
Thanks @kinow ; this will require a fix to schema-salad's makedoc code |
Note to self: re-render after schema-salad release is out. We should have a single field then 🤞 |
The But here's a preview from this repository, after updating
And running
No duplicate |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I can confirm that the rendering works now; thank you @kinow !
Closes #117
Looks like the
Process
section includes/requires another document where theid
field is defined. I'm guessing this works similar to OOP in Python/Java, and that I can specify theid
inProcess
.Will render the site with this change to confirm it's working as expected...