zooniverse / front-end-monorepo

A rebuild of the front-end for zooniverse.org
https://www.zooniverse.org
Apache License 2.0
104 stars 30 forks source link

Scarlets & Blues annotations are lost if you navigate between NextJS project pages #2536

Closed eatyourgreens closed 2 years ago

eatyourgreens commented 2 years ago

Package

app-project lib-classifier

Describe the bug

PFE remembers your subject and annotations if you leave the Classify page and come back again to continue classifying. Try it out here on Measuring the ANZACS: https://www.zooniverse.org/projects/zooniverse/measuring-the-anzacs/classify

You should find that you remain on the same subject and the form is pre-filled with your annotations when the classifier remounts.

Try out the same thing with the dropdown menus on HMS NHS and you should find that the menu values are preserved if you leave the page and use the Back button to come back: https://www.zooniverse.org/projects/msalmon/hms-nhs-the-nautical-health-service/classify/workflow/18624/subject-set/83482

Similarly the transcription task annotations for Davy Notebooks are also remembered if you leave the page and come back. https://www.zooniverse.org/projects/humphrydavy/davy-notebooks-project/classify/workflow/18786

Now try filling out the text boxes for Scarlets and Blues: https://www.zooniverse.org/projects/bogden/scarlets-and-blues/classify/workflow/18505/subject-set/98879/subject/69734438 If you leave the page, then return with the Back button, your annotations flash up briefly then vanish.

Here's a Talk thread where a volunteer reports starting a transcription, going to Talk then losing her work when she returned with the Back button. https://www.zooniverse.org/projects/bogden/scarlets-and-blues/talk/3533/2215783?comment=3634120

Here are a couple of screen recordings. The bug seems specific to the text task in Scarlets & Blues, and appears when you go to the home page and back.

HMS NHS remembers my entries when I leave and come back.

https://user-images.githubusercontent.com/59547/141641780-2c2597d6-e204-4685-81b7-9cef0a764a10.mov

Davy Notebooks also remembers work across pages.

https://user-images.githubusercontent.com/59547/141683491-239bbfa5-34de-440a-b14d-e63af845f352.mov

Scarlets and Blues deletes my classification if I go to the home page and come back.

https://user-images.githubusercontent.com/59547/141641869-2221c01d-f96a-48ec-9741-08d5d8e3dc97.mov

Tested in Firefox 94 on MacOS 11.6.1.

eatyourgreens commented 2 years ago

It's worth checking here whether the bug is in individual subject selection, which is only used by S&B, or in the text task.

eatyourgreens commented 2 years ago

It’s also worth testing this on #2520, which removes global storage of your current annotations.

eatyourgreens commented 2 years ago

Here's another recording of HMS NHS, showing that text annotations can be remembered across pages, so the bug must be specific to projects that use subject URLs.

https://user-images.githubusercontent.com/59547/141781844-4b46767e-bc41-4d92-b4b0-956beb8047f8.mov

eatyourgreens commented 2 years ago

Browser caching of your active annotation varies from browser to browser, so here's a handy table. Tested by making a couple of annotations, going to Talk and back with the browser Back button.

Browser Measuring the Anzacs (PFE) HMS NHS (FEM)
Chrome 92 𐄂
Firefox 94
Safari 15
Edge 95 𐄂