commit/galaxy-central: natefoo: Add $__user_name__ to job template.
1 new commit in galaxy-central: https://bitbucket.org/galaxy/galaxy-central/changeset/069768b7833e/ changeset: 069768b7833e user: natefoo date: 2012-09-18 18:13:02 summary: Add $__user_name__ to job template. affected #: 1 file diff -r 32091cc60876e9720f2ae2b855e9e7f43e8c775a -r 069768b7833ebae78f1c7c7aa97904627540ac3a lib/galaxy/jobs/__init__.py --- a/lib/galaxy/jobs/__init__.py +++ b/lib/galaxy/jobs/__init__.py @@ -155,15 +155,18 @@ if special: out_data[ "output_file" ] = FakeDatasetAssociation( dataset=special.dataset ) - # These can be passed on the command line if wanted as $userId $userEmail - if job.history and job.history.user: # check for anonymous user! - userId = '%d' % job.history.user.id - userEmail = str(job.history.user.email) + # These can be passed on the command line if wanted as $__user_*__ + if job.history and job.history.user: + user_id = '%d' % job.history.user.id + user_email = str(job.history.user.email) + user_name = str(job.history.user.username) else: - userId = 'Anonymous' - userEmail = 'Anonymous' - incoming['__user_id__'] = incoming['userId'] = userId - incoming['__user_email__'] = incoming['userEmail'] = userEmail + user_id = 'Anonymous' + user_email = 'Anonymous' + user_name = 'Anonymous' + incoming['__user_id__'] = incoming['userId'] = user_id + incoming['__user_email__'] = incoming['userEmail'] = user_email + incoming['__user_name__'] = user_name # Build params, done before hook so hook can use param_dict = self.tool.build_param_dict( incoming, inp_data, out_data, self.get_output_fnames(), self.working_directory ) # Certain tools require tasks to be completed prior to job execution 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)
-
Bitbucket