Commit Graph

25 Commits

Author SHA1 Message Date
Nicola Soranzo 26a4e146e0 Fix UP031 errors
reported by ruff 0.8.0 .
2024-11-24 21:35:23 +00:00
Nicola Soranzo 0629908541 Fix new UP031 errors from ruff 0.4.2 2024-04-29 00:09:38 +01:00
Matthias Bernt b81b2f827e remove more leftover references to cluster_files_directory 2022-08-12 16:07:35 +02:00
Dannon Baker 623a5e165a Apply black formatting.
Apply isort.
2022-02-03 07:42:20 -05:00
Nicola Soranzo 9d74bba7fb Drop support for retired Python 3.5
Upgrade syntax using `pyupgrade --py36-plus` .

Manually drop several `six` imports.

Also:
- Remove broken pr_cache in scripts/bootstrap_history.py
- Fix broken prefix removal in lib/galaxy/tool_util/deps/mulled/mulled_build.py
2020-10-07 11:52:13 +01:00
M Bernt 97ba92f3cf external_runner: load json template first
if the JSON is loaded first the cluster_files_directory
does not need to be accessible by the real user (ie all users)
2018-11-09 17:48:36 +01:00
Nicola Soranzo 9b4de72ca6 Fix all E722 errors and ignore E741
Introduced in flake8 3.5.0
Fix import order.
2017-10-24 11:29:09 +01:00
Nicola Soranzo a353b2e88f Fix E127 errors introduced by previous commit
using:
```
autopep8 -i -r --exclude $(sed -e 's|^|./|' -e 's|/$||' .ci/flake8_blacklist.txt | paste -sd,) --select E127 .
```
2017-08-17 11:35:39 +01:00
Nicola Soranzo 21b44bf348 Fix all E201 and E202 style errors
using the following command:
```
autopep8 -i -r --exclude $(sed -e 's|^|./|' -e 's|/$||' .ci/flake8_blacklist.txt | paste -sd,) --select E201,E202 .
```
2017-08-17 11:35:39 +01:00
bernt@informatik.uni-leipzig.de f83871d070 moved assign_all_groups parameter to config 2017-06-13 22:12:48 +02:00
Nicola Soranzo 3d57c22b63 Fix I201 errors from flake8-import-order
Also fix Python3 compatibility.
Remove unused method
galaxy.tools.parameters.sanitize.ToolParameterSanitizer.restore_param() .
2016-11-23 18:31:04 +00:00
Nicola Soranzo 1d17a29c79 Fixes for pycodestyle 2.2.0 2016-11-15 16:56:50 +00:00
Junzhou Wang f68a8198da Python3: scripts/cleanup_datasets scripts/data_libraries 2016-06-25 21:49:25 -04:00
Nicola Soranzo 8a43b2b492 Python 3: use "as" instead of comma in except clause 2016-05-17 23:53:16 +01:00
Nate Coraor 0469ed29e0 Remove egg cruft from scripts/ 2015-09-21 15:55:07 -04:00
Nicola Soranzo 6569c2dcc3 Partially lint scripts/ . 2015-07-13 20:13:28 +01:00
Marek Vavrusa 43cd2083f6 runners/drmaa: set 'workingDirectory' correctly
this fixes an issue with when the Galaxy lib (and therefore working
directory) is not shared with the compute nodes
2015-04-24 16:12:33 +02:00
John Chilton 78e0ede829 Fix for running LSF DRMAA jobs as 'real' user.
Fix thanks to Chong Chen at IBM - "When invoking the LSF drmma api to submit a job, the API will print the message like 'Job <78> is submitted to default queue <normal>'. So if the Galaxy want to use this API, need modify the drmaa_external_runner.py script to handle this message.  LSF already support a env variable to disable this message print out, "BSUB_QUIET", set this into env can disable this message output."

A second issue was related to subsequent querying of the job state as a user other than the submitter - according to Chong Chen this has been fixed in latest LSF DRMAA changes on github (https://github.com/PlatformLSF/lsf-drmaa/commit/43e62546172b90d9f95e90273d77f4c35a0bb404).
2014-08-18 08:43:37 -04:00
Dannon Baker 559ecb4ec8 Remove dependency on simplejson; convert everything over to using the json module in the python standard library. 2014-01-10 07:29:05 -05:00
John Chilton 5e36bde9c8 Rework contribution from pull request #267 to be optional.
To obtain the behavior (assigning all groups for a given user for each job submission) change the property - 'drmaa_external_runjob_script' from  'scripts/drmaa_external_runner.py' to 'scripts/drmaa_external_runner.py --assign_all_groups'.

Making this optional because my concern is that this could be an expensive operation on some clusters.
2013-12-10 08:26:22 -06:00
John Chilton 039780705c PEP-8 fixes for scripts/drmaa_external_runner.py. 2013-12-10 08:02:17 -06:00
Frederik Delaere c939ebb9d8 Fix for two issues
- The secondary user groups are not assigned to the user
 - When the json file is on a NFS share where root access is not allowed this script fails with a "error: JobTemplate file (/path/to/jsonfile) doesn't exist" error

To fix the first we have to go through all the groups of the user in set_user(uid) and assign them with os.setgroups()

The second one is fixed by removing the check if the json file exists in the function validate_paramters and move that check to a new function which is called after set_user(uid). Because its possible that the new user (the one in uid) has access to that file but root hasn't
2013-11-26 15:04:57 +00:00
Nate Coraor 9ab95a9fa9 Fix passing of job name when running jobs as a system user. 2012-10-03 11:51:07 -04:00
Carl Eberhard d97ada4bb5 minor docstring adds in /scripts 2012-08-03 13:31:48 -04:00
ichorny 236276b132 add actual user changes to galaxy-central 2011-10-21 14:01:48 -07:00