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

Transcriptions are failing to save in the editor #1176

Closed
7 tasks done
blms opened this issue Oct 10, 2022 · 2 comments
Closed
7 tasks done

Transcriptions are failing to save in the editor #1176

blms opened this issue Oct 10, 2022 · 2 comments
Assignees
Labels
🐛 bug Something isn't working

Comments

@blms
Copy link
Contributor

blms commented Oct 10, 2022

Testing notes (QA)

In the transcription editor for a document:

  • Create and save a new annotation and confirm it persists in the editor
  • Edit and save an existing annotation and confirm the change persists in the editor
  • Delete an existing annotation and confirm it is deleted successfully

dev notes

  • Fix save failure condition
  • raise events on save/delete failure
  • raise events on save/delete success
  • display errors/success messages in frontend
@blms blms added the 🐛 bug Something isn't working label Oct 10, 2022
@blms blms self-assigned this Oct 10, 2022
@blms
Copy link
Contributor Author

blms commented Oct 11, 2022

About to jump into a meeting, so before I forget: I think the save failure is another Annotorious/async race condition.

First we await the Annotorious promise, which raises an event. Our event handler awaits saving the annotation to storage.

Back in the original function, we fetch all annotations from storage after the Annotorious promise resolves.

But there's no guarantee that our event handler has itself resolved. It's entirely possible (and indeed, it appears to be the case) that we are calling this.storage.loadAnnotations() before the annotation has finished saving to the storage. Should be as simple as calling that method in storage.ts handleUpdateAnnotation instead.

blms added a commit that referenced this issue Oct 13, 2022
Co-authored-by: Rebecca Sutton Koeser <rlskoeser@users.noreply.github.com>
blms added a commit that referenced this issue Oct 13, 2022
@blms blms changed the title Transcriptions are failing to save in the editor, with no clear feedback about success/failure status Transcriptions are failing to save in the editor Oct 13, 2022
@rlskoeser rlskoeser added the 🗜️ awaiting testing Implemented and ready to be tested label Oct 13, 2022
@kseniaryzhova
Copy link

@rlskoeser works for me, thank you!

@rlskoeser rlskoeser removed the 🗜️ awaiting testing Implemented and ready to be tested label Oct 18, 2022
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