-
-
Notifications
You must be signed in to change notification settings - Fork 25
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
Add fall back on SRA if ENA fails #5
Conversation
Awesome thank you very much @mbhall88 ! I've got to get a poster put together, but will get to this ASAP. Quick glance everything looked fine to me Thanks again! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A very pedantic thought; maybe a minor version bump would be more suitable?
From semver
MINOR version when you add functionality in a backwards compatible manner
Good call! |
to avoid variables shadowing global context
I also have a few other fixes incoming so maybe hold off merging |
Okay, I've updated the original comment with a list of all of the stuff I have done. Again, I won't be offended if you don't want some/all of this. I just thought I'd suggest it as I use this project quite heavily and find these things to be quite useful. Thanks for creating this tool! |
@mbhall88 let me know when you think its all set. |
I've successfully run it now on ~290 run accessions that wouldn't download successfully with v1.0.6 👍 So I reckon it's good to go. |
Awesome! Just wanted to make sure you got all the changes in you'd like. |
Thank you so much @mbhall88 I'm planning a release for Bactopia and going to try and sneak this in there as well! |
Thank you for the SUPER helpful tool. I hate dealing with the SRA/ENA APIs so you've saved me a tonne of days dealing with that stuff. |
As the title suggests, this PR adds functionality that will try from SRA if ENA fails.
I formatted the code with black sorry, so the PR looks more complicated than it is.
Feel free to not take any of this either. I won't be offended.
Added
-o
shorthand option for--outdir
-F/--only-provider
, which supercedes--sra_only
. I left--sra_only
in there for backwards compatibility and added a deprecation notice in the help description for it.Changed
main
function to avoid variable shadowingena
. I've also made the option case insensitive, rather than listing the cased versions of the available providersexecute
calls which were mostly operations easily dealt with bypathlib.Path
md5sum
to usehashlib.md5
instead of executing a subprocess call tomd5sum
import
statements out of function bodies to the top of the fileRemoved