From 59fc8eb3f451423bb886be65d00067978d1821c7 Mon Sep 17 00:00:00 2001 From: mvdbeek Date: Mon, 2 Dec 2024 13:01:25 +0100 Subject: [PATCH 1/4] Upgrade schema-salad version and auto-generated documents --- gxformat2/schema/v19_09.py | 215 +++++++++--------- typescript/docs/classes/ArraySchema.html | 6 +- typescript/docs/classes/EnumSchema.html | 6 +- typescript/docs/classes/GalaxyWorkflow.html | 26 +-- typescript/docs/classes/RecordField.html | 8 +- typescript/docs/classes/RecordSchema.html | 6 +- typescript/docs/classes/Report.html | 4 +- typescript/docs/classes/StepPosition.html | 6 +- .../docs/classes/ToolShedRepository.html | 10 +- .../docs/classes/ValidationException.html | 4 +- .../docs/classes/WorkflowInputParameter.html | 18 +- .../docs/classes/WorkflowOutputParameter.html | 12 +- typescript/docs/classes/WorkflowStep.html | 32 +-- .../docs/classes/WorkflowStepInput.html | 10 +- .../docs/classes/WorkflowStepOutput.html | 4 +- typescript/docs/enums/Any.html | 2 +- typescript/docs/enums/GalaxyType.html | 2 +- typescript/docs/enums/PrimitiveType.html | 2 +- typescript/docs/enums/WorkflowStepType.html | 2 +- ...2602be0b4b8fd33e69e29a841317b6ab665bc.html | 2 +- ...1d79c225752b9fadb617367615ab176b47d77.html | 2 +- ...ba076fca539106791a4f46d198c7fcfbdb779.html | 2 +- .../interfaces/ArraySchemaProperties.html | 4 +- .../docs/interfaces/DocumentedProperties.html | 2 +- .../docs/interfaces/EnumSchemaProperties.html | 4 +- .../interfaces/GalaxyWorkflowProperties.html | 24 +- .../interfaces/HasStepErrorsProperties.html | 2 +- .../interfaces/HasStepPositionProperties.html | 2 +- .../docs/interfaces/HasUUIDProperties.html | 2 +- .../docs/interfaces/IdentifiedProperties.html | 2 +- .../interfaces/InputParameterProperties.html | 8 +- .../docs/interfaces/LabeledProperties.html | 2 +- .../interfaces/OutputParameterProperties.html | 6 +- .../docs/interfaces/ParameterProperties.html | 6 +- .../docs/interfaces/ProcessProperties.html | 10 +- .../interfaces/RecordFieldProperties.html | 6 +- .../interfaces/RecordSchemaProperties.html | 4 +- .../interfaces/ReferencesToolProperties.html | 6 +- .../docs/interfaces/ReportProperties.html | 2 +- .../docs/interfaces/SinkProperties.html | 2 +- .../interfaces/StepPositionProperties.html | 4 +- .../ToolShedRepositoryProperties.html | 8 +- .../WorkflowInputParameterProperties.html | 16 +- .../WorkflowOutputParameterProperties.html | 10 +- .../WorkflowStepInputProperties.html | 8 +- .../WorkflowStepOutputProperties.html | 4 +- .../interfaces/WorkflowStepProperties.html | 30 +-- typescript/docs/modules.html | 2 +- 48 files changed, 273 insertions(+), 284 deletions(-) diff --git a/gxformat2/schema/v19_09.py b/gxformat2/schema/v19_09.py index 5d6778e..b5ade5a 100644 --- a/gxformat2/schema/v19_09.py +++ b/gxformat2/schema/v19_09.py @@ -11,21 +11,10 @@ import uuid as _uuid__ # pylint: disable=unused-import # noqa: F401 import xml.sax # nosec from abc import ABC, abstractmethod +from collections.abc import MutableMapping, MutableSequence, Sequence from io import StringIO from itertools import chain -from typing import ( - Any, - Dict, - List, - MutableMapping, - MutableSequence, - Optional, - Sequence, - Tuple, - Type, - Union, - cast, -) +from typing import Any, Optional, Union, cast from urllib.parse import quote, urldefrag, urlparse, urlsplit, urlunsplit from urllib.request import pathname2url @@ -38,13 +27,13 @@ from schema_salad.sourceline import SourceLine, add_lc_filename from schema_salad.utils import CacheType, yaml_no_ts # requires schema-salad v8.2+ -_vocab: Dict[str, str] = {} -_rvocab: Dict[str, str] = {} +_vocab: dict[str, str] = {} +_rvocab: dict[str, str] = {} _logger = logging.getLogger("salad") -IdxType = MutableMapping[str, Tuple[Any, "LoadingOptions"]] +IdxType = MutableMapping[str, tuple[Any, "LoadingOptions"]] class LoadingOptions: @@ -56,27 +45,27 @@ class LoadingOptions: original_doc: Optional[Any] addl_metadata: MutableMapping[str, Any] fetcher: Fetcher - vocab: Dict[str, str] - rvocab: Dict[str, str] + vocab: dict[str, str] + rvocab: dict[str, str] cache: CacheType - imports: List[str] - includes: List[str] + imports: list[str] + includes: list[str] no_link_check: Optional[bool] container: Optional[str] def __init__( self, fetcher: Optional[Fetcher] = None, - namespaces: Optional[Dict[str, str]] = None, - schemas: Optional[List[str]] = None, + namespaces: Optional[dict[str, str]] = None, + schemas: Optional[list[str]] = None, fileuri: Optional[str] = None, copyfrom: Optional["LoadingOptions"] = None, original_doc: Optional[Any] = None, - addl_metadata: Optional[Dict[str, str]] = None, + addl_metadata: Optional[dict[str, str]] = None, baseuri: Optional[str] = None, idx: Optional[IdxType] = None, - imports: Optional[List[str]] = None, - includes: Optional[List[str]] = None, + imports: Optional[list[str]] = None, + includes: Optional[list[str]] = None, no_link_check: Optional[bool] = None, container: Optional[str] = None, ) -> None: @@ -216,16 +205,16 @@ def fromDoc( @abstractmethod def save( self, top: bool = False, base_url: str = "", relative_uris: bool = True - ) -> Dict[str, Any]: + ) -> dict[str, Any]: """Convert this object to a JSON/YAML friendly dictionary.""" def load_field( - val: Union[str, Dict[str, str]], + val: Union[str, dict[str, str]], fieldtype: "_Loader", baseuri: str, loadingOptions: LoadingOptions, - lc: Optional[List[Any]] = None, + lc: Optional[list[Any]] = None, ) -> Any: """Load field.""" if isinstance(val, MutableMapping): @@ -252,7 +241,7 @@ def load_field( save_type = Optional[Union[MutableMapping[str, Any], MutableSequence[Any], int, float, bool, str]] -def extract_type(val_type: Type[Any]) -> str: +def extract_type(val_type: type[Any]) -> str: """Take a type of value, and extracts the value as a string.""" val_str = str(val_type) return val_str.split("'")[1] @@ -271,7 +260,7 @@ def convert_typing(val_type: str) -> str: return val_type -def parse_errors(error_message: str) -> Tuple[str, str, str]: +def parse_errors(error_message: str) -> tuple[str, str, str]: """Parse error messages from several loaders into one error message.""" if not error_message.startswith("Expected"): return error_message, "", "" @@ -431,7 +420,7 @@ def load( baseuri: str, loadingOptions: LoadingOptions, docRoot: Optional[str] = None, - lc: Optional[List[Any]] = None, + lc: Optional[list[Any]] = None, ) -> Any: pass @@ -443,7 +432,7 @@ def load( baseuri: str, loadingOptions: LoadingOptions, docRoot: Optional[str] = None, - lc: Optional[List[Any]] = None, + lc: Optional[list[Any]] = None, ) -> Any: if doc is not None: return doc @@ -451,7 +440,7 @@ def load( class _PrimitiveLoader(_Loader): - def __init__(self, tp: Union[type, Tuple[Type[str], Type[str]]]) -> None: + def __init__(self, tp: Union[type, tuple[type[str], type[str]]]) -> None: self.tp = tp def load( @@ -460,7 +449,7 @@ def load( baseuri: str, loadingOptions: LoadingOptions, docRoot: Optional[str] = None, - lc: Optional[List[Any]] = None, + lc: Optional[list[Any]] = None, ) -> Any: if not isinstance(doc, self.tp): raise ValidationException(f"Expected a {self.tp} but got {doc.__class__.__name__}") @@ -480,16 +469,16 @@ def load( baseuri: str, loadingOptions: LoadingOptions, docRoot: Optional[str] = None, - lc: Optional[List[Any]] = None, + lc: Optional[list[Any]] = None, ) -> Any: if not isinstance(doc, MutableSequence): raise ValidationException( f"Value is a {convert_typing(extract_type(type(doc)))}, " f"but valid type for this field is an array." ) - r: List[Any] = [] - errors: List[SchemaSaladException] = [] - fields: List[str] = [] + r: list[Any] = [] + errors: list[SchemaSaladException] = [] + fields: list[str] = [] for i in range(0, len(doc)): try: lf = load_field( @@ -546,7 +535,7 @@ def load( baseuri: str, loadingOptions: LoadingOptions, docRoot: Optional[str] = None, - lc: Optional[List[Any]] = None, + lc: Optional[list[Any]] = None, ) -> Any: if not isinstance(doc, MutableMapping): raise ValidationException(f"Expected a map, was {type(doc)}") @@ -554,8 +543,8 @@ def load( loadingOptions = LoadingOptions( copyfrom=loadingOptions, container=self.container, no_link_check=self.no_link_check ) - r: Dict[str, Any] = {} - errors: List[SchemaSaladException] = [] + r: dict[str, Any] = {} + errors: list[SchemaSaladException] = [] for k, v in doc.items(): try: lf = load_field(v, self.values, baseuri, loadingOptions, lc) @@ -581,7 +570,7 @@ def load( baseuri: str, loadingOptions: LoadingOptions, docRoot: Optional[str] = None, - lc: Optional[List[Any]] = None, + lc: Optional[list[Any]] = None, ) -> Any: if doc in self.symbols: return doc @@ -601,9 +590,9 @@ def load( baseuri: str, loadingOptions: LoadingOptions, docRoot: Optional[str] = None, - lc: Optional[List[Any]] = None, + lc: Optional[list[Any]] = None, ) -> Any: - r: List[Dict[str, Any]] = [] + r: list[dict[str, Any]] = [] if isinstance(doc, MutableSequence): for d in doc: if isinstance(d, str): @@ -612,7 +601,7 @@ def load( else: r.append({"pattern": d}) elif isinstance(d, dict): - new_dict: Dict[str, Any] = {} + new_dict: dict[str, Any] = {} dict_copy = copy.deepcopy(d) if "pattern" in dict_copy: new_dict["pattern"] = dict_copy.pop("pattern") @@ -666,7 +655,7 @@ def load( class _RecordLoader(_Loader): def __init__( self, - classtype: Type[Saveable], + classtype: type[Saveable], container: Optional[str] = None, no_link_check: Optional[bool] = None, ) -> None: @@ -680,7 +669,7 @@ def load( baseuri: str, loadingOptions: LoadingOptions, docRoot: Optional[str] = None, - lc: Optional[List[Any]] = None, + lc: Optional[list[Any]] = None, ) -> Any: if not isinstance(doc, MutableMapping): raise ValidationException( @@ -698,7 +687,7 @@ def __repr__(self) -> str: class _ExpressionLoader(_Loader): - def __init__(self, items: Type[str]) -> None: + def __init__(self, items: type[str]) -> None: self.items = items def load( @@ -707,7 +696,7 @@ def load( baseuri: str, loadingOptions: LoadingOptions, docRoot: Optional[str] = None, - lc: Optional[List[Any]] = None, + lc: Optional[list[Any]] = None, ) -> Any: if not isinstance(doc, str): raise ValidationException( @@ -731,7 +720,7 @@ def load( baseuri: str, loadingOptions: LoadingOptions, docRoot: Optional[str] = None, - lc: Optional[List[Any]] = None, + lc: Optional[list[Any]] = None, ) -> Any: errors = [] @@ -828,7 +817,7 @@ def load( baseuri: str, loadingOptions: LoadingOptions, docRoot: Optional[str] = None, - lc: Optional[List[Any]] = None, + lc: Optional[list[Any]] = None, ) -> Any: if self.no_link_check is not None: loadingOptions = LoadingOptions( @@ -886,7 +875,7 @@ def resolve( doc: str, baseuri: str, loadingOptions: LoadingOptions, - ) -> Union[List[Union[Dict[str, Any], str]], Dict[str, Any], str]: + ) -> Union[list[Union[dict[str, Any], str]], dict[str, Any], str]: doc_ = doc optional = False if doc_.endswith("?"): @@ -895,7 +884,7 @@ def resolve( if doc_.endswith("[]"): salad_versions = [int(v) for v in self.salad_version[1:].split(".")] - items: Union[List[Union[Dict[str, Any], str]], Dict[str, Any], str] = "" + items: Union[list[Union[dict[str, Any], str]], dict[str, Any], str] = "" rest = doc_[0:-2] if salad_versions < [1, 3]: if rest.endswith("[]"): @@ -907,7 +896,7 @@ def resolve( items = self.resolve(rest, baseuri, loadingOptions) if isinstance(items, str): items = expand_url(items, baseuri, loadingOptions, False, True, self.refScope) - expanded: Union[Dict[str, Any], str] = {"type": "array", "items": items} + expanded: Union[dict[str, Any], str] = {"type": "array", "items": items} else: expanded = expand_url(doc_, baseuri, loadingOptions, False, True, self.refScope) @@ -922,10 +911,10 @@ def load( baseuri: str, loadingOptions: LoadingOptions, docRoot: Optional[str] = None, - lc: Optional[List[Any]] = None, + lc: Optional[list[Any]] = None, ) -> Any: if isinstance(doc, MutableSequence): - r: List[Any] = [] + r: list[Any] = [] for d in doc: if isinstance(d, str): resolved = self.resolve(d, baseuri, loadingOptions) @@ -957,10 +946,10 @@ def load( baseuri: str, loadingOptions: LoadingOptions, docRoot: Optional[str] = None, - lc: Optional[List[Any]] = None, + lc: Optional[list[Any]] = None, ) -> Any: if isinstance(doc, MutableMapping): - r: List[Any] = [] + r: list[Any] = [] for k in sorted(doc.keys()): val = doc[k] if isinstance(val, CommentedMap): @@ -990,7 +979,7 @@ def _document_load( baseuri: str, loadingOptions: LoadingOptions, addl_metadata_fields: Optional[MutableSequence[str]] = None, -) -> Tuple[Any, LoadingOptions]: +) -> tuple[Any, LoadingOptions]: if isinstance(doc, str): return _document_load_by_url( loader, @@ -1059,7 +1048,7 @@ def _document_load_by_url( url: str, loadingOptions: LoadingOptions, addl_metadata_fields: Optional[MutableSequence[str]] = None, -) -> Tuple[Any, LoadingOptions]: +) -> tuple[Any, LoadingOptions]: if url in loadingOptions.idx: return loadingOptions.idx[url] @@ -1101,7 +1090,7 @@ def file_uri(path: str, split_frag: bool = False) -> str: return f"file://{urlpath}{frag}" -def prefix_url(url: str, namespaces: Dict[str, str]) -> str: +def prefix_url(url: str, namespaces: dict[str, str]) -> str: """Expand short forms into full URLs using the given namespace dictionary.""" for k, v in namespaces.items(): if url.startswith(v): @@ -1178,7 +1167,7 @@ def __init__( name: Any, type_: Any, doc: Optional[Any] = None, - extension_fields: Optional[Dict[str, Any]] = None, + extension_fields: Optional[dict[str, Any]] = None, loadingOptions: Optional[LoadingOptions] = None, ) -> None: if extension_fields: @@ -1352,7 +1341,7 @@ def fromDoc( [e], ) ) - extension_fields: Dict[str, Any] = {} + extension_fields: dict[str, Any] = {} for k in _doc.keys(): if k not in cls.attrs: if not k: @@ -1388,8 +1377,8 @@ def fromDoc( def save( self, top: bool = False, base_url: str = "", relative_uris: bool = True - ) -> Dict[str, Any]: - r: Dict[str, Any] = {} + ) -> dict[str, Any]: + r: dict[str, Any] = {} if relative_uris: for ef in self.extension_fields: @@ -1425,7 +1414,7 @@ def __init__( self, type_: Any, fields: Optional[Any] = None, - extension_fields: Optional[Dict[str, Any]] = None, + extension_fields: Optional[dict[str, Any]] = None, loadingOptions: Optional[LoadingOptions] = None, ) -> None: if extension_fields: @@ -1544,7 +1533,7 @@ def fromDoc( [e], ) ) - extension_fields: Dict[str, Any] = {} + extension_fields: dict[str, Any] = {} for k in _doc.keys(): if k not in cls.attrs: if not k: @@ -1578,8 +1567,8 @@ def fromDoc( def save( self, top: bool = False, base_url: str = "", relative_uris: bool = True - ) -> Dict[str, Any]: - r: Dict[str, Any] = {} + ) -> dict[str, Any]: + r: dict[str, Any] = {} if relative_uris: for ef in self.extension_fields: @@ -1617,7 +1606,7 @@ def __init__( self, symbols: Any, type_: Any, - extension_fields: Optional[Dict[str, Any]] = None, + extension_fields: Optional[dict[str, Any]] = None, loadingOptions: Optional[LoadingOptions] = None, ) -> None: if extension_fields: @@ -1737,7 +1726,7 @@ def fromDoc( [e], ) ) - extension_fields: Dict[str, Any] = {} + extension_fields: dict[str, Any] = {} for k in _doc.keys(): if k not in cls.attrs: if not k: @@ -1771,8 +1760,8 @@ def fromDoc( def save( self, top: bool = False, base_url: str = "", relative_uris: bool = True - ) -> Dict[str, Any]: - r: Dict[str, Any] = {} + ) -> dict[str, Any]: + r: dict[str, Any] = {} if relative_uris: for ef in self.extension_fields: @@ -1804,7 +1793,7 @@ def __init__( self, items: Any, type_: Any, - extension_fields: Optional[Dict[str, Any]] = None, + extension_fields: Optional[dict[str, Any]] = None, loadingOptions: Optional[LoadingOptions] = None, ) -> None: if extension_fields: @@ -1924,7 +1913,7 @@ def fromDoc( [e], ) ) - extension_fields: Dict[str, Any] = {} + extension_fields: dict[str, Any] = {} for k in _doc.keys(): if k not in cls.attrs: if not k: @@ -1958,8 +1947,8 @@ def fromDoc( def save( self, top: bool = False, base_url: str = "", relative_uris: bool = True - ) -> Dict[str, Any]: - r: Dict[str, Any] = {} + ) -> dict[str, Any]: + r: dict[str, Any] = {} if relative_uris: for ef in self.extension_fields: @@ -2044,7 +2033,7 @@ def __init__( self, top: Any, left: Any, - extension_fields: Optional[Dict[str, Any]] = None, + extension_fields: Optional[dict[str, Any]] = None, loadingOptions: Optional[LoadingOptions] = None, ) -> None: if extension_fields: @@ -2164,7 +2153,7 @@ def fromDoc( [e], ) ) - extension_fields: Dict[str, Any] = {} + extension_fields: dict[str, Any] = {} for k in _doc.keys(): if k not in cls.attrs: if not k: @@ -2198,8 +2187,8 @@ def fromDoc( def save( self, top: bool = False, base_url: str = "", relative_uris: bool = True - ) -> Dict[str, Any]: - r: Dict[str, Any] = {} + ) -> dict[str, Any]: + r: dict[str, Any] = {} if relative_uris: for ef in self.extension_fields: @@ -2238,7 +2227,7 @@ def __init__( name: Any, owner: Any, tool_shed: Any, - extension_fields: Optional[Dict[str, Any]] = None, + extension_fields: Optional[dict[str, Any]] = None, loadingOptions: Optional[LoadingOptions] = None, ) -> None: if extension_fields: @@ -2457,7 +2446,7 @@ def fromDoc( [e], ) ) - extension_fields: Dict[str, Any] = {} + extension_fields: dict[str, Any] = {} for k in _doc.keys(): if k not in cls.attrs: if not k: @@ -2494,8 +2483,8 @@ def fromDoc( def save( self, top: bool = False, base_url: str = "", relative_uris: bool = True - ) -> Dict[str, Any]: - r: Dict[str, Any] = {} + ) -> dict[str, Any]: + r: dict[str, Any] = {} if relative_uris: for ef in self.extension_fields: @@ -2548,7 +2537,7 @@ def __init__( position: Optional[Any] = None, format: Optional[Any] = None, collection_type: Optional[Any] = None, - extension_fields: Optional[Dict[str, Any]] = None, + extension_fields: Optional[dict[str, Any]] = None, loadingOptions: Optional[LoadingOptions] = None, ) -> None: if extension_fields: @@ -2991,7 +2980,7 @@ def fromDoc( [e], ) ) - extension_fields: Dict[str, Any] = {} + extension_fields: dict[str, Any] = {} for k in _doc.keys(): if k not in cls.attrs: if not k: @@ -3033,8 +3022,8 @@ def fromDoc( def save( self, top: bool = False, base_url: str = "", relative_uris: bool = True - ) -> Dict[str, Any]: - r: Dict[str, Any] = {} + ) -> dict[str, Any]: + r: dict[str, Any] = {} if relative_uris: for ef in self.extension_fields: @@ -3120,7 +3109,7 @@ def __init__( id: Optional[Any] = None, outputSource: Optional[Any] = None, type_: Optional[Any] = None, - extension_fields: Optional[Dict[str, Any]] = None, + extension_fields: Optional[dict[str, Any]] = None, loadingOptions: Optional[LoadingOptions] = None, ) -> None: if extension_fields: @@ -3379,7 +3368,7 @@ def fromDoc( [e], ) ) - extension_fields: Dict[str, Any] = {} + extension_fields: dict[str, Any] = {} for k in _doc.keys(): if k not in cls.attrs: if not k: @@ -3417,8 +3406,8 @@ def fromDoc( def save( self, top: bool = False, base_url: str = "", relative_uris: bool = True - ) -> Dict[str, Any]: - r: Dict[str, Any] = {} + ) -> dict[str, Any]: + r: dict[str, Any] = {} if relative_uris: for ef in self.extension_fields: @@ -3507,7 +3496,7 @@ def __init__( run: Optional[Any] = None, runtime_inputs: Optional[Any] = None, when: Optional[Any] = None, - extension_fields: Optional[Dict[str, Any]] = None, + extension_fields: Optional[dict[str, Any]] = None, loadingOptions: Optional[LoadingOptions] = None, ) -> None: if extension_fields: @@ -4304,7 +4293,7 @@ def fromDoc( [e], ) ) - extension_fields: Dict[str, Any] = {} + extension_fields: dict[str, Any] = {} for k in _doc.keys(): if k not in cls.attrs: if not k: @@ -4354,8 +4343,8 @@ def fromDoc( def save( self, top: bool = False, base_url: str = "", relative_uris: bool = True - ) -> Dict[str, Any]: - r: Dict[str, Any] = {} + ) -> dict[str, Any]: + r: dict[str, Any] = {} if relative_uris: for ef in self.extension_fields: @@ -4489,7 +4478,7 @@ def __init__( source: Optional[Any] = None, label: Optional[Any] = None, default: Optional[Any] = None, - extension_fields: Optional[Dict[str, Any]] = None, + extension_fields: Optional[dict[str, Any]] = None, loadingOptions: Optional[LoadingOptions] = None, ) -> None: if extension_fields: @@ -4705,7 +4694,7 @@ def fromDoc( [e], ) ) - extension_fields: Dict[str, Any] = {} + extension_fields: dict[str, Any] = {} for k in _doc.keys(): if k not in cls.attrs: if not k: @@ -4742,8 +4731,8 @@ def fromDoc( def save( self, top: bool = False, base_url: str = "", relative_uris: bool = True - ) -> Dict[str, Any]: - r: Dict[str, Any] = {} + ) -> dict[str, Any]: + r: dict[str, Any] = {} if relative_uris: for ef in self.extension_fields: @@ -4787,7 +4776,7 @@ class Report(Saveable): def __init__( self, markdown: Any, - extension_fields: Optional[Dict[str, Any]] = None, + extension_fields: Optional[dict[str, Any]] = None, loadingOptions: Optional[LoadingOptions] = None, ) -> None: if extension_fields: @@ -4864,7 +4853,7 @@ def fromDoc( [e], ) ) - extension_fields: Dict[str, Any] = {} + extension_fields: dict[str, Any] = {} for k in _doc.keys(): if k not in cls.attrs: if not k: @@ -4895,8 +4884,8 @@ def fromDoc( def save( self, top: bool = False, base_url: str = "", relative_uris: bool = True - ) -> Dict[str, Any]: - r: Dict[str, Any] = {} + ) -> dict[str, Any]: + r: dict[str, Any] = {} if relative_uris: for ef in self.extension_fields: @@ -4943,7 +4932,7 @@ def __init__( remove_tags: Optional[Any] = None, rename: Optional[Any] = None, set_columns: Optional[Any] = None, - extension_fields: Optional[Dict[str, Any]] = None, + extension_fields: Optional[dict[str, Any]] = None, loadingOptions: Optional[LoadingOptions] = None, ) -> None: if extension_fields: @@ -5343,7 +5332,7 @@ def fromDoc( [e], ) ) - extension_fields: Dict[str, Any] = {} + extension_fields: dict[str, Any] = {} for k in _doc.keys(): if k not in cls.attrs: if not k: @@ -5384,8 +5373,8 @@ def fromDoc( def save( self, top: bool = False, base_url: str = "", relative_uris: bool = True - ) -> Dict[str, Any]: - r: Dict[str, Any] = {} + ) -> dict[str, Any]: + r: dict[str, Any] = {} if relative_uris: for ef in self.extension_fields: @@ -5490,7 +5479,7 @@ def __init__( creator: Optional[Any] = None, license: Optional[Any] = None, release: Optional[Any] = None, - extension_fields: Optional[Dict[str, Any]] = None, + extension_fields: Optional[dict[str, Any]] = None, loadingOptions: Optional[LoadingOptions] = None, ) -> None: if extension_fields: @@ -6077,7 +6066,7 @@ def fromDoc( [e], ) ) - extension_fields: Dict[str, Any] = {} + extension_fields: dict[str, Any] = {} for k in _doc.keys(): if k not in cls.attrs: if not k: @@ -6122,8 +6111,8 @@ def fromDoc( def save( self, top: bool = False, base_url: str = "", relative_uris: bool = True - ) -> Dict[str, Any]: - r: Dict[str, Any] = {} + ) -> dict[str, Any]: + r: dict[str, Any] = {} if relative_uris: for ef in self.extension_fields: diff --git a/typescript/docs/classes/ArraySchema.html b/typescript/docs/classes/ArraySchema.html index b17fcad..5fb71c6 100644 --- a/typescript/docs/classes/ArraySchema.html +++ b/typescript/docs/classes/ArraySchema.html @@ -1,10 +1,10 @@ ArraySchema | org.galaxyproject.gxformat2.v19_09
Options
All
  • Public
  • Public/Protected
  • All
Menu

Auto-generated class implementation for https://w3id.org/cwl/salad#ArraySchema

-

Hierarchy

  • Saveable
    • ArraySchema

Implements

Index

Constructors

Properties

extensionFields?: Dictionary<any>
items: string | ArraySchema | RecordSchema | EnumSchema | (string | ArraySchema | RecordSchema | EnumSchema)[]
+

Hierarchy

  • Saveable
    • ArraySchema

Implements

Index

Constructors

  • Parameters

    Returns ArraySchema

Properties

extensionFields?: Dictionary<any>
items: string | ArraySchema | RecordSchema | EnumSchema | (string | ArraySchema | RecordSchema | EnumSchema)[]

Defines the type of the array elements.

-
loadingOptions: LoadingOptions
type: ARRAY
+
loadingOptions: LoadingOptions
type: ARRAY

Must be array

-
attr: Set<string> = ...

Methods

  • save(top?: boolean, baseUrl?: string, relativeUris?: boolean): Dictionary<any>
  • Parameters

    • top: boolean = false
    • baseUrl: string = ''
    • relativeUris: boolean = true

    Returns Dictionary<any>

  • fromDoc(__doc: any, baseuri: string, loadingOptions: LoadingOptions, docRoot?: string): Promise<Saveable>
attr: Set<string> = ...

Methods

  • save(top?: boolean, baseUrl?: string, relativeUris?: boolean): Dictionary<any>
  • Parameters

    • top: boolean = false
    • baseUrl: string = ''
    • relativeUris: boolean = true

    Returns Dictionary<any>

  • fromDoc(__doc: any, baseuri: string, loadingOptions: LoadingOptions, docRoot?: string): Promise<Saveable>
  • Used to construct instances of .

    throws

    ValidationException If the document fragment is not a {@link Dictionary} or validation of fields fails.

    diff --git a/typescript/docs/classes/EnumSchema.html b/typescript/docs/classes/EnumSchema.html index 390e90a..5f5b97a 100644 --- a/typescript/docs/classes/EnumSchema.html +++ b/typescript/docs/classes/EnumSchema.html @@ -1,11 +1,11 @@ EnumSchema | org.galaxyproject.gxformat2.v19_09
    Options
    All
    • Public
    • Public/Protected
    • All
    Menu

    Auto-generated class implementation for https://w3id.org/cwl/salad#EnumSchema

    Define an enumerated type.

    -

    Hierarchy

    • Saveable
      • EnumSchema

    Implements

    Index

    Constructors

    Properties

    extensionFields?: Dictionary<any>
    loadingOptions: LoadingOptions
    symbols: string[]
    +

    Hierarchy

    • Saveable
      • EnumSchema

    Implements

    Index

    Constructors

    • Parameters

      Returns EnumSchema

    Properties

    extensionFields?: Dictionary<any>
    loadingOptions: LoadingOptions
    symbols: string[]

    Defines the set of valid symbols.

    -
    type: ENUM
    +
    type: ENUM

    Must be enum

    -
    attr: Set<string> = ...

    Methods

    • save(top?: boolean, baseUrl?: string, relativeUris?: boolean): Dictionary<any>
    • Parameters

      • top: boolean = false
      • baseUrl: string = ''
      • relativeUris: boolean = true

      Returns Dictionary<any>

    • fromDoc(__doc: any, baseuri: string, loadingOptions: LoadingOptions, docRoot?: string): Promise<Saveable>
    attr: Set<string> = ...

    Methods

    • save(top?: boolean, baseUrl?: string, relativeUris?: boolean): Dictionary<any>
    • Parameters

      • top: boolean = false
      • baseUrl: string = ''
      • relativeUris: boolean = true

      Returns Dictionary<any>

    • fromDoc(__doc: any, baseuri: string, loadingOptions: LoadingOptions, docRoot?: string): Promise<Saveable>
    • Used to construct instances of .

      throws

      ValidationException If the document fragment is not a {@link Dictionary} or validation of fields fails.

      diff --git a/typescript/docs/classes/GalaxyWorkflow.html b/typescript/docs/classes/GalaxyWorkflow.html index 47f61d1..e8f2fbc 100644 --- a/typescript/docs/classes/GalaxyWorkflow.html +++ b/typescript/docs/classes/GalaxyWorkflow.html @@ -12,13 +12,13 @@

      A note about label field.

      users will primarily identify the workflow using. Legacy support - this may also be called 'name' and Galaxy will consume the workflow document fine and treat this attribute correctly - however in order to validate against this workflow definition schema the attribute should be called label.

      -

Hierarchy

  • Saveable
    • GalaxyWorkflow

Implements

Index

Constructors

Properties

class_: string
creator?: any
+

Hierarchy

  • Saveable
    • GalaxyWorkflow

Implements

Index

Constructors

Properties

class_: string
creator?: any

Can be a schema.org Person (https://schema.org/Person) or Organization (https://schema.org/Organization) entity

-
doc?: string | string[]
+
doc?: string | string[]

A documentation string for this object, or an array of strings which should be concatenated.

-
extensionFields?: Dictionary<any>
id?: string
+
extensionFields?: Dictionary<any>
id?: string

The unique identifier for this object.

-
+

Defines the input parameters of the process. The process is ready to run when all required input parameters are associated with concrete values. Input parameters include a schema for each parameter which is @@ -29,25 +29,25 @@

A note about label field.

assigned a value of null (or the value of default for that parameter, if provided) for the purposes of validation and evaluation of expressions.

-
label?: string
+
label?: string

A short, human-readable label of this object.

-
license?: string
+
license?: string

Must be a valid license listed at https://spdx.org/licenses/

-
loadingOptions: LoadingOptions
+
loadingOptions: LoadingOptions

Defines the parameters representing the output of the process. May be used to generate and/or validate the output object.

-
release?: string
+
release?: string

If listed should correspond to the release of the workflow in its source reposiory.

-
report?: Report
+
report?: Report

Workflow invocation report template.

-
steps: WorkflowStep[]
+
steps: WorkflowStep[]

The individual steps that make up the workflow. Each step is executed when all of its input data links are fulfilled.

-
tags?: string[]
+
tags?: string[]

Tags for the workflow.

-
uuid?: string
+
uuid?: string

UUID uniquely representing this element.

-
attr: Set<string> = ...

Methods

  • save(top?: boolean, baseUrl?: string, relativeUris?: boolean): Dictionary<any>
  • Parameters

    • top: boolean = false
    • baseUrl: string = ''
    • relativeUris: boolean = true

    Returns Dictionary<any>

  • fromDoc(__doc: any, baseuri: string, loadingOptions: LoadingOptions, docRoot?: string): Promise<Saveable>
attr: Set<string> = ...

Methods

  • save(top?: boolean, baseUrl?: string, relativeUris?: boolean): Dictionary<any>
  • Parameters

    • top: boolean = false
    • baseUrl: string = ''
    • relativeUris: boolean = true

    Returns Dictionary<any>

  • fromDoc(__doc: any, baseuri: string, loadingOptions: LoadingOptions, docRoot?: string): Promise<Saveable>

Hierarchy

  • Saveable
    • WorkflowOutputParameter

Implements

Index

Constructors

Properties

doc?: string | string[]
+

Hierarchy

  • Saveable
    • WorkflowOutputParameter

Implements

Index

Constructors

Properties

doc?: string | string[]

A documentation string for this object, or an array of strings which should be concatenated.

-
extensionFields?: Dictionary<any>
id?: string
+
extensionFields?: Dictionary<any>
id?: string

The unique identifier for this object.

-
label?: string
+
label?: string

A short, human-readable label of this object.

-
loadingOptions: LoadingOptions
outputSource?: string
+
loadingOptions: LoadingOptions
outputSource?: string

Specifies workflow parameter that supply the value of to the output parameter.

-
type?: GalaxyType
+
type?: GalaxyType

Specify valid types of data that may be assigned to this parameter.

-
attr: Set<string> = ...

Methods

  • save(top?: boolean, baseUrl?: string, relativeUris?: boolean): Dictionary<any>
  • fromDoc(__doc: any, baseuri: string, loadingOptions: LoadingOptions, docRoot?: string): Promise<Saveable>
attr: Set<string> = ...

Methods

  • save(top?: boolean, baseUrl?: string, relativeUris?: boolean): Dictionary<any>
  • Parameters

    • top: boolean = false
    • baseUrl: string = ''
    • relativeUris: boolean = true

    Returns Dictionary<any>

  • fromDoc(__doc: any, baseuri: string, loadingOptions: LoadingOptions, docRoot?: string): Promise<Saveable>
  • Used to construct instances of .

    throws

    ValidationException If the document fragment is not a {@link Dictionary} or validation of fields fails.

    diff --git a/typescript/docs/classes/WorkflowStep.html b/typescript/docs/classes/WorkflowStep.html index 4689ab6..13b482c 100644 --- a/typescript/docs/classes/WorkflowStep.html +++ b/typescript/docs/classes/WorkflowStep.html @@ -14,53 +14,53 @@

    A note about state and tool_state fields.

    Galaxy but shouldn't be written by humans.

    state can contained a typed map. Repeat values can be represented as YAML arrays. An alternative to representing state this way is defining inputs with default values.

    -

Hierarchy

  • Saveable
    • WorkflowStep

Implements

Index

Constructors

Properties

doc?: string | string[]
+

Hierarchy

  • Saveable
    • WorkflowStep

Implements

Index

Constructors

  • Parameters

    Returns WorkflowStep

Properties

doc?: string | string[]

A documentation string for this object, or an array of strings which should be concatenated.

-
errors?: string
+
errors?: string

During Galaxy export there may be some problem validating the tool state, tool used, etc.. that will be indicated by this field. The Galaxy user should be warned of these problems before the workflow can be used in Galaxy.

This field should not be used in human written Galaxy workflow files.

A typical problem is the referenced tool is not installed, this can be fixed by installed the tool and re-saving the workflow and then re-exporting it.

-
extensionFields?: Dictionary<any>
id?: string
+
extensionFields?: Dictionary<any>
id?: string

The unique identifier for this object.

-
+

Defines the input parameters of the workflow step. The process is ready to run when all required input parameters are associated with concrete values. Input parameters include a schema for each parameter which is used to validate the input object. It may also be used build a user interface for constructing the input object.

-
label?: string
+
label?: string

A short, human-readable label of this object.

-
loadingOptions: LoadingOptions
out?: (string | WorkflowStepOutput)[]
+
loadingOptions: LoadingOptions
out?: (string | WorkflowStepOutput)[]

Defines the parameters representing the output of the process. May be used to generate and/or validate the output object.

This can also be called 'outputs' for legacy reasons - but the resulting workflow document is not a valid instance of this schema.

-
position?: StepPosition
+
position?: StepPosition

Specifies a subworkflow to run.

-
runtime_inputs?: string[]
state?: any
+
runtime_inputs?: string[]
state?: any

Structured tool state.

-
tool_id?: string
+
tool_id?: string

The tool ID used to run this step of the workflow (e.g. 'cat1' or 'toolshed.g2.bx.psu.edu/repos/nml/collapse_collections/collapse_dataset/4.0').

-
tool_shed_repository?: ToolShedRepository
+
tool_shed_repository?: ToolShedRepository

The Galaxy Tool Shed repository that should be installed in order to use this tool.

-
tool_state?: any
+
tool_state?: any

Unstructured tool state.

-
tool_version?: string
+
tool_version?: string

The tool version corresponding used to run this step of the workflow. For tool shed installed tools, the ID generally uniquely specifies a version and this field is optional.

-
+

Workflow step module's type (defaults to 'tool').

-
uuid?: string
+
uuid?: string

UUID uniquely representing this element.

-
when?: string
+
when?: string

If defined, only run the step when the expression evaluates to true. If false the step is skipped. A skipped step produces a null on each output.

Expression should be an ecma5.1 expression.

-
attr: Set<string> = ...

Methods

  • save(top?: boolean, baseUrl?: string, relativeUris?: boolean): Dictionary<any>
  • Parameters

    • top: boolean = false
    • baseUrl: string = ''
    • relativeUris: boolean = true

    Returns Dictionary<any>

  • fromDoc(__doc: any, baseuri: string, loadingOptions: LoadingOptions, docRoot?: string): Promise<Saveable>
attr: Set<string> = ...

Methods

  • save(top?: boolean, baseUrl?: string, relativeUris?: boolean): Dictionary<any>
  • Parameters

    • top: boolean = false
    • baseUrl: string = ''
    • relativeUris: boolean = true

    Returns Dictionary<any>

  • fromDoc(__doc: any, baseuri: string, loadingOptions: LoadingOptions, docRoot?: string): Promise<Saveable>

Hierarchy

  • Saveable
    • WorkflowStepOutput

Implements

Index

Constructors

Properties

add_tags?: string[]
change_datatype?: string
delete_intermediate_datasets?: boolean
extensionFields?: Dictionary<any>
hide?: boolean
id?: string
+

Hierarchy

  • Saveable
    • WorkflowStepOutput

Implements

Index

Constructors

Properties

add_tags?: string[]
change_datatype?: string
delete_intermediate_datasets?: boolean
extensionFields?: Dictionary<any>
hide?: boolean
id?: string

The unique identifier for this object.

-
loadingOptions: LoadingOptions
remove_tags?: string[]
rename?: string
set_columns?: string[]
attr: Set<string> = ...

Methods

  • save(top?: boolean, baseUrl?: string, relativeUris?: boolean): Dictionary<any>
  • Parameters

    • top: boolean = false
    • baseUrl: string = ''
    • relativeUris: boolean = true

    Returns Dictionary<any>

  • fromDoc(__doc: any, baseuri: string, loadingOptions: LoadingOptions, docRoot?: string): Promise<Saveable>
loadingOptions: LoadingOptions
remove_tags?: string[]
rename?: string
set_columns?: string[]
attr: Set<string> = ...

Methods

  • save(top?: boolean, baseUrl?: string, relativeUris?: boolean): Dictionary<any>
  • Parameters

    • top: boolean = false
    • baseUrl: string = ''
    • relativeUris: boolean = true

    Returns Dictionary<any>

  • fromDoc(__doc: any, baseuri: string, loadingOptions: LoadingOptions, docRoot?: string): Promise<Saveable>

Hierarchy

Implemented by

Index

Properties

class_?: string
creator?: any
+

Hierarchy

Implemented by

Index

Properties

class_?: string
creator?: any

Can be a schema.org Person (https://schema.org/Person) or Organization (https://schema.org/Organization) entity

-
doc?: string | string[]
+
doc?: string | string[]

A documentation string for this object, or an array of strings which should be concatenated.

-
extensionFields?: Dictionary<any>
id?: string
+
extensionFields?: Dictionary<any>
id?: string

The unique identifier for this object.

-
+

Defines the input parameters of the process. The process is ready to run when all required input parameters are associated with concrete values. Input parameters include a schema for each parameter which is @@ -29,22 +29,22 @@

A note about label field.

assigned a value of null (or the value of default for that parameter, if provided) for the purposes of validation and evaluation of expressions.

-
label?: string
+
label?: string

A short, human-readable label of this object.

-
license?: string
+
license?: string

Must be a valid license listed at https://spdx.org/licenses/

-
+

Defines the parameters representing the output of the process. May be used to generate and/or validate the output object.

-
release?: string
+
release?: string

If listed should correspond to the release of the workflow in its source reposiory.

-
report?: Report
+
report?: Report

Workflow invocation report template.

-
steps: WorkflowStep[]
+
steps: WorkflowStep[]

The individual steps that make up the workflow. Each step is executed when all of its input data links are fulfilled.

-
tags?: string[]
+
tags?: string[]

Tags for the workflow.

-
uuid?: string
+
uuid?: string

UUID uniquely representing this element.

Generated using TypeDoc

\ No newline at end of file diff --git a/typescript/docs/interfaces/HasStepErrorsProperties.html b/typescript/docs/interfaces/HasStepErrorsProperties.html index ca20449..293b104 100644 --- a/typescript/docs/interfaces/HasStepErrorsProperties.html +++ b/typescript/docs/interfaces/HasStepErrorsProperties.html @@ -1,6 +1,6 @@ HasStepErrorsProperties | org.galaxyproject.gxformat2.v19_09
Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

Index

Properties

Properties

errors?: string
+

Hierarchy

Index

Properties

Properties

errors?: string

During Galaxy export there may be some problem validating the tool state, tool used, etc.. that will be indicated by this field. The Galaxy user should be warned of these problems before the workflow can be used in Galaxy.

diff --git a/typescript/docs/interfaces/HasStepPositionProperties.html b/typescript/docs/interfaces/HasStepPositionProperties.html index 532e645..c326e4d 100644 --- a/typescript/docs/interfaces/HasStepPositionProperties.html +++ b/typescript/docs/interfaces/HasStepPositionProperties.html @@ -1,3 +1,3 @@ HasStepPositionProperties | org.galaxyproject.gxformat2.v19_09
Options
All
  • Public
  • Public/Protected
  • All
Menu

Legend

  • Constructor
  • Property
  • Method
  • Static property
  • Static method
  • Property
  • Inherited property

Settings

Theme

Generated using TypeDoc

\ No newline at end of file +

Hierarchy

Index

Properties

Properties

position?: StepPosition

Generated using TypeDoc

\ No newline at end of file diff --git a/typescript/docs/interfaces/HasUUIDProperties.html b/typescript/docs/interfaces/HasUUIDProperties.html index 5cda86f..4ae4b4f 100644 --- a/typescript/docs/interfaces/HasUUIDProperties.html +++ b/typescript/docs/interfaces/HasUUIDProperties.html @@ -1,5 +1,5 @@ HasUUIDProperties | org.galaxyproject.gxformat2.v19_09
Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

Index

Properties

Properties

uuid?: string
+

Hierarchy

Index

Properties

Properties

uuid?: string

UUID uniquely representing this element.

Generated using TypeDoc

\ No newline at end of file diff --git a/typescript/docs/interfaces/IdentifiedProperties.html b/typescript/docs/interfaces/IdentifiedProperties.html index 3fc5cc2..7506f35 100644 --- a/typescript/docs/interfaces/IdentifiedProperties.html +++ b/typescript/docs/interfaces/IdentifiedProperties.html @@ -1,5 +1,5 @@ IdentifiedProperties | org.galaxyproject.gxformat2.v19_09
Options
All
  • Public
  • Public/Protected
  • All
Menu

Auto-generated interface for https://w3id.org/cwl/cwl#Identified

-

Hierarchy

Index

Properties

Properties

id?: string
+

Hierarchy

Index

Properties

Properties

id?: string

The unique identifier for this object.

Generated using TypeDoc

\ No newline at end of file diff --git a/typescript/docs/interfaces/InputParameterProperties.html b/typescript/docs/interfaces/InputParameterProperties.html index 77bea12..200625d 100644 --- a/typescript/docs/interfaces/InputParameterProperties.html +++ b/typescript/docs/interfaces/InputParameterProperties.html @@ -1,14 +1,14 @@ InputParameterProperties | org.galaxyproject.gxformat2.v19_09
Options
All
  • Public
  • Public/Protected
  • All
Menu

Auto-generated interface for https://w3id.org/cwl/cwl#InputParameter

-

Hierarchy

Index

Properties

default_?: any
+

Hierarchy

Index

Properties

default_?: any

The default value to use for this parameter if the parameter is missing from the input object, or if the value of the parameter in the input object is null. Default values are applied before evaluating expressions (e.g. dependent valueFrom fields).

-
doc?: string | string[]
+
doc?: string | string[]

A documentation string for this object, or an array of strings which should be concatenated.

-
id?: string
+
id?: string

The unique identifier for this object.

-
label?: string
+
label?: string

A short, human-readable label of this object.

Generated using TypeDoc

\ No newline at end of file diff --git a/typescript/docs/interfaces/LabeledProperties.html b/typescript/docs/interfaces/LabeledProperties.html index 8d8c25b..fe4ef14 100644 --- a/typescript/docs/interfaces/LabeledProperties.html +++ b/typescript/docs/interfaces/LabeledProperties.html @@ -1,5 +1,5 @@ LabeledProperties | org.galaxyproject.gxformat2.v19_09
Options
All
  • Public
  • Public/Protected
  • All
Menu

Auto-generated interface for https://w3id.org/cwl/cwl#Labeled

-

Hierarchy

Index

Properties

Properties

label?: string
+

Hierarchy

Index

Properties

Properties

label?: string

A short, human-readable label of this object.

Generated using TypeDoc

\ No newline at end of file diff --git a/typescript/docs/interfaces/OutputParameterProperties.html b/typescript/docs/interfaces/OutputParameterProperties.html index 68a2689..ff3757c 100644 --- a/typescript/docs/interfaces/OutputParameterProperties.html +++ b/typescript/docs/interfaces/OutputParameterProperties.html @@ -1,9 +1,9 @@ OutputParameterProperties | org.galaxyproject.gxformat2.v19_09
Options
All
  • Public
  • Public/Protected
  • All
Menu

Auto-generated interface for https://w3id.org/cwl/cwl#OutputParameter

-

Hierarchy

Index

Properties

Properties

doc?: string | string[]
+

Hierarchy

Index

Properties

Properties

doc?: string | string[]

A documentation string for this object, or an array of strings which should be concatenated.

-
id?: string
+
id?: string

The unique identifier for this object.

-
label?: string
+
label?: string

A short, human-readable label of this object.

Generated using TypeDoc

\ No newline at end of file diff --git a/typescript/docs/interfaces/ParameterProperties.html b/typescript/docs/interfaces/ParameterProperties.html index 7f118b5..3d1dc23 100644 --- a/typescript/docs/interfaces/ParameterProperties.html +++ b/typescript/docs/interfaces/ParameterProperties.html @@ -1,10 +1,10 @@ ParameterProperties | org.galaxyproject.gxformat2.v19_09
Options
All
  • Public
  • Public/Protected
  • All
Menu

Auto-generated interface for https://w3id.org/cwl/cwl#Parameter

Define an input or output parameter to a process.

-

Hierarchy

Index

Properties

Properties

doc?: string | string[]
+

Hierarchy

Index

Properties

Properties

doc?: string | string[]

A documentation string for this object, or an array of strings which should be concatenated.

-
id?: string
+
id?: string

The unique identifier for this object.

-
label?: string
+
label?: string

A short, human-readable label of this object.

Generated using TypeDoc

\ No newline at end of file diff --git a/typescript/docs/interfaces/ProcessProperties.html b/typescript/docs/interfaces/ProcessProperties.html index 590e9e8..5614050 100644 --- a/typescript/docs/interfaces/ProcessProperties.html +++ b/typescript/docs/interfaces/ProcessProperties.html @@ -3,11 +3,11 @@

The base executable type in CWL is the Process object defined by the document. Note that the Process object is abstract and cannot be directly executed.

-

Hierarchy

Index

Properties

doc?: string | string[]
+

Hierarchy

Index

Properties

doc?: string | string[]

A documentation string for this object, or an array of strings which should be concatenated.

-
id?: string
+
id?: string

The unique identifier for this object.

-
+

Defines the input parameters of the process. The process is ready to run when all required input parameters are associated with concrete values. Input parameters include a schema for each parameter which is @@ -18,9 +18,9 @@ assigned a value of null (or the value of default for that parameter, if provided) for the purposes of validation and evaluation of expressions.

-
label?: string
+
label?: string

A short, human-readable label of this object.

-
+

Defines the parameters representing the output of the process. May be used to generate and/or validate the output object.

Legend

  • Constructor
  • Property
  • Method
  • Static property
  • Static method
  • Property
  • Inherited property

Settings

Theme

Generated using TypeDoc

\ No newline at end of file diff --git a/typescript/docs/interfaces/RecordFieldProperties.html b/typescript/docs/interfaces/RecordFieldProperties.html index e7b8994..866cf6a 100644 --- a/typescript/docs/interfaces/RecordFieldProperties.html +++ b/typescript/docs/interfaces/RecordFieldProperties.html @@ -1,10 +1,10 @@ RecordFieldProperties | org.galaxyproject.gxformat2.v19_09
Options
All
  • Public
  • Public/Protected
  • All
Menu

Auto-generated interface for https://w3id.org/cwl/salad#RecordField

A field of a record.

-

Hierarchy

Implemented by

Index

Properties

doc?: string | string[]
+

Hierarchy

Implemented by

Index

Properties

doc?: string | string[]

A documentation string for this object, or an array of strings which should be concatenated.

-
extensionFields?: Dictionary<any>
name: string
+
extensionFields?: Dictionary<any>
name: string

The name of the field

-
+

The field type

Legend

  • Constructor
  • Property
  • Method
  • Static property
  • Static method
  • Property
  • Inherited property

Settings

Theme

Generated using TypeDoc

\ No newline at end of file diff --git a/typescript/docs/interfaces/RecordSchemaProperties.html b/typescript/docs/interfaces/RecordSchemaProperties.html index 94c443b..71b3a23 100644 --- a/typescript/docs/interfaces/RecordSchemaProperties.html +++ b/typescript/docs/interfaces/RecordSchemaProperties.html @@ -1,7 +1,7 @@ RecordSchemaProperties | org.galaxyproject.gxformat2.v19_09
Options
All
  • Public
  • Public/Protected
  • All
Menu

Auto-generated interface for https://w3id.org/cwl/salad#RecordSchema

-

Hierarchy

  • RecordSchemaProperties

Implemented by

Index

Properties

extensionFields?: Dictionary<any>
fields?: RecordField[]
+

Hierarchy

  • RecordSchemaProperties

Implemented by

Index

Properties

extensionFields?: Dictionary<any>
fields?: RecordField[]

Defines the fields of the record.

-
type: RECORD
+
type: RECORD

Must be record

Legend

  • Constructor
  • Property
  • Method
  • Static property
  • Static method
  • Property
  • Inherited property

Settings

Theme

Generated using TypeDoc

\ No newline at end of file diff --git a/typescript/docs/interfaces/ReferencesToolProperties.html b/typescript/docs/interfaces/ReferencesToolProperties.html index f35706c..9476965 100644 --- a/typescript/docs/interfaces/ReferencesToolProperties.html +++ b/typescript/docs/interfaces/ReferencesToolProperties.html @@ -1,10 +1,10 @@ ReferencesToolProperties | org.galaxyproject.gxformat2.v19_09
Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

Index

Properties

tool_id?: string
+

Hierarchy

Index

Properties

tool_id?: string

The tool ID used to run this step of the workflow (e.g. 'cat1' or 'toolshed.g2.bx.psu.edu/repos/nml/collapse_collections/collapse_dataset/4.0').

-
tool_shed_repository?: ToolShedRepository
+
tool_shed_repository?: ToolShedRepository

The Galaxy Tool Shed repository that should be installed in order to use this tool.

-
tool_version?: string
+
tool_version?: string

The tool version corresponding used to run this step of the workflow. For tool shed installed tools, the ID generally uniquely specifies a version and this field is optional.

Legend

  • Constructor
  • Property
  • Method
  • Static property
  • Static method
  • Property
  • Inherited property

Settings

Theme

Generated using TypeDoc

\ No newline at end of file diff --git a/typescript/docs/interfaces/ReportProperties.html b/typescript/docs/interfaces/ReportProperties.html index 22170f5..4c977ea 100644 --- a/typescript/docs/interfaces/ReportProperties.html +++ b/typescript/docs/interfaces/ReportProperties.html @@ -2,6 +2,6 @@

Auto-generated interface for https://galaxyproject.org/gxformat2/v19_09#Report

Definition of an invocation report for this workflow. Currently the only field is 'markdown'.

-

Hierarchy

Implemented by

Index

Properties

extensionFields?: Dictionary<any>
markdown: string
+

Hierarchy

  • ReportProperties

Implemented by

Index

Properties

extensionFields?: Dictionary<any>
markdown: string

Galaxy flavored Markdown to define an invocation report.

Legend

  • Constructor
  • Property
  • Method
  • Static property
  • Static method
  • Property
  • Inherited property

Settings

Theme

Generated using TypeDoc

\ No newline at end of file diff --git a/typescript/docs/interfaces/SinkProperties.html b/typescript/docs/interfaces/SinkProperties.html index 447dbd8..07fa198 100644 --- a/typescript/docs/interfaces/SinkProperties.html +++ b/typescript/docs/interfaces/SinkProperties.html @@ -1,6 +1,6 @@ SinkProperties | org.galaxyproject.gxformat2.v19_09
Options
All
  • Public
  • Public/Protected
  • All
Menu

Auto-generated interface for https://galaxyproject.org/gxformat2/v19_09#Sink

-

Hierarchy

Index

Properties

Properties

source?: string | string[]
+

Hierarchy

Index

Properties

Properties

source?: string | string[]

Specifies one or more workflow parameters that will provide input to the underlying step parameter.

Legend

  • Constructor
  • Property
  • Method
  • Static property
  • Static method
  • Property
  • Inherited property

Settings

Theme

Generated using TypeDoc

\ No newline at end of file diff --git a/typescript/docs/interfaces/StepPositionProperties.html b/typescript/docs/interfaces/StepPositionProperties.html index 7425e0c..1215ee6 100644 --- a/typescript/docs/interfaces/StepPositionProperties.html +++ b/typescript/docs/interfaces/StepPositionProperties.html @@ -1,8 +1,8 @@ StepPositionProperties | org.galaxyproject.gxformat2.v19_09
Options
All
  • Public
  • Public/Protected
  • All
Menu

This field specifies the location of the step's node when rendered in the workflow editor.

-

Hierarchy

  • StepPositionProperties

Implemented by

Index

Properties

extensionFields?: Dictionary<any>
left: number
+

Hierarchy

  • StepPositionProperties

Implemented by

Index

Properties

extensionFields?: Dictionary<any>
left: number

Relative horizontal position of the step's node when rendered in the workflow editor.

-
top: number
+
top: number

Relative vertical position of the step's node when rendered in the workflow editor.

Legend

  • Constructor
  • Property
  • Method
  • Static property
  • Static method
  • Property
  • Inherited property

Settings

Theme

Generated using TypeDoc

\ No newline at end of file diff --git a/typescript/docs/interfaces/ToolShedRepositoryProperties.html b/typescript/docs/interfaces/ToolShedRepositoryProperties.html index 251cdb5..2a0873d 100644 --- a/typescript/docs/interfaces/ToolShedRepositoryProperties.html +++ b/typescript/docs/interfaces/ToolShedRepositoryProperties.html @@ -1,11 +1,11 @@ ToolShedRepositoryProperties | org.galaxyproject.gxformat2.v19_09
Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

  • ToolShedRepositoryProperties

Implemented by

Index

Properties

changeset_revision: string
+

Hierarchy

  • ToolShedRepositoryProperties

Implemented by

Index

Properties

changeset_revision: string

The revision of the tool shed repository this tool can be found in.

-
extensionFields?: Dictionary<any>
name: string
+
extensionFields?: Dictionary<any>
name: string

The name of the tool shed repository this tool can be found in.

-
owner: string
+
owner: string

The owner of the tool shed repository this tool can be found in.

-
tool_shed: string
+
tool_shed: string

The URI of the tool shed containing the repository this tool can be found in - typically this should be toolshed.g2.bx.psu.edu.

Legend

  • Constructor
  • Property
  • Method
  • Static property
  • Static method
  • Property
  • Inherited property

Settings

Theme

Generated using TypeDoc

\ No newline at end of file diff --git a/typescript/docs/interfaces/WorkflowInputParameterProperties.html b/typescript/docs/interfaces/WorkflowInputParameterProperties.html index 4a4fd17..6aac54c 100644 --- a/typescript/docs/interfaces/WorkflowInputParameterProperties.html +++ b/typescript/docs/interfaces/WorkflowInputParameterProperties.html @@ -1,23 +1,23 @@ WorkflowInputParameterProperties | org.galaxyproject.gxformat2.v19_09
Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

Implemented by

Index

Properties

collection_type?: string
+

Hierarchy

Implemented by

Index

Properties

collection_type?: string

Collection type (defaults to list if type is collection). Nested collection types are separated with colons, e.g. list:list:paired.

-
default_?: any
+
default_?: any

The default value to use for this parameter if the parameter is missing from the input object, or if the value of the parameter in the input object is null. Default values are applied before evaluating expressions (e.g. dependent valueFrom fields).

-
doc?: string | string[]
+
doc?: string | string[]

A documentation string for this object, or an array of strings which should be concatenated.

-
extensionFields?: Dictionary<any>
format?: string[]
+
extensionFields?: Dictionary<any>
format?: string[]

Specify datatype extension for valid input datasets.

-
id?: string
+
id?: string

The unique identifier for this object.

-
label?: string
+
label?: string

A short, human-readable label of this object.

-
optional?: boolean
+
optional?: boolean

If set to true, WorkflowInputParameter is not required to submit the workflow.

-
position?: StepPosition
+
position?: StepPosition

Specify valid types of data that may be assigned to this parameter.

Legend

  • Constructor
  • Property
  • Method
  • Static property
  • Static method
  • Property
  • Inherited property

Settings

Theme

Generated using TypeDoc

\ No newline at end of file diff --git a/typescript/docs/interfaces/WorkflowOutputParameterProperties.html b/typescript/docs/interfaces/WorkflowOutputParameterProperties.html index 63bc05d..d6ba916 100644 --- a/typescript/docs/interfaces/WorkflowOutputParameterProperties.html +++ b/typescript/docs/interfaces/WorkflowOutputParameterProperties.html @@ -4,15 +4,15 @@ connected to one parameter defined in the workflow that will provide the value of the output parameter. It is legal to connect a WorkflowInputParameter to a WorkflowOutputParameter.

-

Hierarchy

Implemented by

Index

Properties

doc?: string | string[]
+

Hierarchy

Implemented by

Index

Properties

doc?: string | string[]

A documentation string for this object, or an array of strings which should be concatenated.

-
extensionFields?: Dictionary<any>
id?: string
+
extensionFields?: Dictionary<any>
id?: string

The unique identifier for this object.

-
label?: string
+
label?: string

A short, human-readable label of this object.

-
outputSource?: string
+
outputSource?: string

Specifies workflow parameter that supply the value of to the output parameter.

-
type?: GalaxyType
+
type?: GalaxyType

Specify valid types of data that may be assigned to this parameter.

Legend

  • Constructor
  • Property
  • Method
  • Static property
  • Static method
  • Property
  • Inherited property

Settings

Theme

Generated using TypeDoc

\ No newline at end of file diff --git a/typescript/docs/interfaces/WorkflowStepInputProperties.html b/typescript/docs/interfaces/WorkflowStepInputProperties.html index 8e8854e..d029a0e 100644 --- a/typescript/docs/interfaces/WorkflowStepInputProperties.html +++ b/typescript/docs/interfaces/WorkflowStepInputProperties.html @@ -1,15 +1,15 @@ WorkflowStepInputProperties | org.galaxyproject.gxformat2.v19_09
Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

Implemented by

Index

Properties

default_?: any
+

Hierarchy

Implemented by

Index

Properties

default_?: any

The default value for this parameter to use if either there is no source field, or the value produced by the source is null. The default must be applied prior to scattering or evaluating valueFrom.

-
extensionFields?: Dictionary<any>
id?: string
+
extensionFields?: Dictionary<any>
id?: string

The unique identifier for this object.

-
label?: string
+
label?: string

A short, human-readable label of this object.

-
source?: string | string[]
+
source?: string | string[]

Specifies one or more workflow parameters that will provide input to the underlying step parameter.

Legend

  • Constructor
  • Property
  • Method
  • Static property
  • Static method
  • Property
  • Inherited property

Settings

Theme

Generated using TypeDoc

\ No newline at end of file diff --git a/typescript/docs/interfaces/WorkflowStepOutputProperties.html b/typescript/docs/interfaces/WorkflowStepOutputProperties.html index 53330a3..fc38483 100644 --- a/typescript/docs/interfaces/WorkflowStepOutputProperties.html +++ b/typescript/docs/interfaces/WorkflowStepOutputProperties.html @@ -7,6 +7,6 @@

A unique identifier for this workflow output parameter. This is the identifier to use in the source field of WorkflowStepInput to connect the output value to downstream parameters.

-

Hierarchy

Implemented by

Index

Properties

add_tags?: string[]
change_datatype?: string
delete_intermediate_datasets?: boolean
extensionFields?: Dictionary<any>
hide?: boolean
id?: string
+

Hierarchy

Implemented by

Index

Properties

add_tags?: string[]
change_datatype?: string
delete_intermediate_datasets?: boolean
extensionFields?: Dictionary<any>
hide?: boolean
id?: string

The unique identifier for this object.

-
remove_tags?: string[]
rename?: string
set_columns?: string[]

Legend

  • Constructor
  • Property
  • Method
  • Static property
  • Static method
  • Property
  • Inherited property

Settings

Theme

Generated using TypeDoc

\ No newline at end of file +
remove_tags?: string[]
rename?: string
set_columns?: string[]

Generated using TypeDoc

\ No newline at end of file diff --git a/typescript/docs/interfaces/WorkflowStepProperties.html b/typescript/docs/interfaces/WorkflowStepProperties.html index 79e2920..f733f2b 100644 --- a/typescript/docs/interfaces/WorkflowStepProperties.html +++ b/typescript/docs/interfaces/WorkflowStepProperties.html @@ -14,48 +14,48 @@

A note about state and tool_state fields.

Galaxy but shouldn't be written by humans.

state can contained a typed map. Repeat values can be represented as YAML arrays. An alternative to representing state this way is defining inputs with default values.

-

Hierarchy

Implemented by

Index

Properties

doc?: string | string[]
+

Hierarchy

Implemented by

Index

Properties

doc?: string | string[]

A documentation string for this object, or an array of strings which should be concatenated.

-
errors?: string
+
errors?: string

During Galaxy export there may be some problem validating the tool state, tool used, etc.. that will be indicated by this field. The Galaxy user should be warned of these problems before the workflow can be used in Galaxy.

This field should not be used in human written Galaxy workflow files.

A typical problem is the referenced tool is not installed, this can be fixed by installed the tool and re-saving the workflow and then re-exporting it.

-
extensionFields?: Dictionary<any>
id?: string
+
extensionFields?: Dictionary<any>
id?: string

The unique identifier for this object.

-
+

Defines the input parameters of the workflow step. The process is ready to run when all required input parameters are associated with concrete values. Input parameters include a schema for each parameter which is used to validate the input object. It may also be used build a user interface for constructing the input object.

-
label?: string
+
label?: string

A short, human-readable label of this object.

-
out?: (string | WorkflowStepOutput)[]
+
out?: (string | WorkflowStepOutput)[]

Defines the parameters representing the output of the process. May be used to generate and/or validate the output object.

This can also be called 'outputs' for legacy reasons - but the resulting workflow document is not a valid instance of this schema.

-
position?: StepPosition
+
position?: StepPosition

Specifies a subworkflow to run.

-
runtime_inputs?: string[]
state?: any
+
runtime_inputs?: string[]
state?: any

Structured tool state.

-
tool_id?: string
+
tool_id?: string

The tool ID used to run this step of the workflow (e.g. 'cat1' or 'toolshed.g2.bx.psu.edu/repos/nml/collapse_collections/collapse_dataset/4.0').

-
tool_shed_repository?: ToolShedRepository
+
tool_shed_repository?: ToolShedRepository

The Galaxy Tool Shed repository that should be installed in order to use this tool.

-
tool_state?: any
+
tool_state?: any

Unstructured tool state.

-
tool_version?: string
+
tool_version?: string

The tool version corresponding used to run this step of the workflow. For tool shed installed tools, the ID generally uniquely specifies a version and this field is optional.

-
+

Workflow step module's type (defaults to 'tool').

-
uuid?: string
+
uuid?: string

UUID uniquely representing this element.

-
when?: string
+
when?: string

If defined, only run the step when the expression evaluates to true. If false the step is skipped. A skipped step produces a null on each output.

diff --git a/typescript/docs/modules.html b/typescript/docs/modules.html index 2430719..a4401cd 100644 --- a/typescript/docs/modules.html +++ b/typescript/docs/modules.html @@ -1,4 +1,4 @@ -org.galaxyproject.gxformat2.v19_09
Options
All
  • Public
  • Public/Protected
  • All
Menu

org.galaxyproject.gxformat2.v19_09

Index

Functions

  • shortname(inputId: string): string
  • +org.galaxyproject.gxformat2.v19_09
    Options
    All
    • Public
    • Public/Protected
    • All
    Menu

    org.galaxyproject.gxformat2.v19_09

    Index

    Functions

    • Parameters

      • doc: any
      • Optional baseuri: string
      • Optional loadingOptions: LoadingOptions

      Returns Promise<GalaxyWorkflow | GalaxyWorkflow[]>

    • Parameters

      • doc: string
      • uri: string
      • Optional loadingOptions: LoadingOptions

      Returns Promise<GalaxyWorkflow | GalaxyWorkflow[]>

    • shortname(inputId: string): string

    Legend

    • Constructor
    • Property
    • Method
    • Static property
    • Static method
    • Property
    • Inherited property

    Settings

    Theme

    Generated using TypeDoc

    \ No newline at end of file From 7ad3e03c7e2042de2315145304b0a2a17a8acd59 Mon Sep 17 00:00:00 2001 From: mvdbeek Date: Mon, 2 Dec 2024 16:12:12 +0100 Subject: [PATCH 2/4] Bump up python version --- .github/workflows/maven.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/maven.yml b/.github/workflows/maven.yml index 574e64a..60ca569 100644 --- a/.github/workflows/maven.yml +++ b/.github/workflows/maven.yml @@ -9,7 +9,7 @@ jobs: - name: Set up Python uses: actions/setup-python@v1 with: - python-version: 3.7 + python-version: 3.8 - name: Install Python dependencies run: | python -m pip install --upgrade pip From 633a5d3e498b6151f09fade187f22397c22ae87e Mon Sep 17 00:00:00 2001 From: mvdbeek Date: Mon, 2 Dec 2024 16:16:17 +0100 Subject: [PATCH 3/4] Update codecov action --- .github/workflows/typescript.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/typescript.yaml b/.github/workflows/typescript.yaml index 4970a4a..a8e5596 100644 --- a/.github/workflows/typescript.yaml +++ b/.github/workflows/typescript.yaml @@ -28,7 +28,7 @@ jobs: - run: npm install - run: npm test - name: Upload coverage to Codecov - uses: codecov/codecov-action@v2.1.0 + uses: codecov/codecov-action@v5.0.7 with: directory: ./typescript fail_ci_if_error: true From c13768df2b99bea572b223ae927b18da0c1b7fb8 Mon Sep 17 00:00:00 2001 From: mvdbeek Date: Mon, 2 Dec 2024 16:44:03 +0100 Subject: [PATCH 4/4] Use last schema-salad version that supports python 3.7 --- gxformat2/schema/v19_09.py | 215 +++++++++++++++++++------------------ requirements.txt | 2 +- 2 files changed, 114 insertions(+), 103 deletions(-) diff --git a/gxformat2/schema/v19_09.py b/gxformat2/schema/v19_09.py index b5ade5a..5d6778e 100644 --- a/gxformat2/schema/v19_09.py +++ b/gxformat2/schema/v19_09.py @@ -11,10 +11,21 @@ import uuid as _uuid__ # pylint: disable=unused-import # noqa: F401 import xml.sax # nosec from abc import ABC, abstractmethod -from collections.abc import MutableMapping, MutableSequence, Sequence from io import StringIO from itertools import chain -from typing import Any, Optional, Union, cast +from typing import ( + Any, + Dict, + List, + MutableMapping, + MutableSequence, + Optional, + Sequence, + Tuple, + Type, + Union, + cast, +) from urllib.parse import quote, urldefrag, urlparse, urlsplit, urlunsplit from urllib.request import pathname2url @@ -27,13 +38,13 @@ from schema_salad.sourceline import SourceLine, add_lc_filename from schema_salad.utils import CacheType, yaml_no_ts # requires schema-salad v8.2+ -_vocab: dict[str, str] = {} -_rvocab: dict[str, str] = {} +_vocab: Dict[str, str] = {} +_rvocab: Dict[str, str] = {} _logger = logging.getLogger("salad") -IdxType = MutableMapping[str, tuple[Any, "LoadingOptions"]] +IdxType = MutableMapping[str, Tuple[Any, "LoadingOptions"]] class LoadingOptions: @@ -45,27 +56,27 @@ class LoadingOptions: original_doc: Optional[Any] addl_metadata: MutableMapping[str, Any] fetcher: Fetcher - vocab: dict[str, str] - rvocab: dict[str, str] + vocab: Dict[str, str] + rvocab: Dict[str, str] cache: CacheType - imports: list[str] - includes: list[str] + imports: List[str] + includes: List[str] no_link_check: Optional[bool] container: Optional[str] def __init__( self, fetcher: Optional[Fetcher] = None, - namespaces: Optional[dict[str, str]] = None, - schemas: Optional[list[str]] = None, + namespaces: Optional[Dict[str, str]] = None, + schemas: Optional[List[str]] = None, fileuri: Optional[str] = None, copyfrom: Optional["LoadingOptions"] = None, original_doc: Optional[Any] = None, - addl_metadata: Optional[dict[str, str]] = None, + addl_metadata: Optional[Dict[str, str]] = None, baseuri: Optional[str] = None, idx: Optional[IdxType] = None, - imports: Optional[list[str]] = None, - includes: Optional[list[str]] = None, + imports: Optional[List[str]] = None, + includes: Optional[List[str]] = None, no_link_check: Optional[bool] = None, container: Optional[str] = None, ) -> None: @@ -205,16 +216,16 @@ def fromDoc( @abstractmethod def save( self, top: bool = False, base_url: str = "", relative_uris: bool = True - ) -> dict[str, Any]: + ) -> Dict[str, Any]: """Convert this object to a JSON/YAML friendly dictionary.""" def load_field( - val: Union[str, dict[str, str]], + val: Union[str, Dict[str, str]], fieldtype: "_Loader", baseuri: str, loadingOptions: LoadingOptions, - lc: Optional[list[Any]] = None, + lc: Optional[List[Any]] = None, ) -> Any: """Load field.""" if isinstance(val, MutableMapping): @@ -241,7 +252,7 @@ def load_field( save_type = Optional[Union[MutableMapping[str, Any], MutableSequence[Any], int, float, bool, str]] -def extract_type(val_type: type[Any]) -> str: +def extract_type(val_type: Type[Any]) -> str: """Take a type of value, and extracts the value as a string.""" val_str = str(val_type) return val_str.split("'")[1] @@ -260,7 +271,7 @@ def convert_typing(val_type: str) -> str: return val_type -def parse_errors(error_message: str) -> tuple[str, str, str]: +def parse_errors(error_message: str) -> Tuple[str, str, str]: """Parse error messages from several loaders into one error message.""" if not error_message.startswith("Expected"): return error_message, "", "" @@ -420,7 +431,7 @@ def load( baseuri: str, loadingOptions: LoadingOptions, docRoot: Optional[str] = None, - lc: Optional[list[Any]] = None, + lc: Optional[List[Any]] = None, ) -> Any: pass @@ -432,7 +443,7 @@ def load( baseuri: str, loadingOptions: LoadingOptions, docRoot: Optional[str] = None, - lc: Optional[list[Any]] = None, + lc: Optional[List[Any]] = None, ) -> Any: if doc is not None: return doc @@ -440,7 +451,7 @@ def load( class _PrimitiveLoader(_Loader): - def __init__(self, tp: Union[type, tuple[type[str], type[str]]]) -> None: + def __init__(self, tp: Union[type, Tuple[Type[str], Type[str]]]) -> None: self.tp = tp def load( @@ -449,7 +460,7 @@ def load( baseuri: str, loadingOptions: LoadingOptions, docRoot: Optional[str] = None, - lc: Optional[list[Any]] = None, + lc: Optional[List[Any]] = None, ) -> Any: if not isinstance(doc, self.tp): raise ValidationException(f"Expected a {self.tp} but got {doc.__class__.__name__}") @@ -469,16 +480,16 @@ def load( baseuri: str, loadingOptions: LoadingOptions, docRoot: Optional[str] = None, - lc: Optional[list[Any]] = None, + lc: Optional[List[Any]] = None, ) -> Any: if not isinstance(doc, MutableSequence): raise ValidationException( f"Value is a {convert_typing(extract_type(type(doc)))}, " f"but valid type for this field is an array." ) - r: list[Any] = [] - errors: list[SchemaSaladException] = [] - fields: list[str] = [] + r: List[Any] = [] + errors: List[SchemaSaladException] = [] + fields: List[str] = [] for i in range(0, len(doc)): try: lf = load_field( @@ -535,7 +546,7 @@ def load( baseuri: str, loadingOptions: LoadingOptions, docRoot: Optional[str] = None, - lc: Optional[list[Any]] = None, + lc: Optional[List[Any]] = None, ) -> Any: if not isinstance(doc, MutableMapping): raise ValidationException(f"Expected a map, was {type(doc)}") @@ -543,8 +554,8 @@ def load( loadingOptions = LoadingOptions( copyfrom=loadingOptions, container=self.container, no_link_check=self.no_link_check ) - r: dict[str, Any] = {} - errors: list[SchemaSaladException] = [] + r: Dict[str, Any] = {} + errors: List[SchemaSaladException] = [] for k, v in doc.items(): try: lf = load_field(v, self.values, baseuri, loadingOptions, lc) @@ -570,7 +581,7 @@ def load( baseuri: str, loadingOptions: LoadingOptions, docRoot: Optional[str] = None, - lc: Optional[list[Any]] = None, + lc: Optional[List[Any]] = None, ) -> Any: if doc in self.symbols: return doc @@ -590,9 +601,9 @@ def load( baseuri: str, loadingOptions: LoadingOptions, docRoot: Optional[str] = None, - lc: Optional[list[Any]] = None, + lc: Optional[List[Any]] = None, ) -> Any: - r: list[dict[str, Any]] = [] + r: List[Dict[str, Any]] = [] if isinstance(doc, MutableSequence): for d in doc: if isinstance(d, str): @@ -601,7 +612,7 @@ def load( else: r.append({"pattern": d}) elif isinstance(d, dict): - new_dict: dict[str, Any] = {} + new_dict: Dict[str, Any] = {} dict_copy = copy.deepcopy(d) if "pattern" in dict_copy: new_dict["pattern"] = dict_copy.pop("pattern") @@ -655,7 +666,7 @@ def load( class _RecordLoader(_Loader): def __init__( self, - classtype: type[Saveable], + classtype: Type[Saveable], container: Optional[str] = None, no_link_check: Optional[bool] = None, ) -> None: @@ -669,7 +680,7 @@ def load( baseuri: str, loadingOptions: LoadingOptions, docRoot: Optional[str] = None, - lc: Optional[list[Any]] = None, + lc: Optional[List[Any]] = None, ) -> Any: if not isinstance(doc, MutableMapping): raise ValidationException( @@ -687,7 +698,7 @@ def __repr__(self) -> str: class _ExpressionLoader(_Loader): - def __init__(self, items: type[str]) -> None: + def __init__(self, items: Type[str]) -> None: self.items = items def load( @@ -696,7 +707,7 @@ def load( baseuri: str, loadingOptions: LoadingOptions, docRoot: Optional[str] = None, - lc: Optional[list[Any]] = None, + lc: Optional[List[Any]] = None, ) -> Any: if not isinstance(doc, str): raise ValidationException( @@ -720,7 +731,7 @@ def load( baseuri: str, loadingOptions: LoadingOptions, docRoot: Optional[str] = None, - lc: Optional[list[Any]] = None, + lc: Optional[List[Any]] = None, ) -> Any: errors = [] @@ -817,7 +828,7 @@ def load( baseuri: str, loadingOptions: LoadingOptions, docRoot: Optional[str] = None, - lc: Optional[list[Any]] = None, + lc: Optional[List[Any]] = None, ) -> Any: if self.no_link_check is not None: loadingOptions = LoadingOptions( @@ -875,7 +886,7 @@ def resolve( doc: str, baseuri: str, loadingOptions: LoadingOptions, - ) -> Union[list[Union[dict[str, Any], str]], dict[str, Any], str]: + ) -> Union[List[Union[Dict[str, Any], str]], Dict[str, Any], str]: doc_ = doc optional = False if doc_.endswith("?"): @@ -884,7 +895,7 @@ def resolve( if doc_.endswith("[]"): salad_versions = [int(v) for v in self.salad_version[1:].split(".")] - items: Union[list[Union[dict[str, Any], str]], dict[str, Any], str] = "" + items: Union[List[Union[Dict[str, Any], str]], Dict[str, Any], str] = "" rest = doc_[0:-2] if salad_versions < [1, 3]: if rest.endswith("[]"): @@ -896,7 +907,7 @@ def resolve( items = self.resolve(rest, baseuri, loadingOptions) if isinstance(items, str): items = expand_url(items, baseuri, loadingOptions, False, True, self.refScope) - expanded: Union[dict[str, Any], str] = {"type": "array", "items": items} + expanded: Union[Dict[str, Any], str] = {"type": "array", "items": items} else: expanded = expand_url(doc_, baseuri, loadingOptions, False, True, self.refScope) @@ -911,10 +922,10 @@ def load( baseuri: str, loadingOptions: LoadingOptions, docRoot: Optional[str] = None, - lc: Optional[list[Any]] = None, + lc: Optional[List[Any]] = None, ) -> Any: if isinstance(doc, MutableSequence): - r: list[Any] = [] + r: List[Any] = [] for d in doc: if isinstance(d, str): resolved = self.resolve(d, baseuri, loadingOptions) @@ -946,10 +957,10 @@ def load( baseuri: str, loadingOptions: LoadingOptions, docRoot: Optional[str] = None, - lc: Optional[list[Any]] = None, + lc: Optional[List[Any]] = None, ) -> Any: if isinstance(doc, MutableMapping): - r: list[Any] = [] + r: List[Any] = [] for k in sorted(doc.keys()): val = doc[k] if isinstance(val, CommentedMap): @@ -979,7 +990,7 @@ def _document_load( baseuri: str, loadingOptions: LoadingOptions, addl_metadata_fields: Optional[MutableSequence[str]] = None, -) -> tuple[Any, LoadingOptions]: +) -> Tuple[Any, LoadingOptions]: if isinstance(doc, str): return _document_load_by_url( loader, @@ -1048,7 +1059,7 @@ def _document_load_by_url( url: str, loadingOptions: LoadingOptions, addl_metadata_fields: Optional[MutableSequence[str]] = None, -) -> tuple[Any, LoadingOptions]: +) -> Tuple[Any, LoadingOptions]: if url in loadingOptions.idx: return loadingOptions.idx[url] @@ -1090,7 +1101,7 @@ def file_uri(path: str, split_frag: bool = False) -> str: return f"file://{urlpath}{frag}" -def prefix_url(url: str, namespaces: dict[str, str]) -> str: +def prefix_url(url: str, namespaces: Dict[str, str]) -> str: """Expand short forms into full URLs using the given namespace dictionary.""" for k, v in namespaces.items(): if url.startswith(v): @@ -1167,7 +1178,7 @@ def __init__( name: Any, type_: Any, doc: Optional[Any] = None, - extension_fields: Optional[dict[str, Any]] = None, + extension_fields: Optional[Dict[str, Any]] = None, loadingOptions: Optional[LoadingOptions] = None, ) -> None: if extension_fields: @@ -1341,7 +1352,7 @@ def fromDoc( [e], ) ) - extension_fields: dict[str, Any] = {} + extension_fields: Dict[str, Any] = {} for k in _doc.keys(): if k not in cls.attrs: if not k: @@ -1377,8 +1388,8 @@ def fromDoc( def save( self, top: bool = False, base_url: str = "", relative_uris: bool = True - ) -> dict[str, Any]: - r: dict[str, Any] = {} + ) -> Dict[str, Any]: + r: Dict[str, Any] = {} if relative_uris: for ef in self.extension_fields: @@ -1414,7 +1425,7 @@ def __init__( self, type_: Any, fields: Optional[Any] = None, - extension_fields: Optional[dict[str, Any]] = None, + extension_fields: Optional[Dict[str, Any]] = None, loadingOptions: Optional[LoadingOptions] = None, ) -> None: if extension_fields: @@ -1533,7 +1544,7 @@ def fromDoc( [e], ) ) - extension_fields: dict[str, Any] = {} + extension_fields: Dict[str, Any] = {} for k in _doc.keys(): if k not in cls.attrs: if not k: @@ -1567,8 +1578,8 @@ def fromDoc( def save( self, top: bool = False, base_url: str = "", relative_uris: bool = True - ) -> dict[str, Any]: - r: dict[str, Any] = {} + ) -> Dict[str, Any]: + r: Dict[str, Any] = {} if relative_uris: for ef in self.extension_fields: @@ -1606,7 +1617,7 @@ def __init__( self, symbols: Any, type_: Any, - extension_fields: Optional[dict[str, Any]] = None, + extension_fields: Optional[Dict[str, Any]] = None, loadingOptions: Optional[LoadingOptions] = None, ) -> None: if extension_fields: @@ -1726,7 +1737,7 @@ def fromDoc( [e], ) ) - extension_fields: dict[str, Any] = {} + extension_fields: Dict[str, Any] = {} for k in _doc.keys(): if k not in cls.attrs: if not k: @@ -1760,8 +1771,8 @@ def fromDoc( def save( self, top: bool = False, base_url: str = "", relative_uris: bool = True - ) -> dict[str, Any]: - r: dict[str, Any] = {} + ) -> Dict[str, Any]: + r: Dict[str, Any] = {} if relative_uris: for ef in self.extension_fields: @@ -1793,7 +1804,7 @@ def __init__( self, items: Any, type_: Any, - extension_fields: Optional[dict[str, Any]] = None, + extension_fields: Optional[Dict[str, Any]] = None, loadingOptions: Optional[LoadingOptions] = None, ) -> None: if extension_fields: @@ -1913,7 +1924,7 @@ def fromDoc( [e], ) ) - extension_fields: dict[str, Any] = {} + extension_fields: Dict[str, Any] = {} for k in _doc.keys(): if k not in cls.attrs: if not k: @@ -1947,8 +1958,8 @@ def fromDoc( def save( self, top: bool = False, base_url: str = "", relative_uris: bool = True - ) -> dict[str, Any]: - r: dict[str, Any] = {} + ) -> Dict[str, Any]: + r: Dict[str, Any] = {} if relative_uris: for ef in self.extension_fields: @@ -2033,7 +2044,7 @@ def __init__( self, top: Any, left: Any, - extension_fields: Optional[dict[str, Any]] = None, + extension_fields: Optional[Dict[str, Any]] = None, loadingOptions: Optional[LoadingOptions] = None, ) -> None: if extension_fields: @@ -2153,7 +2164,7 @@ def fromDoc( [e], ) ) - extension_fields: dict[str, Any] = {} + extension_fields: Dict[str, Any] = {} for k in _doc.keys(): if k not in cls.attrs: if not k: @@ -2187,8 +2198,8 @@ def fromDoc( def save( self, top: bool = False, base_url: str = "", relative_uris: bool = True - ) -> dict[str, Any]: - r: dict[str, Any] = {} + ) -> Dict[str, Any]: + r: Dict[str, Any] = {} if relative_uris: for ef in self.extension_fields: @@ -2227,7 +2238,7 @@ def __init__( name: Any, owner: Any, tool_shed: Any, - extension_fields: Optional[dict[str, Any]] = None, + extension_fields: Optional[Dict[str, Any]] = None, loadingOptions: Optional[LoadingOptions] = None, ) -> None: if extension_fields: @@ -2446,7 +2457,7 @@ def fromDoc( [e], ) ) - extension_fields: dict[str, Any] = {} + extension_fields: Dict[str, Any] = {} for k in _doc.keys(): if k not in cls.attrs: if not k: @@ -2483,8 +2494,8 @@ def fromDoc( def save( self, top: bool = False, base_url: str = "", relative_uris: bool = True - ) -> dict[str, Any]: - r: dict[str, Any] = {} + ) -> Dict[str, Any]: + r: Dict[str, Any] = {} if relative_uris: for ef in self.extension_fields: @@ -2537,7 +2548,7 @@ def __init__( position: Optional[Any] = None, format: Optional[Any] = None, collection_type: Optional[Any] = None, - extension_fields: Optional[dict[str, Any]] = None, + extension_fields: Optional[Dict[str, Any]] = None, loadingOptions: Optional[LoadingOptions] = None, ) -> None: if extension_fields: @@ -2980,7 +2991,7 @@ def fromDoc( [e], ) ) - extension_fields: dict[str, Any] = {} + extension_fields: Dict[str, Any] = {} for k in _doc.keys(): if k not in cls.attrs: if not k: @@ -3022,8 +3033,8 @@ def fromDoc( def save( self, top: bool = False, base_url: str = "", relative_uris: bool = True - ) -> dict[str, Any]: - r: dict[str, Any] = {} + ) -> Dict[str, Any]: + r: Dict[str, Any] = {} if relative_uris: for ef in self.extension_fields: @@ -3109,7 +3120,7 @@ def __init__( id: Optional[Any] = None, outputSource: Optional[Any] = None, type_: Optional[Any] = None, - extension_fields: Optional[dict[str, Any]] = None, + extension_fields: Optional[Dict[str, Any]] = None, loadingOptions: Optional[LoadingOptions] = None, ) -> None: if extension_fields: @@ -3368,7 +3379,7 @@ def fromDoc( [e], ) ) - extension_fields: dict[str, Any] = {} + extension_fields: Dict[str, Any] = {} for k in _doc.keys(): if k not in cls.attrs: if not k: @@ -3406,8 +3417,8 @@ def fromDoc( def save( self, top: bool = False, base_url: str = "", relative_uris: bool = True - ) -> dict[str, Any]: - r: dict[str, Any] = {} + ) -> Dict[str, Any]: + r: Dict[str, Any] = {} if relative_uris: for ef in self.extension_fields: @@ -3496,7 +3507,7 @@ def __init__( run: Optional[Any] = None, runtime_inputs: Optional[Any] = None, when: Optional[Any] = None, - extension_fields: Optional[dict[str, Any]] = None, + extension_fields: Optional[Dict[str, Any]] = None, loadingOptions: Optional[LoadingOptions] = None, ) -> None: if extension_fields: @@ -4293,7 +4304,7 @@ def fromDoc( [e], ) ) - extension_fields: dict[str, Any] = {} + extension_fields: Dict[str, Any] = {} for k in _doc.keys(): if k not in cls.attrs: if not k: @@ -4343,8 +4354,8 @@ def fromDoc( def save( self, top: bool = False, base_url: str = "", relative_uris: bool = True - ) -> dict[str, Any]: - r: dict[str, Any] = {} + ) -> Dict[str, Any]: + r: Dict[str, Any] = {} if relative_uris: for ef in self.extension_fields: @@ -4478,7 +4489,7 @@ def __init__( source: Optional[Any] = None, label: Optional[Any] = None, default: Optional[Any] = None, - extension_fields: Optional[dict[str, Any]] = None, + extension_fields: Optional[Dict[str, Any]] = None, loadingOptions: Optional[LoadingOptions] = None, ) -> None: if extension_fields: @@ -4694,7 +4705,7 @@ def fromDoc( [e], ) ) - extension_fields: dict[str, Any] = {} + extension_fields: Dict[str, Any] = {} for k in _doc.keys(): if k not in cls.attrs: if not k: @@ -4731,8 +4742,8 @@ def fromDoc( def save( self, top: bool = False, base_url: str = "", relative_uris: bool = True - ) -> dict[str, Any]: - r: dict[str, Any] = {} + ) -> Dict[str, Any]: + r: Dict[str, Any] = {} if relative_uris: for ef in self.extension_fields: @@ -4776,7 +4787,7 @@ class Report(Saveable): def __init__( self, markdown: Any, - extension_fields: Optional[dict[str, Any]] = None, + extension_fields: Optional[Dict[str, Any]] = None, loadingOptions: Optional[LoadingOptions] = None, ) -> None: if extension_fields: @@ -4853,7 +4864,7 @@ def fromDoc( [e], ) ) - extension_fields: dict[str, Any] = {} + extension_fields: Dict[str, Any] = {} for k in _doc.keys(): if k not in cls.attrs: if not k: @@ -4884,8 +4895,8 @@ def fromDoc( def save( self, top: bool = False, base_url: str = "", relative_uris: bool = True - ) -> dict[str, Any]: - r: dict[str, Any] = {} + ) -> Dict[str, Any]: + r: Dict[str, Any] = {} if relative_uris: for ef in self.extension_fields: @@ -4932,7 +4943,7 @@ def __init__( remove_tags: Optional[Any] = None, rename: Optional[Any] = None, set_columns: Optional[Any] = None, - extension_fields: Optional[dict[str, Any]] = None, + extension_fields: Optional[Dict[str, Any]] = None, loadingOptions: Optional[LoadingOptions] = None, ) -> None: if extension_fields: @@ -5332,7 +5343,7 @@ def fromDoc( [e], ) ) - extension_fields: dict[str, Any] = {} + extension_fields: Dict[str, Any] = {} for k in _doc.keys(): if k not in cls.attrs: if not k: @@ -5373,8 +5384,8 @@ def fromDoc( def save( self, top: bool = False, base_url: str = "", relative_uris: bool = True - ) -> dict[str, Any]: - r: dict[str, Any] = {} + ) -> Dict[str, Any]: + r: Dict[str, Any] = {} if relative_uris: for ef in self.extension_fields: @@ -5479,7 +5490,7 @@ def __init__( creator: Optional[Any] = None, license: Optional[Any] = None, release: Optional[Any] = None, - extension_fields: Optional[dict[str, Any]] = None, + extension_fields: Optional[Dict[str, Any]] = None, loadingOptions: Optional[LoadingOptions] = None, ) -> None: if extension_fields: @@ -6066,7 +6077,7 @@ def fromDoc( [e], ) ) - extension_fields: dict[str, Any] = {} + extension_fields: Dict[str, Any] = {} for k in _doc.keys(): if k not in cls.attrs: if not k: @@ -6111,8 +6122,8 @@ def fromDoc( def save( self, top: bool = False, base_url: str = "", relative_uris: bool = True - ) -> dict[str, Any]: - r: dict[str, Any] = {} + ) -> Dict[str, Any]: + r: Dict[str, Any] = {} if relative_uris: for ef in self.extension_fields: diff --git a/requirements.txt b/requirements.txt index 83e19a7..75f612f 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,4 +1,4 @@ bioblend pyyaml -schema-salad >= 8.2 +schema-salad <= 8.7.20241010092723 typing_extensions