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

Editor loses focus and destroys unrelated notes [video] #2084

Closed
wezm opened this issue May 13, 2020 · 10 comments
Closed

Editor loses focus and destroys unrelated notes [video] #2084

wezm opened this issue May 13, 2020 · 10 comments
Labels
bug Something isn't working

Comments

@wezm
Copy link

wezm commented May 13, 2020

Expected

When editing a note the text being typed is directed into the current note.

Observed

Recently, perhaps since the introduction of keyboard shortcuts, using Simplenote on the web has become a nerve racking experience for me. While typing into a note the focus leaves the current note, switches to another and starts typing into it and destroys the formatting in the process.

If you then try to use the revisions slider to rollback to a previous revision the whole page goes blank and needs to be refreshed, at which time the broken note can be restored.

Reproduced

  1. Select a note or create a new note, it doesn't matter
  2. Start typing into the note
  3. See error

You can observe the behaviour in this screen recording: https://files.wezm.net/github/simplenote.mp4

In this video you can see that while I'm typing into the new note, Simplenote jumps to a different note (the next one down the list of notes), types two letters into it but also destroys the (Markdown) formatting of that note.

The behaviour has been observed in:

  • Arch Linux, Firefox 76.0.1, Simplenote web 1.16.0-2066
  • Microsoft Windows 10, Firefox 76.0.1, Simplenote web 1.16.0-2066
@wezm wezm added the bug Something isn't working label May 13, 2020
@charlesverge
Copy link

I've experienced this on simplenote 1.16.0 on ubuntu 20.04 Linux

@rachelmcr
Copy link
Member

Thanks for the report! I just experienced this on Simplenote 1.17.0-beta1 on a Windows 10 VM. As noted in the original report, I can't identify any particular trigger (no consistent key combination or sequence of events prior to the error) but at some point the app jumps to another note. A couple things I have noticed:

  • The app often (I think always?) jumps to the same, wrong note.
  • Sometimes the app jumps back to the original note I was typing in (but the cursor is then at the beginning of the note).

(I haven't seen the issue on Simplenote 1.17.0-beta1 on macOS 10.15.4 but that might just be chance?)

@belcherj
Copy link
Contributor

@wezm Do you see this behavior all the time? Does it still happen when you turn off the keyboard in Settings -> Tools?

@belcherj
Copy link
Contributor

I deployed a version to https://staging.simplenote.com

Could you try to see if this resolves your issue? I also added logging that will appear in dev tools. If it is not fixed those details may help us understand the issue.

@wezm
Copy link
Author

wezm commented May 19, 2020

Do you see this behavior all the time?

Yes, it was consistently happening after typing a few words.

Does it still happen when you turn off the keyboard in Settings -> Tools?

I tested this morning in Version 1.16.0-2078 on the web with keyboard shortcuts on and off and it didn't happen at all. :-/

Could you try to see if this resolves your issue?

I was also unable to reproduce the issue on the staging site.

@belcherj
Copy link
Contributor

Fixed in 1.18, whould be out by tomorrow.

@belcherj
Copy link
Contributor

It has been fixed on web for a couple of weeks.

@wezm
Copy link
Author

wezm commented Jun 16, 2020

There doesn't seem to be a PR or commit referencing this issue. I am curious what the fix was?

@belcherj
Copy link
Contributor

Here is the PR: #2111

The issue was that the note you were editing was being removed briefly from one of the several places that notes are stored. This caused the note list to update briefly to not include the note being edited. When that occurred it selected another note. We removed some of the note selection to fix the issue. We are currently doing a big refactor to simplify the app and remove a lot of the duplicate data stores that were the source of the issue.

@wezm
Copy link
Author

wezm commented Jun 17, 2020

Great, thanks for the explanation. 😃

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

4 participants