Skip to content

Comment/Comments tag's "Created At" and "Updated At" reset to 0 after enable sync #1040

Open

Description

@Track3

Search first

  • I searched and no similar issues were found

What Happened?

After enabling sync and re-downloading from the sync server, the "Created At" and "Updated At" timestamps of the Comment/Comments tag are reset to 0. See the reproduction steps below.

Reproduce the Bug

  1. Go to "All graphs" and create a new graph.
  2. Enable Logseq Sync. cmd+k search "tag", go to the #Tag page, noticed the Comment and Comments tag all has the correct creation and last modified time.
  3. In "All graphs" page, select "Delete local graph" from the three dot menu, then re-download it from the sync server.
  4. Go to the #Tag page again, the creation and last modified time for Comment and Comments tag all reset to 0.

Expected Behavior

The creation and last modified time should remain unchanged.

Screenshots

Image

Files

No response

Browser, Desktop or Mobile Platform Information

Windows 11, 2.0.1-alpha+nightly.20260728, commit 9a11243.
Also can reproduce on test.logseq.com.
Uses self-hosted sync server.

Additional Context

No response

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

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

Activity

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

    @yuxi-liu-wired

    The cause is a timestamp constant of 0 in the sync repair that creates the built-in Comment/Comments classes (src/main/frontend/worker/db_core.cljs). logseq/logseq#13899 makes new repairs use the day that repair was introduced instead of the epoch, with a test. Graphs that already got the 0 timestamps keep them: rewriting those needs a one-time repair or migration, which is a maintainer's call.

  2. yuxi-liu-wired commented on Oct 28, 2026

    @yuxi-liu-wired

    An update to the note above: the timestamp change is no longer in logseq/logseq#13899. The repair that creates these two classes is synced under one fixed transaction id, so changing the constant would have clients of different versions send different timestamps under the same id. The cause stays as described (built-in-sync-repair-timestamp is 0 in src/main/frontend/worker/db_core.cljs), but the fix touches sync convergence and graphs that already carry the 0, so it is a maintainer's call.

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