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

Drag and drop tsv metadata not adding color by option to dropdown #1176

Closed
eharkins opened this issue Jun 24, 2020 · 3 comments
Closed

Drag and drop tsv metadata not adding color by option to dropdown #1176

eharkins opened this issue Jun 24, 2020 · 3 comments
Assignees
Labels
bug Something isn't working

Comments

@eharkins
Copy link
Contributor

Current Behavior
From @trvrb :

drag-and-drop metadata is working on auspice.us, but is perhaps broken on nextstrain.org.

Expected behavior
Drag and drop should work to add a color by option to the dropdown upon dropping and parsing a TSV. This works on auspice.us

How to reproduce
Reproduce bug:

  1. On current master, run auspice view --datasetDir examples and go to http://localhost:4000/minimal/v2
  2. When that has loaded, drag and drop https://gist.github.com/eharkins/c89ae185f164c2af3ae6668ffa8f55c2
  3. Note that collection is not an option to select in the sidebar's Color By dropdown

Reproduce correct behavior:

  1. Go to auspice.us
  2. Drag and drop https://github.com/nextstrain/auspice/blob/master/examples/minimal_v2.json
  3. When that has loaded, drag and drop https://gist.github.com/eharkins/c89ae185f164c2af3ae6668ffa8f55c2
  4. Note that collection is an option to select in the sidebar's Color By dropdown

Possible solution
Differing versions of auspice (2.17.0 in nextstrain.org and 2.12.0 in auspice.us) are my best guess as to the difference in behavior - several hundred commits in auspice separate the two. One way to solve this is to try and find the commit that broke it, another way is more directly debugging the current code.

Your environment: if browsing Nextstrain online

  • Operating system: macOS High Sierra 10.13.4 (17E199)
  • Browser: Chrome Version 83.0.4103.106 (Official Build) (64-bit)
@eharkins eharkins added bug Something isn't working high priority labels Jun 24, 2020
@eharkins eharkins self-assigned this Jun 24, 2020
@jameshadfield
Copy link
Member

It used to (and still should) work in auspice by itself, so bisecting (perhaps from 2.12 which auspice.us is running) should identify the commit which breaks it.

@jameshadfield
Copy link
Member

Bisecting indicates this is 20d8439, which makes sense: the new coloring is being correctly added to the redux state as an available option, but the drop-down is not being updated due to the shouldComponentUpdate code introduced in that commit. This also explains why the TSV-derived color-by option magically appears in the dropdown once you change the color-by to any one of the original options.

eharkins added a commit that referenced this issue Jun 24, 2020
see github.com//issues/1176#issuecomment-649097216
@trvrb
Copy link
Member

trvrb commented Jul 20, 2020

Looks like this was resolved.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants