New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[17.09] Fix tool-shed-config-validate #5343

merged 1 commit into from Jan 25, 2018


None yet
4 participants

ValentinChCloud commented Jan 19, 2018

I test the command make tool-shed-config-validate with @erasche , and it returns

root@v-VirtualBox:~/galaxy# make tool-shed-config-validate
if [ -f .venv/bin/activate ]; then . .venv/bin/activate; fi; python lib/galaxy/webapps/ validate tool_shed
Traceback (most recent call last):
  File "lib/galaxy/webapps/", line 709, in <module>
  File "lib/galaxy/webapps/", line 264, in main
    action_func(args, app_desc)
  File "lib/galaxy/webapps/", line 402, in _validate
    raw_config = _order_load_path(f)
  File "lib/galaxy/webapps/", line 576, in _order_load_path
    with open(path, "r") as f:
TypeError: coercing to Unicode: need string or buffer, file found
Makefile:60: recipe for target 'tool-shed-config-validate' failed
make: *** [tool-shed-config-validate] Error 1

The problem seems to come from the function def _validate(args, app_desc):
In the function_validate a path is found and the config file open, and the file object is given to the function def _order_load_path(path): line 398
The problem is, in the function _order_load_path try to open again the config file and failed, line574

I propose to remove the line 400 with open(path, "r") as f: because the file object named f isn't used somewhere else and to replace it by the path variable when the function _order_load_path(path) is called, like it's used line 372

@ValentinChCloud ValentinChCloud changed the title from Fix tool-shed-config-validate to [17.09] Fix tool-shed-config-validate Jan 19, 2018

@galaxybot galaxybot added the triage label Jan 19, 2018

@martenson martenson added this to the 18.01 milestone Jan 19, 2018

@martenson martenson requested a review from jmchilton Jan 19, 2018


This comment has been minimized.


jmchilton commented Jan 25, 2018

Thanks for the fix - the current version is mostly definitely broken and this seems to fix it for me. Really appreciate this.

@martenson martenson merged commit 73418ab into galaxyproject:release_17.09 Jan 25, 2018

1 check passed

continuous-integration/travis-ci/pr The Travis CI build passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment