Skip to content

"Invalid data writing to db!" error when trying to delete a new choice from the #Task "Status" property #729

@Jtro84

Description

@Jtro84

Search first

  • I searched and no similar issues were found

What Happened?

If I add a new choice for the #Task built-in "Status" property and change the status of a task (tagged block) to this new choice, then trying to delete the new choice from the "Status" property in the #Task tag systematically results in an "Invalid data writing to db!" error.

This is quite annoying since I did not found a way to fix it and it can easily mess up the #Task statuses.

Reproduce the Bug

  1. Go the the #Task tag
  2. Click on the "Status" property
  3. Click on "Available choices"
  4. Add a new choice and click on "Save"
Image
  1. Scroll down and observe that the new choice appears in the "Linked references" with the "Status" property... (which seems normal as this is the case as well with non-built-in properties which don't have the issue - see Additional Context - but I suspected at first that it could have a link with the issue...)
Image
  1. Go to the Journal page, add a new block and tag it with #Task
  2. Click on the task's status and change it to the new choice
Image
  1. (Optional) Click again on the status and click on "No status" or on another built-in choice to remove the new choice from the task
  2. Click on the #Task tag and go to the "Available choices of the "Status" property again
  3. Click on the three dots to the right of the new choice, then "Delete"
  4. See error "Invalid data writing to db!"

Expected Behavior

There is no error and the new choice is deleted from the "Available choices" in the "Status" property, for the tag and the tagged blocks.

Files

No response

Browser, Desktop or Mobile Platform Information

Windows, Browser (Chrome) on test.loqseq.com

Additional Context

Notice that it seems specific to the built-in "Status" property as I cannot reproduce it with a custom property : if I add a new Text property to #Task (or to another tag) and add a new choice to it, I can delete the choice afterwards without issue even if this choice is still set on a tagged block.

Are you willing to submit a PR? If you know how to fix the bug.

  • I'm willing to submit a PR (Thank you!)

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions