commit/galaxy-central: 4 new changesets
4 new commits in galaxy-central: https://bitbucket.org/galaxy/galaxy-central/commits/01f5eba13754/ Changeset: 01f5eba13754 User: kellrott Date: 2015-01-29 23:55:38+00:00 Summary: Fixing provenance api request bug when data element has job == None Affected #: 1 file diff -r a917e3d871f2782ae4cf1b57bb4775c0e0224efe -r 01f5eba13754ffd2316a227b3b2c4ab4ee8282f0 lib/galaxy/webapps/galaxy/api/provenance.py --- a/lib/galaxy/webapps/galaxy/api/provenance.py +++ b/lib/galaxy/webapps/galaxy/api/provenance.py @@ -52,15 +52,21 @@ if item.copied_from_library_dataset_dataset_association: item = item.copied_from_library_dataset_dataset_association job = item.creating_job - return { - "id": trans.security.encode_id(item.id), - "uuid": ( lambda uuid: str( uuid ) if uuid else None )( item.dataset.uuid), - "job_id": trans.security.encode_id( job.id ), - "tool_id": job.tool_id, - "parameters": self._get_job_record(trans, job, follow), - "stderr": job.stderr, - "stdout": job.stdout, - } + if job is not None: + return { + "id": trans.security.encode_id(item.id), + "uuid": ( lambda uuid: str( uuid ) if uuid else None )( item.dataset.uuid), + "job_id": trans.security.encode_id( job.id ), + "tool_id": job.tool_id, + "parameters": self._get_job_record(trans, job, follow), + "stderr": job.stderr, + "stdout": job.stdout, + } + else: + return { + "id": trans.security.encode_id(item.id), + "uuid": ( lambda uuid: str( uuid ) if uuid else None )( item.dataset.uuid) + } return None def _get_job_record(self, trans, job, follow): https://bitbucket.org/galaxy/galaxy-central/commits/bd8d5ea01638/ Changeset: bd8d5ea01638 User: kellrott Date: 2015-01-30 00:33:23+00:00 Summary: Adding addtional runtime metrics into provenance record Affected #: 1 file diff -r 01f5eba13754ffd2316a227b3b2c4ab4ee8282f0 -r bd8d5ea01638566e972d50f4428ac1ae44301b3f lib/galaxy/webapps/galaxy/api/provenance.py --- a/lib/galaxy/webapps/galaxy/api/provenance.py +++ b/lib/galaxy/webapps/galaxy/api/provenance.py @@ -53,6 +53,10 @@ item = item.copied_from_library_dataset_dataset_association job = item.creating_job if job is not None: + m = dict( (a.metric_name, str(a.metric_value)) for a in job.text_metrics ) + m2 = dict( (a.metric_name, float(a.metric_value)) for a in job.numeric_metrics ) + for a in m2: + m[a] = m2[a] return { "id": trans.security.encode_id(item.id), "uuid": ( lambda uuid: str( uuid ) if uuid else None )( item.dataset.uuid), @@ -61,6 +65,9 @@ "parameters": self._get_job_record(trans, job, follow), "stderr": job.stderr, "stdout": job.stdout, + "update_time": job.update_time.isoformat(), + "create_time": job.create_time.isoformat(), + "metrics" : m } else: return { https://bitbucket.org/galaxy/galaxy-central/commits/09d542aedfec/ Changeset: 09d542aedfec User: kellrott Date: 2015-01-30 18:49:22+00:00 Summary: Removing metrics from provenance, because reasons Affected #: 1 file diff -r bd8d5ea01638566e972d50f4428ac1ae44301b3f -r 09d542aedfec5a8357bdd4f5318cca381610030a lib/galaxy/webapps/galaxy/api/provenance.py --- a/lib/galaxy/webapps/galaxy/api/provenance.py +++ b/lib/galaxy/webapps/galaxy/api/provenance.py @@ -53,10 +53,6 @@ item = item.copied_from_library_dataset_dataset_association job = item.creating_job if job is not None: - m = dict( (a.metric_name, str(a.metric_value)) for a in job.text_metrics ) - m2 = dict( (a.metric_name, float(a.metric_value)) for a in job.numeric_metrics ) - for a in m2: - m[a] = m2[a] return { "id": trans.security.encode_id(item.id), "uuid": ( lambda uuid: str( uuid ) if uuid else None )( item.dataset.uuid), @@ -65,9 +61,6 @@ "parameters": self._get_job_record(trans, job, follow), "stderr": job.stderr, "stdout": job.stdout, - "update_time": job.update_time.isoformat(), - "create_time": job.create_time.isoformat(), - "metrics" : m } else: return { https://bitbucket.org/galaxy/galaxy-central/commits/ce2f405062f6/ Changeset: ce2f405062f6 User: dannon Date: 2015-01-30 19:19:16+00:00 Summary: Merged in kellrott/galaxy-farm (pull request #654) Fixing provenance api request bug when data element has job == None Affected #: 1 file diff -r 18dacdf8674e21c5e9a2bb61036382e44f6842bc -r ce2f405062f677cf826a4cac0647a0e0f8beef65 lib/galaxy/webapps/galaxy/api/provenance.py --- a/lib/galaxy/webapps/galaxy/api/provenance.py +++ b/lib/galaxy/webapps/galaxy/api/provenance.py @@ -52,15 +52,21 @@ if item.copied_from_library_dataset_dataset_association: item = item.copied_from_library_dataset_dataset_association job = item.creating_job - return { - "id": trans.security.encode_id(item.id), - "uuid": ( lambda uuid: str( uuid ) if uuid else None )( item.dataset.uuid), - "job_id": trans.security.encode_id( job.id ), - "tool_id": job.tool_id, - "parameters": self._get_job_record(trans, job, follow), - "stderr": job.stderr, - "stdout": job.stdout, - } + if job is not None: + return { + "id": trans.security.encode_id(item.id), + "uuid": ( lambda uuid: str( uuid ) if uuid else None )( item.dataset.uuid), + "job_id": trans.security.encode_id( job.id ), + "tool_id": job.tool_id, + "parameters": self._get_job_record(trans, job, follow), + "stderr": job.stderr, + "stdout": job.stdout, + } + else: + return { + "id": trans.security.encode_id(item.id), + "uuid": ( lambda uuid: str( uuid ) if uuid else None )( item.dataset.uuid) + } return None def _get_job_record(self, trans, job, follow): Repository URL: https://bitbucket.org/galaxy/galaxy-central/ -- This is a commit notification from bitbucket.org. You are receiving this because you have the service enabled, addressing the recipient of this email.
participants (1)
-
commits-noreply@bitbucket.org