-
Notifications
You must be signed in to change notification settings - Fork 128
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
schemas: Add missing display_default properties for Auspice config v2 #916
Conversation
eed47a8
to
0c09991
Compare
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.
Changes look good from reading the diff. Scanning the languages auspice supports I think they're all BCP-47, although this was never specified explicitly.
CI is failing, though it's not immediately obvious why...
ERROR: 'nDescendents' is not one of ['clade', 'aa', 'none']. Trace: ... - properties - display_defaults - properties - branch_label - enum
…g and dataset) Resolves <#911> which noted "language". In confirming that, I cross-referenced Auspice's view settings doc¹ and code² which revealed "sidebar" and "panels" too. Clarifies the purpose of the two different "panels" keys. ¹ https://docs.nextstrain.org/projects/auspice/en/stable/advanced-functionality/view-settings.html#dataset-json-configurable-defaults ² https://github.com/nextstrain/auspice/blob/ce8380f7/src/actions/recomputeReduxState.js#L699-L718
…nd dataset Reconciles the two schemas with some minor improvements + a bug fix. While the enum values in one schema were valid, they're not the _only_ valid values. This display_default refers to the keys of branch_attr.labels objects on nodes, so I reused the former's pattern of allowed characters. I think that pattern may be too restrictive and not accurately describe what Auspice will handle, but that's a broader issue with other parts of the schema too and something to investigate for another day. Hint that there's a special-cased value ("none") by mentioning it explicitly in the pattern.
0c09991
to
65ebea1
Compare
Sorry, yeah, wasn't quite ready for review. Auspice langs should be BCP-47 (and appear so to me). Repushed with a fix addressing the schema for |
Codecov Report
@@ Coverage Diff @@
## master #916 +/- ##
==========================================
+ Coverage 34.66% 35.02% +0.36%
==========================================
Files 42 42
Lines 6018 6189 +171
Branches 1542 1605 +63
==========================================
+ Hits 2086 2168 +82
- Misses 3859 3940 +81
- Partials 73 81 +8
Continue to review full report at Codecov.
|
Resolves #911 which noted
"language". In confirming that, I cross-referenced Auspice's view
settings doc¹ and code² which revealed "sidebar" and "panels" too.
Clarifies the purpose of the two different "panels" keys.
¹ https://docs.nextstrain.org/projects/auspice/en/stable/advanced-functionality/view-settings.html#dataset-json-configurable-defaults
² https://github.com/nextstrain/auspice/blob/ce8380f7/src/actions/recomputeReduxState.js#L699-L718
Testing
Not yet tested. Will look at CI tests and maybe add a test case too.