Skip to content

Commit

Permalink
Added noLinkCheck to format field
Browse files Browse the repository at this point in the history
CWL parsers should not follow `format` links.
  • Loading branch information
GlassOfWhiskey authored and mr-c committed Apr 10, 2024
1 parent d6bc230 commit e9acf61
Show file tree
Hide file tree
Showing 11 changed files with 40 additions and 55 deletions.
4 changes: 4 additions & 0 deletions .github/config/wordlist.txt
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ chilton
cisphobia
classname
cmd
colonnelli
commandinputarrayschema
commandinputenumschema
commandinputparameter
Expand Down Expand Up @@ -113,6 +114,7 @@ gmail
gunzip
hervé
https
iacopo
iana
ietf
implementer
Expand All @@ -127,6 +129,7 @@ inplaceupdaterequirement
inputarrayschema
inputenumschema
inputbinding
inputfile
inputformat
inputrecordfield
inputrecordschema
Expand Down Expand Up @@ -275,6 +278,7 @@ tijanić
timelimit
toc
tooltimelimit
torino
transcode
txt
typedef
Expand Down
8 changes: 6 additions & 2 deletions Base.yml
Original file line number Diff line number Diff line change
Expand Up @@ -285,6 +285,7 @@ $graph:
_id: cwl:format
_type: "@id"
identity: true
noLinkCheck: true
doc: |
The format of the file: this must be an IRI of a concept node that
represents the file format, preferably defined within an ontology.
Expand Down Expand Up @@ -473,7 +474,6 @@ $graph:
items:
- "null"
- CWLObjectType
flatten: false
- type: map
values:
- "null"
Expand All @@ -491,4 +491,8 @@ $graph:
items: ProcessRequirement
- CWLObjectType
doc: |
Type representing a valid CWL input file as a `map<string, union<array<ProcessRequirement>, CWLObjectType>>`.
Type representing a valid CWL input file as a `map<string, union<array<ProcessRequirement>, CWLObjectType>>`.
jsonldPredicate:
_id: "cwl:inputfile"
_container: "@list"
noLinkCheck: true
5 changes: 4 additions & 1 deletion Process.yml
Original file line number Diff line number Diff line change
Expand Up @@ -199,6 +199,7 @@ $graph:
_id: cwl:format
_type: "@id"
identity: true
noLinkCheck: true
doc: |
Only valid when `type: File` or is an array of `items: File`.
Expand All @@ -221,6 +222,7 @@ $graph:
_id: cwl:format
_type: "@id"
identity: true
noLinkCheck: true
doc: |
Only valid when `type: File` or is an array of `items: File`.
Expand Down Expand Up @@ -374,7 +376,8 @@ $graph:
- name: default
type: CWLObjectType?
jsonldPredicate:
_id: sld:default
_id: "sld:default"
_container: "@list"
noLinkCheck: true
doc: |
The default value to use for this parameter if the parameter is missing
Expand Down
1 change: 1 addition & 0 deletions Workflow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -593,6 +593,7 @@ $graph:
default must be applied prior to scattering or evaluating `valueFrom`.
jsonldPredicate:
_id: "sld:default"
_container: "@list"
noLinkCheck: true
- name: valueFrom
type:
Expand Down
2 changes: 1 addition & 1 deletion concepts.md
Original file line number Diff line number Diff line change
Expand Up @@ -331,7 +331,7 @@ prefix listed in the `$namespaces` section of the document as described in the
[Schema Salad specification](SchemaSalad.html#Explicit_context).

It is recommended that concepts from schema.org are used whenever possible.
For the `$schemas` field we recommend their RDF encoding: http://schema.org/version/latest/schema.rdf
For the `$schemas` field we recommend their RDF encoding: https://schema.org/version/latest/schemaorg-current-https.rdf

Implementation extensions which modify execution semantics must be [listed in
the `requirements` field](#Requirements_and_hints).
Expand Down
6 changes: 3 additions & 3 deletions render.bash
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
#!/usr/bin/env bash
if [[ -z "$WORKSPACE" ]] ; then
WORKSPACE=$PWD
WORKSPACE=$PWD/temp/
fi
mkdir -p $WORKSPACE
repo=https://github.com/common-workflow-language/cwl-website \
bn=$(basename $repo)
bn=$WORKSPACE/$(basename $repo)
if [[ -d $bn ]] ; then
(cd $bn && git fetch origin && git reset --hard origin/main)
else
git clone $repo && pushd $bn; git checkout main ; git show --no-patch ; popd
git clone $repo $bn && pushd $bn; git checkout main ; git show --no-patch ; popd
fi
echo "- basename: Base.yml" >> $WORKSPACE/cwl-website/site/v1.2-deps.yaml
echo " class: File" >> $WORKSPACE/cwl-website/site/v1.2-deps.yaml
Expand Down
10 changes: 9 additions & 1 deletion salad/schema_salad/metaschema/metaschema.yml
Original file line number Diff line number Diff line change
Expand Up @@ -274,6 +274,7 @@ $graph:
doc: |
If true, indicates that the type is a valid at the document root. At
least one type in a schema must be tagged with `documentRoot: true`.
jsonldPredicate: sld:documentRoot


- name: SaladRecordField
Expand Down Expand Up @@ -368,10 +369,17 @@ $graph:
- name: SaladUnionSchema
docParent: "#Schema"
type: record
extends: [NamedType, UnionSchema, SchemaDefinedType]
extends: [NamedType, UnionSchema, DocType]
documentRoot: true
doc: |
Define a union type.
fields:
- name: documentRoot
type: boolean?
doc: |
If true, indicates that the type is a valid at the document root. At
least one type in a schema must be tagged with `documentRoot: true`.
jsonldPredicate: sld:documentRoot


- name: Documentation
Expand Down
7 changes: 0 additions & 7 deletions salad/schema_salad/metaschema/metaschema_base.yml
Original file line number Diff line number Diff line change
Expand Up @@ -191,13 +191,6 @@ $graph:
_type: "@vocab"
refScope: 2
doc: "Defines the type of the array elements."
flatten:
type: boolean?
jsonldPredicate:
_id: "sld:flatten"
_type: "@vocab"
refScope: 2
doc: "Flatten inner array objects into a single sequence (default: true)."


- name: MapSchema
Expand Down
13 changes: 12 additions & 1 deletion salad/schema_salad/metaschema/salad.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ Contributors:
* The developers of JSON-LD
* Nebojša Tijanić <nebojsa.tijanic@sbgenomics.com>, Seven Bridges Genomics
* Michael R. Crusoe, ELIXIR-DE
* Iacopo Colonnelli, University of Torino

# Abstract

Expand Down Expand Up @@ -120,6 +121,16 @@ clarifications.
resolved with [identifier resolution](#Identifier_resolution).
Otherwise the field is resolved with [link resolution](#Link_resolution).

## Introduction to v1.3

This is the fifth version of the Schema Salad specification. It was created to
enhance code generation by representing CWL data types as specific Python objects
(instead of relying on the generic `Any` type). The following changes have been made:

* Support for the Avro `map` schema
* Add named versions of the `map` and `union` Avro types
* Support for nested named `union` type definitions

## References to Other Specifications

**Javascript Object Notation (JSON)**: http://json.org
Expand Down Expand Up @@ -173,7 +184,7 @@ enable or disable the behavior described.
## Data concepts

An **object** is a data structure equivalent to the "object" type in JSON,
consisting of an unordered set of name/value pairs (referred to here as
consisting of a unordered set of name/value pairs (referred to here as
**fields**) and where the name is a string and the value is a string, number,
boolean, array, or object.

Expand Down
19 changes: 0 additions & 19 deletions tests/cat3-tool-docker.cwl

This file was deleted.

20 changes: 0 additions & 20 deletions tests/wc-tool-shortcut.cwl

This file was deleted.

0 comments on commit e9acf61

Please sign in to comment.