[arvados] updated: 2.6.0-573-gdfc7bfa9a4
git repository hosting
git at public.arvados.org
Wed Oct 11 21:12:44 UTC 2023
Summary of changes:
sdk/cwl/arvados_cwl/runner.py | 3 ++-
sdk/cwl/setup.py | 3 +++
sdk/python/arvados/commands/arv_copy.py | 12 +++++++++---
sdk/python/arvados/util.py | 12 ++++++------
4 files changed, 20 insertions(+), 10 deletions(-)
via dfc7bfa9a4fca1f6b5aef5ba0645672de2f9a34e (commit)
via 218eef732bd8ec45cf51a22a73e9a7e07609ba27 (commit)
from 96a389052be846aed84b7c9aead713ce8a54075e (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
commit dfc7bfa9a4fca1f6b5aef5ba0645672de2f9a34e
Author: Peter Amstutz <peter.amstutz at curii.com>
Date: Wed Oct 11 16:57:59 2023 -0400
20933: Code cleanups
Arvados-DCO-1.1-Signed-off-by: Peter Amstutz <peter.amstutz at curii.com>
diff --git a/sdk/cwl/arvados_cwl/runner.py b/sdk/cwl/arvados_cwl/runner.py
index 554f137449..f6aab4b93f 100644
--- a/sdk/cwl/arvados_cwl/runner.py
+++ b/sdk/cwl/arvados_cwl/runner.py
@@ -983,4 +983,5 @@ def print_keep_deps(arvRunner, runtimeContext, merged_map, tool):
if g:
references.add(g[1])
- arvRunner.stdout.write(json.dumps(sorted(list(references)))+"\n")
+ json.dump(sorted(references), arvRunner.stdout)
+ print(file=arvRunner.stdout)
diff --git a/sdk/cwl/setup.py b/sdk/cwl/setup.py
index 1be2c119c2..f8aace0683 100644
--- a/sdk/cwl/setup.py
+++ b/sdk/cwl/setup.py
@@ -44,6 +44,9 @@ setup(name='arvados-cwl-runner',
'msgpack==1.0.3',
'importlib-metadata<5',
'setuptools>=40.3.0',
+
+ # zipp 3.16 dropped support for Python 3.7, so this can be
+ # removed this when we drop support for 3.7 as well.
'zipp<3.16.0'
],
data_files=[
diff --git a/sdk/python/arvados/commands/arv_copy.py b/sdk/python/arvados/commands/arv_copy.py
index 6431f83d96..a9266a33c1 100755
--- a/sdk/python/arvados/commands/arv_copy.py
+++ b/sdk/python/arvados/commands/arv_copy.py
@@ -319,9 +319,15 @@ def copy_workflow(wf_uuid, src, dst, args):
try:
result = subprocess.run(["arvados-cwl-runner", "--quiet", "--print-keep-deps", "arvwf:"+wf_uuid],
capture_output=True, env=env)
- except (FileNotFoundError, subprocess.CalledProcessError):
- logger.error('Copying workflows requires arvados-cwl-runner 2.7.1 or later to be installed in PATH.')
- return
+ except FileNotFoundError:
+ no_arv_copy = True
+ else:
+ no_arv_copy = result.returncode == 2
+
+ if no_arv_copy:
+ raise Exception('Copying workflows requires arvados-cwl-runner 2.7.1 or later to be installed in PATH.')
+ elif result.returncode != 0:
+ raise Exception('There was an error getting Keep dependencies from workflow using arvados-cwl-runner --print-keep-deps')
locations = json.loads(result.stdout)
commit 218eef732bd8ec45cf51a22a73e9a7e07609ba27
Author: Peter Amstutz <peter.amstutz at curii.com>
Date: Wed Oct 11 16:32:50 2023 -0400
20933: Use [0-9] instead of \d in regex
Arvados-DCO-1.1-Signed-off-by: Peter Amstutz <peter.amstutz at curii.com>
diff --git a/sdk/python/arvados/util.py b/sdk/python/arvados/util.py
index c1ba790241..85f4b55b85 100644
--- a/sdk/python/arvados/util.py
+++ b/sdk/python/arvados/util.py
@@ -24,9 +24,9 @@ CR_UNCOMMITTED = 'Uncommitted'
CR_COMMITTED = 'Committed'
CR_FINAL = 'Final'
-keep_locator_pattern = re.compile(r'[0-9a-f]{32}\+\d+(\+\S+)*')
-signed_locator_pattern = re.compile(r'[0-9a-f]{32}\+\d+(\+\S+)*\+A\S+(\+\S+)*')
-portable_data_hash_pattern = re.compile(r'[0-9a-f]{32}\+\d+')
+keep_locator_pattern = re.compile(r'[0-9a-f]{32}\+[0-9]+(\+\S+)*')
+signed_locator_pattern = re.compile(r'[0-9a-f]{32}\+[0-9]+(\+\S+)*\+A\S+(\+\S+)*')
+portable_data_hash_pattern = re.compile(r'[0-9a-f]{32}\+[0-9]+')
uuid_pattern = re.compile(r'[a-z0-9]{5}-[a-z0-9]{5}-[a-z0-9]{15}')
collection_uuid_pattern = re.compile(r'[a-z0-9]{5}-4zz18-[a-z0-9]{15}')
group_uuid_pattern = re.compile(r'[a-z0-9]{5}-j7d0g-[a-z0-9]{15}')
@@ -34,9 +34,9 @@ user_uuid_pattern = re.compile(r'[a-z0-9]{5}-tpzed-[a-z0-9]{15}')
link_uuid_pattern = re.compile(r'[a-z0-9]{5}-o0j2j-[a-z0-9]{15}')
job_uuid_pattern = re.compile(r'[a-z0-9]{5}-8i9sb-[a-z0-9]{15}')
container_uuid_pattern = re.compile(r'[a-z0-9]{5}-dz642-[a-z0-9]{15}')
-manifest_pattern = re.compile(r'((\S+)( +[a-f0-9]{32}(\+\d+)(\+\S+)*)+( +\d+:\d+:\S+)+$)+', flags=re.MULTILINE)
-keep_file_locator_pattern = re.compile(r'([0-9a-f]{32}\+\d+)/(.*)')
-keepuri_pattern = re.compile(r'keep:([0-9a-f]{32}\+\d+)/(.*)')
+manifest_pattern = re.compile(r'((\S+)( +[a-f0-9]{32}(\+[0-9]+)(\+\S+)*)+( +[0-9]+:[0-9]+:\S+)+$)+', flags=re.MULTILINE)
+keep_file_locator_pattern = re.compile(r'([0-9a-f]{32}\+[0-9]+)/(.*)')
+keepuri_pattern = re.compile(r'keep:([0-9a-f]{32}\+[0-9]+)/(.*)')
def _deprecated(version=None, preferred=None):
"""Mark a callable as deprecated in the SDK
-----------------------------------------------------------------------
hooks/post-receive
--
More information about the arvados-commits
mailing list