pycompss-cli 3.3.3__tar.gz → 3.3.5__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (62) hide show
  1. {pycompss-cli-3.3.3/pycompss_cli.egg-info → pycompss-cli-3.3.5}/PKG-INFO +1 -1
  2. pycompss-cli-3.3.5/VERSION.txt +1 -0
  3. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5}/pycompss_cli/__init__.py +2 -2
  4. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5}/pycompss_cli/assets/__init__.py +2 -2
  5. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5}/pycompss_cli/cli/__init__.py +2 -2
  6. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5}/pycompss_cli/cli/compss.py +2 -2
  7. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5}/pycompss_cli/cli/dislib.py +2 -2
  8. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5}/pycompss_cli/cli/pycompss.py +2 -2
  9. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5}/pycompss_cli/core/__init__.py +2 -2
  10. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5}/pycompss_cli/core/actions.py +6 -2
  11. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5}/pycompss_cli/core/actions_dispatcher.py +3 -7
  12. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5}/pycompss_cli/core/arguments.py +15 -2
  13. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5}/pycompss_cli/core/cmd_helpers.py +2 -2
  14. pycompss-cli-3.3.5/pycompss_cli/core/docker/__init__.py +16 -0
  15. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5}/pycompss_cli/core/docker/actions.py +7 -4
  16. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5}/pycompss_cli/core/docker/arguments.py +2 -2
  17. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5}/pycompss_cli/core/docker/cmd.py +3 -3
  18. pycompss-cli-3.3.5/pycompss_cli/core/local/__init__.py +16 -0
  19. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5}/pycompss_cli/core/local/actions.py +10 -3
  20. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5}/pycompss_cli/core/local/arguments.py +2 -2
  21. pycompss-cli-3.3.5/pycompss_cli/core/local/cmd.py +368 -0
  22. pycompss-cli-3.3.5/pycompss_cli/core/remote/__init__.py +16 -0
  23. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5}/pycompss_cli/core/remote/actions.py +6 -3
  24. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5}/pycompss_cli/core/remote/arguments.py +3 -4
  25. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5}/pycompss_cli/core/remote/cmd.py +3 -3
  26. pycompss-cli-3.3.5/pycompss_cli/core/remote/interactive_sc/__init__.py +16 -0
  27. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5}/pycompss_cli/core/remote/interactive_sc/core.py +3 -3
  28. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5}/pycompss_cli/core/remote/interactive_sc/defaults.py +2 -2
  29. pycompss-cli-3.3.5/pycompss_cli/core/remote/job_scripts/__init__.py +16 -0
  30. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5}/pycompss_cli/core/remote/job_scripts/cancel.py +2 -2
  31. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5}/pycompss_cli/core/remote/job_scripts/commons.py +2 -2
  32. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5}/pycompss_cli/core/remote/job_scripts/find.py +2 -2
  33. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5}/pycompss_cli/core/remote/job_scripts/info.py +2 -2
  34. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5}/pycompss_cli/core/remote/job_scripts/status.py +2 -2
  35. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5}/pycompss_cli/core/unicore/__init__.py +2 -2
  36. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5}/pycompss_cli/core/unicore/actions.py +2 -2
  37. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5}/pycompss_cli/core/unicore/arguments.py +2 -2
  38. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5}/pycompss_cli/core/utils.py +2 -2
  39. pycompss-cli-3.3.5/pycompss_cli/models/__init__.py +16 -0
  40. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5}/pycompss_cli/models/app.py +2 -2
  41. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5/pycompss_cli.egg-info}/PKG-INFO +1 -1
  42. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5}/pycompss_cli.egg-info/requires.txt +1 -0
  43. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5}/setup.py +1 -1
  44. pycompss-cli-3.3.3/VERSION.txt +0 -1
  45. pycompss-cli-3.3.3/pycompss_cli/core/docker/__init__.py +0 -16
  46. pycompss-cli-3.3.3/pycompss_cli/core/local/__init__.py +0 -16
  47. pycompss-cli-3.3.3/pycompss_cli/core/local/cmd.py +0 -136
  48. pycompss-cli-3.3.3/pycompss_cli/core/remote/__init__.py +0 -16
  49. pycompss-cli-3.3.3/pycompss_cli/core/remote/interactive_sc/__init__.py +0 -16
  50. pycompss-cli-3.3.3/pycompss_cli/core/remote/job_scripts/__init__.py +0 -16
  51. pycompss-cli-3.3.3/pycompss_cli/models/__init__.py +0 -16
  52. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5}/LICENSE.txt +0 -0
  53. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5}/MANIFEST.in +0 -0
  54. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5}/README.rst +0 -0
  55. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5}/pycompss_cli/assets/enqueue_compss_args.txt +0 -0
  56. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5}/pycompss_cli/assets/runcompss_args.txt +0 -0
  57. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5}/pycompss_cli.egg-info/SOURCES.txt +0 -0
  58. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5}/pycompss_cli.egg-info/dependency_links.txt +0 -0
  59. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5}/pycompss_cli.egg-info/entry_points.txt +0 -0
  60. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5}/pycompss_cli.egg-info/top_level.txt +0 -0
  61. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5}/requirements.txt +0 -0
  62. {pycompss-cli-3.3.3 → pycompss-cli-3.3.5}/setup.cfg +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: pycompss-cli
3
- Version: 3.3.3
3
+ Version: 3.3.5
4
4
  Summary: PyCOMPSs cli
5
5
  Home-page: https://compss.bsc.es
6
6
  Author: Workflows and Distributed Computing Group (WDC) - Barcelona Supercomputing Center (BSC)
@@ -0,0 +1 @@
1
+ 3.3.5
@@ -1,6 +1,6 @@
1
- #!/usr/bin/python
1
+ #!/usr/bin/env python3
2
2
  #
3
- # Copyright 2002-2023 Barcelona Supercomputing Center (www.bsc.es)
3
+ # Copyright 2002-2024 Barcelona Supercomputing Center (www.bsc.es)
4
4
  #
5
5
  # Licensed under the Apache License, Version 2.0 (the "License");
6
6
  # you may not use this file except in compliance with the License.
@@ -1,6 +1,6 @@
1
- #!/usr/bin/python
1
+ #!/usr/bin/env python3
2
2
  #
3
- # Copyright 2002-2023 Barcelona Supercomputing Center (www.bsc.es)
3
+ # Copyright 2002-2024 Barcelona Supercomputing Center (www.bsc.es)
4
4
  #
5
5
  # Licensed under the Apache License, Version 2.0 (the "License");
6
6
  # you may not use this file except in compliance with the License.
@@ -1,6 +1,6 @@
1
- #!/usr/bin/python
1
+ #!/usr/bin/env python3
2
2
  #
3
- # Copyright 2002-2023 Barcelona Supercomputing Center (www.bsc.es)
3
+ # Copyright 2002-2024 Barcelona Supercomputing Center (www.bsc.es)
4
4
  #
5
5
  # Licensed under the Apache License, Version 2.0 (the "License");
6
6
  # you may not use this file except in compliance with the License.
@@ -1,6 +1,6 @@
1
- #!/usr/bin/python
1
+ #!/usr/bin/env python3
2
2
  #
3
- # Copyright 2002-2023 Barcelona Supercomputing Center (www.bsc.es)
3
+ # Copyright 2002-2024 Barcelona Supercomputing Center (www.bsc.es)
4
4
  #
5
5
  # Licensed under the Apache License, Version 2.0 (the "License");
6
6
  # you may not use this file except in compliance with the License.
@@ -1,6 +1,6 @@
1
- #!/usr/bin/python
1
+ #!/usr/bin/env python3
2
2
  #
3
- # Copyright 2002-2023 Barcelona Supercomputing Center (www.bsc.es)
3
+ # Copyright 2002-2024 Barcelona Supercomputing Center (www.bsc.es)
4
4
  #
5
5
  # Licensed under the Apache License, Version 2.0 (the "License");
6
6
  # you may not use this file except in compliance with the License.
@@ -1,6 +1,6 @@
1
- #!/usr/bin/python
1
+ #!/usr/bin/env python3
2
2
  #
3
- # Copyright 2002-2023 Barcelona Supercomputing Center (www.bsc.es)
3
+ # Copyright 2002-2024 Barcelona Supercomputing Center (www.bsc.es)
4
4
  #
5
5
  # Licensed under the Apache License, Version 2.0 (the "License");
6
6
  # you may not use this file except in compliance with the License.
@@ -1,6 +1,6 @@
1
- #!/usr/bin/python
1
+ #!/usr/bin/env python3
2
2
  #
3
- # Copyright 2002-2023 Barcelona Supercomputing Center (www.bsc.es)
3
+ # Copyright 2002-2024 Barcelona Supercomputing Center (www.bsc.es)
4
4
  #
5
5
  # Licensed under the Apache License, Version 2.0 (the "License");
6
6
  # you may not use this file except in compliance with the License.
@@ -1,6 +1,6 @@
1
- #!/usr/bin/python
1
+ #!/usr/bin/env python3
2
2
  #
3
- # Copyright 2002-2023 Barcelona Supercomputing Center (www.bsc.es)
3
+ # Copyright 2002-2024 Barcelona Supercomputing Center (www.bsc.es)
4
4
  #
5
5
  # Licensed under the Apache License, Version 2.0 (the "License");
6
6
  # you may not use this file except in compliance with the License.
@@ -167,3 +167,7 @@ class Actions(ABC):
167
167
 
168
168
  print(f'Deleting environment `{env_id}`...')
169
169
  shutil.rmtree(env_dir_name)
170
+
171
+ @abstractmethod
172
+ def inspect(self):
173
+ pass
@@ -1,6 +1,6 @@
1
- #!/usr/bin/python
1
+ #!/usr/bin/env python3
2
2
  #
3
- # Copyright 2002-2023 Barcelona Supercomputing Center (www.bsc.es)
3
+ # Copyright 2002-2024 Barcelona Supercomputing Center (www.bsc.es)
4
4
  #
5
5
  # Licensed under the Apache License, Version 2.0 (the "License");
6
6
  # you may not use this file except in compliance with the License.
@@ -40,11 +40,6 @@ class ActionsDispatcher(object):
40
40
  if arguments.action == 'environment':
41
41
  if arguments.environment and arguments.environment.startswith('r'):
42
42
  self.__delete_envs(arguments.env_id, arguments)
43
- exit(0)
44
-
45
- if arguments.env_id and arguments.env_id not in list(os.walk(envs_path))[0][1]:
46
- print("ERROR: There's no environment named " + arguments.env_id)
47
- exit(1)
48
43
 
49
44
  env_id = arguments.env_id if arguments.env_id else None
50
45
 
@@ -71,6 +66,7 @@ class ActionsDispatcher(object):
71
66
  env_arguments.env_id = env_id
72
67
  action_cmd = self.__getactions_cmd(env_type, env_arguments, env_conf=env_conf)
73
68
  action_cmd.env_remove()
69
+ exit(0)
74
70
 
75
71
  def __get_env_type_from_name(self, env_name):
76
72
  envs_path = self.home_path + '/.COMPSs/envs'
@@ -1,6 +1,6 @@
1
- #!/usr/bin/python
1
+ #!/usr/bin/env python3
2
2
  #
3
- # Copyright 2002-2023 Barcelona Supercomputing Center (www.bsc.es)
3
+ # Copyright 2002-2024 Barcelona Supercomputing Center (www.bsc.es)
4
4
  #
5
5
  # Licensed under the Apache License, Version 2.0 (the "License");
6
6
  # you may not use this file except in compliance with the License.
@@ -284,6 +284,19 @@ def parse_sys_argv():
284
284
  type=str,
285
285
  help="ID of the environment to remove") # noqa: E501
286
286
 
287
+ # INSPECT
288
+ parser_environment = subparsers.add_parser("inspect",
289
+ aliases=["ins"],
290
+ help="Inspect an RO-Crate from a COMPSs application run.", # noqa: E501
291
+ parents=[parent_parser],
292
+ formatter_class=FORMATTER_CLASS)
293
+
294
+ parser_environment.set_defaults(action='inspect')
295
+
296
+ parser_environment.add_argument("ro_crate",
297
+ type=str,
298
+ help="Folder or zip file containing the RO-Crate")
299
+
287
300
  # Check if the user does not include any argument
288
301
  if len(sys.argv) < 2:
289
302
  print(parser.print_help())
@@ -1,6 +1,6 @@
1
- #!/usr/bin/python
1
+ #!/usr/bin/env python3
2
2
  #
3
- # Copyright 2002-2023 Barcelona Supercomputing Center (www.bsc.es)
3
+ # Copyright 2002-2024 Barcelona Supercomputing Center (www.bsc.es)
4
4
  #
5
5
  # Licensed under the Apache License, Version 2.0 (the "License");
6
6
  # you may not use this file except in compliance with the License.
@@ -0,0 +1,16 @@
1
+ #!/usr/bin/env python3
2
+ #
3
+ # Copyright 2002-2024 Barcelona Supercomputing Center (www.bsc.es)
4
+ #
5
+ # Licensed under the Apache License, Version 2.0 (the "License");
6
+ # you may not use this file except in compliance with the License.
7
+ # You may obtain a copy of the License at
8
+ #
9
+ # http://www.apache.org/licenses/LICENSE-2.0
10
+ #
11
+ # Unless required by applicable law or agreed to in writing, software
12
+ # distributed under the License is distributed on an "AS IS" BASIS,
13
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
+ # See the License for the specific language governing permissions and
15
+ # limitations under the License.
16
+ #
@@ -1,6 +1,6 @@
1
- #!/usr/bin/python
1
+ #!/usr/bin/env python3
2
2
  #
3
- # Copyright 2002-2023 Barcelona Supercomputing Center (www.bsc.es)
3
+ # Copyright 2002-2024 Barcelona Supercomputing Center (www.bsc.es)
4
4
  #
5
5
  # Licensed under the Apache License, Version 2.0 (the "License");
6
6
  # you may not use this file except in compliance with the License.
@@ -189,8 +189,8 @@ class DockerActions(Actions):
189
189
 
190
190
 
191
191
  def gentrace(self):
192
- command = f"compss_gentrace " + ' '.join(self.arguments.rest_args)
193
- command += f' {self.arguments.trace_dir}'
192
+ command = f"compss_gentrace {self.arguments.trace_dir} "
193
+ command += ' '.join(self.arguments.rest_args)
194
194
  self.docker_cmd.docker_exec_in_daemon(command)
195
195
  if self.arguments.download_dir:
196
196
  self.docker_cmd.docker_exec_in_daemon(f'cp {self.arguments.trace_dir}/* {self.arguments.download_dir}/')
@@ -239,3 +239,6 @@ class DockerActions(Actions):
239
239
  def job(self):
240
240
  print("ERROR: Wrong Environment! Try using a `remote` environment")
241
241
  exit(1)
242
+
243
+ def inspect(self):
244
+ pass
@@ -1,6 +1,6 @@
1
- #!/usr/bin/python
1
+ #!/usr/bin/env python3
2
2
  #
3
- # Copyright 2002-2023 Barcelona Supercomputing Center (www.bsc.es)
3
+ # Copyright 2002-2024 Barcelona Supercomputing Center (www.bsc.es)
4
4
  #
5
5
  # Licensed under the Apache License, Version 2.0 (the "License");
6
6
  # you may not use this file except in compliance with the License.
@@ -1,6 +1,6 @@
1
- #!/usr/bin/python
1
+ #!/usr/bin/env python3
2
2
  #
3
- # Copyright 2002-2023 Barcelona Supercomputing Center (www.bsc.es)
3
+ # Copyright 2002-2024 Barcelona Supercomputing Center (www.bsc.es)
4
4
  #
5
5
  # Licensed under the Apache License, Version 2.0 (the "License");
6
6
  # you may not use this file except in compliance with the License.
@@ -136,7 +136,7 @@ class DockerCmd(object):
136
136
  "while because it needs to download the docker image. " +
137
137
  "Please be patient.")
138
138
  if update_image:
139
- subprocess.run(['docker', 'pull', docker_image], stdout=subprocess.PIPE)
139
+ subprocess.run(f'docker pull {docker_image}', shell=True)
140
140
  mounts = self._get_mounts(user_working_dir=working_dir, log_dir=log_dir)
141
141
  ports = {"8888/tcp": 8888, # required for jupyter notebooks
142
142
  "8080/tcp": 8080} # required for monitor
@@ -0,0 +1,16 @@
1
+ #!/usr/bin/env python3
2
+ #
3
+ # Copyright 2002-2024 Barcelona Supercomputing Center (www.bsc.es)
4
+ #
5
+ # Licensed under the Apache License, Version 2.0 (the "License");
6
+ # you may not use this file except in compliance with the License.
7
+ # You may obtain a copy of the License at
8
+ #
9
+ # http://www.apache.org/licenses/LICENSE-2.0
10
+ #
11
+ # Unless required by applicable law or agreed to in writing, software
12
+ # distributed under the License is distributed on an "AS IS" BASIS,
13
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
+ # See the License for the specific language governing permissions and
15
+ # limitations under the License.
16
+ #
@@ -1,6 +1,6 @@
1
- #!/usr/bin/python
1
+ #!/usr/bin/env python3
2
2
  #
3
- # Copyright 2002-2023 Barcelona Supercomputing Center (www.bsc.es)
3
+ # Copyright 2002-2024 Barcelona Supercomputing Center (www.bsc.es)
4
4
  #
5
5
  # Licensed under the Apache License, Version 2.0 (the "License");
6
6
  # you may not use this file except in compliance with the License.
@@ -35,12 +35,12 @@ from pycompss_cli.core.local.cmd import local_job_list
35
35
  from pycompss_cli.core.local.cmd import local_cancel_job
36
36
  from pycompss_cli.core.local.cmd import local_job_status
37
37
  from pycompss_cli.core.local.cmd import local_app_deploy
38
+ from pycompss_cli.core.local.cmd import local_inspect
38
39
  from pycompss_cli.core.actions import Actions
39
40
  import pycompss_cli.core.utils as utils
40
41
  import os, sys
41
42
 
42
43
 
43
-
44
44
  class LocalActions(Actions):
45
45
  def __init__(self, arguments, debug=False, env_conf=None) -> None:
46
46
  super().__init__(arguments, debug=debug, env_conf=env_conf)
@@ -329,3 +329,10 @@ class LocalActions(Actions):
329
329
  apps.append(App(app_dir_name))
330
330
  self.apps = apps
331
331
  return apps
332
+
333
+ def inspect(self):
334
+ # Code that inspects the RO-Crate
335
+ local_inspect(self.arguments.ro_crate)
336
+
337
+
338
+
@@ -1,6 +1,6 @@
1
- #!/usr/bin/python
1
+ #!/usr/bin/env python3
2
2
  #
3
- # Copyright 2002-2023 Barcelona Supercomputing Center (www.bsc.es)
3
+ # Copyright 2002-2024 Barcelona Supercomputing Center (www.bsc.es)
4
4
  #
5
5
  # Licensed under the Apache License, Version 2.0 (the "License");
6
6
  # you may not use this file except in compliance with the License.