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

feat: fetch sidecar Auspice JSON if .root_sequence is not on the tree #1460

Merged
merged 7 commits into from
May 30, 2024

Conversation

ivan-aksamentov
Copy link
Member

Followup of #1455

If .root_sequence is not available on Auspice JSON, let's attempt to fetch ref sequence from sidecar Auspice JSON. For that let's GET from the same URL, but with Accept: application/vnd.nextstrain.dataset.root-sequence+json header.

Followup of #1455

If `.root_sequence` is not available on Auspice JSON, let's attempt to fetch ref sequence from sidecar Auspice JSON. For that let's GET from the same URL, but with `Accept: application/vnd.nextstrain.dataset.root-sequence+json` header.
Copy link

vercel bot commented May 30, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated (UTC)
nextclade ✅ Ready (Inspect) Visit Preview May 30, 2024 9:47pm

@ivan-aksamentov
Copy link
Member Author

ivan-aksamentov commented May 30, 2024

Attempt to run with a very large SC2 tree has hit the local storage limit.

https://nextclade-git-feat-fetch-auspice-sidecar-json-nextstrain.vercel.app/?dataset-json-url=https://nextstrain.org/ncov/gisaid/global/all-time

Well, I should not store the dataset in the local storage in the first place. Need to rethink my decisions about how to persist the datasets from remote different sources (if it all?). Probably should just store the (type, dataset URL) or (dataset server, dataset name, dataset version) and refetch. Will take a bit of plumbing though.

Not related to this PR, but something to address ASAP.

@ivan-aksamentov
Copy link
Member Author

It's unclear how to implement a symmetric functionality in CLI. I guess we can tell users to paste their sidecar into the main JSON? Does it make sense to introduce a new CLI arg for a new file type?

@ivan-aksamentov ivan-aksamentov marked this pull request as ready for review May 30, 2024 00:46
@tsibley
Copy link
Member

tsibley commented May 30, 2024

@ivan-aksamentov The root sequence sidecar for x_y_z.json is canonically at x_y_z_root-sequence.json when dealing with a file system, so for the CLI it'd seem reasonable to look for that file automatically.

Maybe the CLI could also support fetching a dataset specified as a URL directly, and then make the same content-nego request behind the scenes in that case?

@ivan-aksamentov ivan-aksamentov merged commit f17e687 into master May 30, 2024
20 checks passed
@ivan-aksamentov ivan-aksamentov deleted the feat/fetch-auspice-sidecar-json branch May 30, 2024 23:47
jameshadfield added a commit to nextstrain/auspice that referenced this pull request Jun 5, 2024
Most discussion about this functionality has been happening within the
nextclade repo, see <nextstrain/nextclade#1455>
and <nextstrain/nextclade#1460> for a good
summary.
jameshadfield added a commit to nextstrain/auspice that referenced this pull request Jun 5, 2024
Most discussion about this functionality has been happening within the
nextclade repo, see <nextstrain/nextclade#1455>
and <nextstrain/nextclade#1460> for a good
summary.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants