Skip to content
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

Activate virtualenv in updateucsc.sh.sample #11800

Merged
merged 1 commit into from
Apr 7, 2021

Conversation

nsoranzo
Copy link
Member

@nsoranzo nsoranzo commented Apr 7, 2021

What did you do?

  • Activate virtualenv in the cron/updateucsc.sh.sample script

Why did you make this change?

If the virtualenv is not activated, Python 2 is used or requests may be missing, resulting in errors:

$ bash cron/updateucsc.sh.sample
Creating required directories.
cron/../tool-data/shared/ucsc/new already exists, continuing.
cron/../tool-data/shared/ucsc/chrom already exists, continuing.
cron/../tool-data/shared/ucsc/chrom/new already exists, continuing.
Wed  7 Apr 18:12:25 BST 2021
Updating UCSC shared data tables.
Updating builds.txt
Traceback (most recent call last):
  File "cron/../cron/parse_builds.py", line 11, in <module>
    import requests
ImportError: No module named requests
Failed to update builds.txt
Updating ucsc_build_sites.txt
Traceback (most recent call last):
  File "cron/../cron/parse_builds_3_sites.py", line 8, in <module>
    import requests
ImportError: No module named requests
Failed to update builds.txt
Building chromInfo tables.
  File "cron/../cron/build_chrom_db.py", line 78
    print("\t".join(chrominfo), file=outfile)
                                    ^
SyntaxError: invalid syntax
Failed to update chromInfo tables.
Update complete.
Adding Manual Builds.
  File "cron/../cron/add_manual_builds.py", line 36
    print(build + "\t" + name + " (" + build + ")", file=build_file_out)
                                                        ^
SyntaxError: invalid syntax
Manual addition failed

How to test the changes?

(select the most appropriate option; if the latter, provide steps for testing below)

  • I've included appropriate automated tests.
  • This is a refactoring of components with existing test coverage.
  • Instructions for manual testing are as follows:
    1. bash cron/updateucsc.sh.sample

License

Otherwise Python 2 is used or `requests` may be missing.
@nsoranzo nsoranzo added this to the 21.05 milestone Apr 7, 2021
@dannon dannon merged commit 2f2439a into galaxyproject:dev Apr 7, 2021
@nsoranzo nsoranzo deleted the virtualenv_updateucsc branch April 8, 2021 01:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants