Skip to content

Undo of deleting a property removes it from the tags that had it as a tag property #1311

Open
logseq/logseq
#13786

Description

@yuxi-liu-wired

Steps

  1. Create a number property "rating".
  2. Add "rating" as a tag property of the tag "Topic".
  3. Delete the property "rating".
  4. Press Ctrl+Z.

Expected

"rating" is back and is again a tag property of "Topic".

Actual

"rating" is back, but "Topic" no longer lists it as a tag property.

Notes

The tag's list of properties refers to the property entity, so deleting the property also removes it from that list. The undo restores the property but not the tag's reference to it. Same family as #1304 and #1305: the undo of a delete does not restore what the delete changed on other nodes.

Found with a probe of undo on single operations, replayed on upstream master 16c4ed1a0: after the undo, the datom [Topic :logseq.property.class/properties rating] is missing.

Activity

  1. yuxi-liu-wired commented on Oct 27, 2026

    @yuxi-liu-wired
    Author

    Fixed on graphs without sync by logseq/logseq#13786. Undo of deleting a property now replays the delete's recorded datoms, so the property is a tag property of Topic again. local-graph-undo-of-property-delete-restores-tag-property-test pins it. A synced graph still undoes through the old inverse op, which this PR does not change.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions