Skip to content

Logs: each write to notes, folders and spaces says what it changed #1923

Done

Description

@vmillet-dev

Context — An action is logged by its name, a call to the core by its name, duration and outcome (#1843, #1844): neither says which note, folder or space it touched, nor what changed. Played on a session, a closing writes #8 Notes::Editor::Save then #9 Notes::Editor::Save, each a notes::update, and nothing tells whether the two wrote the same thing. Asked by the owner: a line that says what was written, with its id, in every build.

Change — Each service function of the core that writes notes, tags, fields, attachments, folders or spaces logs one line at info once it has written: what it did, the ids it touched, the kind of note, the parts that changed, and what was written through Sensitive — whole in a development build, its length in a release.

INFO [db] engine::notes: updated 3f2a91c0 (Note): content « sudo systemctl restart api »
INFO [db] engine::notes: duplicated 3f2a91c0 into 9b1c44e2 (Note) « Restart the API (copy) »
INFO [db] engine::notes: 1 note to the trash: 9b1c44e2

To do

  1. One line a write in notes.rs, folders.rs, spaces.rs, attachments.rs: created, updated (the parts of the patch that are set), converted, duplicated, deleted, restored, purged, moved, filed, tagged, untagged, pinned, prioritised, fields kept or filled, revision restored, trash emptied; folders and spaces created, renamed, moved, deleted. Reads stay at the call's debug line.
  2. Ids written whole; a list of ids past ten says how many more.
  3. The wiki's logs page: what the core says, beside the actions and the calls.
  4. One pull request into dev/1.3.3, after the one for Sensitive.

Tests


Generated by Claude Code

Activity

  1. added
    refactor
    on Dec 6, 2026
  2. added a commit that references this issue on Dec 6, 2026
    86fa9b1
  3. vmillet-dev commented on Dec 6, 2026

    @vmillet-dev
    OwnerAuthor

    Fixed by #1926, merged into dev/1.3.3.


    Generated by Claude Code

  4. added a commit that references this issue on Dec 6, 2026
    77e8520
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

    refactor

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions