ERROR:cwlab:name 'sleep' is not defined
Traceback (most recent call last):
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/engine/base.py", line 1276, in _execute_context
self.dialect.do_execute(
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/engine/default.py", line 593, in do_execute
cursor.execute(statement, parameters)
sqlite3.IntegrityError: UNIQUE constraint failed: job.job_name
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/usr/local/lib/python3.8/dist-packages/cwlab/database/sqlalchemy/job_manager.py", line 88, in update
db.session.commit()
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/orm/scoping.py", line 163, in do
return getattr(self.registry(), name)(*args, **kwargs)
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/orm/session.py", line 1042, in commit
self.transaction.commit()
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/orm/session.py", line 504, in commit
self._prepare_impl()
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/orm/session.py", line 483, in _prepare_impl
self.session.flush()
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/orm/session.py", line 2536, in flush
self._flush(objects)
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/orm/session.py", line 2678, in _flush
transaction.rollback(_capture_exception=True)
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/util/langhelpers.py", line 68, in __exit__
compat.raise_(
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/util/compat.py", line 182, in raise_
raise exception
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/orm/session.py", line 2638, in _flush
flush_context.execute()
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/orm/unitofwork.py", line 422, in execute
rec.execute(self)
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/orm/unitofwork.py", line 586, in execute
persistence.save_obj(
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/orm/persistence.py", line 239, in save_obj
_emit_insert_statements(
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/orm/persistence.py", line 1135, in _emit_insert_statements
result = cached_connections[connection].execute(
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/engine/base.py", line 1011, in execute
return meth(self, multiparams, params)
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/sql/elements.py", line 298, in _execute_on_connection
return connection._execute_clauseelement(self, multiparams, params)
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/engine/base.py", line 1124, in _execute_clauseelement
ret = self._execute_context(
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/engine/base.py", line 1316, in _execute_context
self._handle_dbapi_exception(
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/engine/base.py", line 1510, in _handle_dbapi_exception
util.raise_(
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/util/compat.py", line 182, in raise_
raise exception
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/engine/base.py", line 1276, in _execute_context
self.dialect.do_execute(
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/engine/default.py", line 593, in do_execute
cursor.execute(statement, parameters)
sqlalchemy.exc.IntegrityError: (sqlite3.IntegrityError) UNIQUE constraint failed: job.job_name
[SQL: INSERT INTO job (job_name, username, wf_target) VALUES (?, ?, ?)]
[parameters: ('20201216_633_test', None, '/cwlab/workflows/gwas_workflow.cwl')]
(Background on this error at: http://sqlalche.me/e/13/gkpj)
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/local/lib/python3.8/dist-packages/cwlab/web_app/create_job.py", line 294, in create_job_from_param_values
create_job_(
File "/usr/local/lib/python3.8/dist-packages/cwlab/exec/exec.py", line 101, in create_job
_ = job_manager.create_job(
File "/usr/local/lib/python3.8/dist-packages/cwlab/database/sqlalchemy/job_manager.py", line 18, in create_job
self.store(job)
File "/usr/local/lib/python3.8/dist-packages/cwlab/database/sqlalchemy/job_manager.py", line 96, in store
self.update()
File "/usr/local/lib/python3.8/dist-packages/cwlab/database/sqlalchemy/job_manager.py", line 91, in update
sleep(retry_delay + retry_delay*random())
NameError: name 'sleep' is not defined
INFO:werkzeug:172.17.0.1 - - [16/Dec/2020 09:58:44] "POST /create_job_from_param_values/ HTTP/1.1" 200 -
{'param_values': {'metadata': ['https://raw.githubusercontent.com/elixir-cloud-aai/demo-workflows/dev/cwl/gwas_workflow/example_job/data/thousand_genomes_meta.csv'], 'variants': ['https://raw.githubusercontent.com/elixir-cloud-aai/demo-workflows/blob/dev/cwl/gwas_workflow/example_job/data/ALL.chr21.integrated_phase1_v3.20101123.snps_indels_svs.genotypes_subsample.vcf.gz']}, 'configs': {'metadata': {'additional_validation_methods': [''], 'aligned_to': '', 'allowed_characters': [''], 'allowed_selection': [''], 'default_value': [''], 'doc': 'all the metadata', 'forbidden_characters': [''], 'group_by': [''], 'is_array': False, 'manipulate_value': [''], 'null_allowed': False, 'null_items_allowed': False, 'parameter_sheet_name': 'parameters', 'secondary_files': [''], 'split_into_runs_by': [''], 'type': 'File'}, 'variants': {'additional_validation_methods': [''], 'aligned_to': '', 'allowed_characters': [''], 'allowed_selection': [''], 'default_value': [''], 'doc': 'to be gwased', 'forbidden_characters': [''], 'group_by': [''], 'is_array': False, 'manipulate_value': [''], 'null_allowed': False, 'null_items_allowed': False, 'parameter_sheet_name': 'parameters', 'secondary_files': [''], 'split_into_runs_by': [''], 'type': 'File'}}, 'output_file': '/cwlab/tmp/kRGXdn6tjPEHsO/param_sheet.xlsx', 'validate_uris': False, 'search_paths': False, 'search_subdirs': True, 'allow_remote_uri': True, 'allow_local_path': True, 'input_dir': '/cwlab/Please fill', 'metadata': {'workflow_name': 'gwas_workflow.cwl'}}
Translation successful.
ERROR:cwlab:name 'sleep' is not defined
Traceback (most recent call last):
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/engine/base.py", line 1276, in _execute_context
self.dialect.do_execute(
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/engine/default.py", line 593, in do_execute
cursor.execute(statement, parameters)
sqlite3.IntegrityError: UNIQUE constraint failed: job.job_name
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/usr/local/lib/python3.8/dist-packages/cwlab/database/sqlalchemy/job_manager.py", line 88, in update
db.session.commit()
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/orm/scoping.py", line 163, in do
return getattr(self.registry(), name)(*args, **kwargs)
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/orm/session.py", line 1042, in commit
self.transaction.commit()
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/orm/session.py", line 504, in commit
self._prepare_impl()
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/orm/session.py", line 483, in _prepare_impl
self.session.flush()
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/orm/session.py", line 2536, in flush
self._flush(objects)
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/orm/session.py", line 2678, in _flush
transaction.rollback(_capture_exception=True)
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/util/langhelpers.py", line 68, in __exit__
compat.raise_(
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/util/compat.py", line 182, in raise_
raise exception
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/orm/session.py", line 2638, in _flush
flush_context.execute()
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/orm/unitofwork.py", line 422, in execute
rec.execute(self)
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/orm/unitofwork.py", line 586, in execute
persistence.save_obj(
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/orm/persistence.py", line 239, in save_obj
_emit_insert_statements(
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/orm/persistence.py", line 1135, in _emit_insert_statements
result = cached_connections[connection].execute(
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/engine/base.py", line 1011, in execute
return meth(self, multiparams, params)
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/sql/elements.py", line 298, in _execute_on_connection
return connection._execute_clauseelement(self, multiparams, params)
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/engine/base.py", line 1124, in _execute_clauseelement
ret = self._execute_context(
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/engine/base.py", line 1316, in _execute_context
self._handle_dbapi_exception(
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/engine/base.py", line 1510, in _handle_dbapi_exception
util.raise_(
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/util/compat.py", line 182, in raise_
raise exception
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/engine/base.py", line 1276, in _execute_context
self.dialect.do_execute(
File "/usr/local/lib/python3.8/dist-packages/sqlalchemy/engine/default.py", line 593, in do_execute
cursor.execute(statement, parameters)
sqlalchemy.exc.IntegrityError: (sqlite3.IntegrityError) UNIQUE constraint failed: job.job_name
[SQL: INSERT INTO job (job_name, username, wf_target) VALUES (?, ?, ?)]
[parameters: ('20201216_633_test', None, '/cwlab/workflows/gwas_workflow.cwl')]
(Background on this error at: http://sqlalche.me/e/13/gkpj)
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/local/lib/python3.8/dist-packages/cwlab/web_app/create_job.py", line 294, in create_job_from_param_values
create_job_(
File "/usr/local/lib/python3.8/dist-packages/cwlab/exec/exec.py", line 101, in create_job
_ = job_manager.create_job(
File "/usr/local/lib/python3.8/dist-packages/cwlab/database/sqlalchemy/job_manager.py", line 18, in create_job
self.store(job)
File "/usr/local/lib/python3.8/dist-packages/cwlab/database/sqlalchemy/job_manager.py", line 96, in store
self.update()
File "/usr/local/lib/python3.8/dist-packages/cwlab/database/sqlalchemy/job_manager.py", line 91, in update
sleep(retry_delay + retry_delay*random())
NameError: name 'sleep' is not defined