AllTheBacteria / AllTheBacteria/atb-cli
atb download --from <file> --output-dir . does not work from mlst manifest
Nobody has claimed this yet.
- Dominant language
- Go
- Stars
- 35
- Forks
- 1
- Avg merge
- 12m
- Merged PRs (30d)
- 2
Description
Tested:
atb mlst --species "Escherichia coli" --st 216 --hq-only > E._coli_ST216/E._coli_ST216_accessions.txt
atb download --from E._coli_ST216_accessions.txt --output-dir .
Result:
This message is printed to screen but no downloads start
Downloading 570 file(s) to .
Workaround:
cut -f1 E._coli_ST216_accessions.txt |
while read -r accession
do
wget "https://allthebacteria-assemblies.s3.eu-west-2.amazonaws.com/${accession}.fa.gz"
done
Further testing
This however works:
atb query --species-like "Pseudomonas%fluorescens" > pf.txt
atb download --from pf.txt --output-dir .
I wondered if maybe it was because the large number of files in the original query so I tested this, but also did not work
mkdir test
head -n 5 E._coli_ST216_accessions.txt > test/test.txt
cd test
atb download --from test.txt --output-dir .
Output:
Downloading 4 file(s) to .
Completed: 0/4 Failed: 4 Bytes: 0 B
error: SAMEA104027617: Get "SAMEA104027617": unsupported protocol scheme ""
error: SAMEA103923478: Get "SAMEA103923478": unsupported protocol scheme ""
error: SAMEA10300091: Get "SAMEA10300091": unsupported protocol scheme ""
error: SAMD00092883: Get "SAMD00092883": unsupported protocol scheme ""
Error: 4 download(s) failed
4 download(s) failed
Perhaps it needed to loop through all 570 files before failing them all in the original call
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by tracing the atb download --from ... handling and compare the accession lines produced by atb mlst with those from atb query. Reproduce with the five-line manifest and inspect why entries such as SAMEA104027617 become URLs without a protocol; done means the manifest downloads succeed as the query-generated file does.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go
- Domain
- cli
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 66/100