Text in tables disappears after switching to another note and back

Testing version:
TestFlight beta 2. iOS, iPadOS, macOS

What were you doing:
I created a new note and inserted a table, then added some text into the cells. I switched to another note, and then back to the first note

What feature did you use:
Tables

What happened:
When i switch back to the note with the table, all of the text is missing from the table. This happens on all three platforms, iOS, iPadOS and macOS. I can reproduce it consistently

What did you expect to happen:
Text to remain in the table :grin:

This seems similar to this issue reported in Panda in Oct 2020, but in that case hitting “Undo” caused the text to disappear. I have to switch to another note and back. Hitting “Undo” seems ok

Edit: turns out I don’t even need to open another note first. Just going back to the note list (on iOS) will cause all table text to disappear. Other text before and after the table is fine


Edit 2: Tables text also does not sync, and disappears after locking and locking iPhone. What I did:

  1. Open a note on macOS with a table and some regular text
  2. Open the same note on iOS
  3. On iOS, add some text to the table, and add some text to the regular text line
  4. Dismiss the keyboard on iOS
  5. The regular line text shows up in the macOS note after a few seconds, but the table text never does
  6. Lock the iPhone while the note is still showing
  7. Immediately unlock the phone, and the table text disappears after a very short delay
2 Likes

I just tested and it did the same thing to me on iOS. I didn’t try macOS yet. I also have the TestFlight beta.

Update: I now tested on macOS and the same thing happens.

1 Like

Table changes aren’t being transferred from the editor view to the model in the beta, meaning you see a table that’s populated in the editor, but Bear beta (internally) just sees an empty table. You can witness this by creating a table, adding any content to the table, and then either typing ``` on the line before the table (to convert it to markdown) or selecting the note/table, picking Edit > Copy As > Markdown from the menu, and pasting into a plain text editor (both of these, just like switching away & returning to the note, reveal what Bear is seeing internally: an empty 2x2 table).

It’s tricky, because everything looks okay in the editor, but you can’t trust that Bear is seeing what you’re seeing. If you aren’t sure whether you made changes to a table, then be sure to use this workaround before navigating away from the note in the editor.

Given this is a nasty bug (data loss) and easily reproducible, it’s fair to assume it will be quickly fixed by the Bear team, so won’t be an issue for long.

3 Likes

Yea, I also confirmed that the data is not getting written to Bear’s SQLite DB. However, if I quit Bear, edit the note’s table text directly (in the ZSFNOTE.ZNOTE.ZTEXT column), upon restarting Bear the note retains the text I manually edited, even if I switch to other notes and back again. It also retains the manually edited text when editing the table, but any changes are silently discarded. So that’s good news in that existing notes should keep the previous table text, but I’m just not going to edit any tables until there’s a fix

So all this seems to confirm your suspicion that the text is indeed being dropped before the CoreData model gets hold of it for persistence

2 Likes

Already fixed. Way to go Bear team! :smiley: :+1:

1 Like

Ha, I was just about to post about the update. You beat me by a minute!

1 Like