Add opt-in genome download feature #1149
Open
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description of proposed changes
When a corresponding FASTA file is placed in the same directory with auspice's
JSON file, for example a
ncov_global.fasta
is placed in the same directory withncov_global.json
: the genome database handling functionality will kick in andgenerate a file-based NeDB database at server startup time. A "Selected
Genomes (Fasta)" download button also then appears in side the "Download Data"
popup window. For dataset that doesn't have a corresponding FASTA file, this
functionality is inactive.
Related issue(s)
Fixes #1110
Testing
ncov_global.fasta
todatasetDir
(i.e. ./data) for testing withncov_global.json
. Start or restartasupice
. Fasta record IDs inside the FASTA file and tree tip names should match for auspice to fetch the correct genome from the database.None.
Note:
Upgrading
papaparse
to newer version is not required for this feature to function properly, but I upgraded that in response to severe security warning bynpm
during installation process.Thank you for contributing to Nextstrain!