Renamed Vikunja tasks are rewritten on the page (closes #79) #80

Manually merged
jfro merged 2 commits from feature/79-rename-rewrite into main 2026-11-12 01:21:44 +00:00
Owner

Closes #79 (D70: renamed Vikunja tasks are rewritten on the page).

Depends on #78. The base is feature/77-seed-on-map so this diff is only #79. Once #78 merges I'll rebase onto main and move the base to main, keeping the history linear.

What it does

  • app_title (new column on todo_items): the task's title as last seen from the app. It's set on create from the page, on seed/link, on adopt, and on the first poll that lists the task.
  • Poll: an open task whose title (normalized) moved off app_title gets its old line struck and the new title written on the next free row. The old line becomes its own :deleted row with no task, pending :strike, and keeps the line's marks. That way the next read takes his old writing as that row instead of a new task. The task keeps its row id and task id; the row gets the new text, pending :add.
  • Not a rename: a title we haven't seen before (it's only recorded); a title equal to the row's text; the page's text being read differently. Page edits are never sent to the app as renames, so there's no echo loop.
  • A done task isn't rewritten. Renamed and then reopened, it is.
  • A task whose line isn't written yet only gets the new text, so two renames before a write give the latest title.
  • The panel's "Last check of the app" now counts renamed.
  • docs/todo-sync.md: new paragraph "Renamed in the app".

Tests (poll_worker_test, "renamed in the app")

  • His line gets struck and the new title is written on row 2. It's the same item id and task, the strike and the line are in our layer, and a second poll writes nothing.
  • The next read of the page creates nothing and deletes nothing: the struck row stays, and the renamed task stays open.
  • An unseen title is only recorded, and a misread line is left alone.
  • A done task isn't rewritten, but renamed and reopened, it is.
  • Renamed while its line is waiting (tablet busy), then renamed again: only the latest title gets written, with no struck row.

mix precommit: 1360 tests pass.

Screenshots (390px and desktop) of the panel's renamed count will be added at the head before this is called ready.

Closes #79 (D70: renamed Vikunja tasks are rewritten on the page). **Depends on #78.** The base is `feature/77-seed-on-map` so this diff is only #79. Once #78 merges I'll rebase onto main and move the base to main, keeping the history linear. ## What it does - **`app_title`** (new column on `todo_items`): the task's title as last seen from the app. It's set on create from the page, on seed/link, on adopt, and on the first poll that lists the task. - **Poll:** an open task whose title (normalized) moved off `app_title` gets its old line struck and the new title written on the next free row. The old line becomes its own `:deleted` row with no task, pending `:strike`, and keeps the line's marks. That way the next read takes his old writing as that row instead of a new task. The task keeps its row id and task id; the row gets the new text, pending `:add`. - **Not a rename:** a title we haven't seen before (it's only recorded); a title equal to the row's text; the page's text being read differently. Page edits are never sent to the app as renames, so there's no echo loop. - A **done** task isn't rewritten. Renamed and then reopened, it is. - A task whose line **isn't written yet** only gets the new text, so two renames before a write give the latest title. - The panel's "Last check of the app" now counts `renamed`. - `docs/todo-sync.md`: new paragraph "Renamed in the app". ## Tests (poll_worker_test, "renamed in the app") - His line gets struck and the new title is written on row 2. It's the same item id and task, the strike and the line are in our layer, and a second poll writes nothing. - The next read of the page creates nothing and deletes nothing: the struck row stays, and the renamed task stays open. - An unseen title is only recorded, and a misread line is left alone. - A done task isn't rewritten, but renamed and reopened, it is. - Renamed while its line is waiting (tablet busy), then renamed again: only the latest title gets written, with no struck row. `mix precommit`: 1360 tests pass. Screenshots (390px and desktop) of the panel's `renamed` count will be added at the head before this is called ready.
Each item keeps app_title, the task's title as last seen from the app;
a poll listing an open task whose title moved off it strikes the old line
(a :deleted row keeping its marks) and writes the new title (pending :add)
for the same task. Unseen titles are only recorded, and a misread of his
line is no rename. Done tasks aren't rewritten until reopened; an unwritten
line only gets the new text.
jfro changed target branch from feature/77-seed-on-map to main 2026-11-12 01:01:50 +00:00
jfro force-pushed feature/79-rename-rewrite from 9e3b8cb84b
Some checks failed
CI / test (pull_request) Failing after 1m12s
to 02f05a8068
All checks were successful
CI / test (pull_request) Successful in 1m45s
2026-11-12 01:07:57 +00:00
Compare
jfro manually merged commit 239391fcba into main 2026-11-12 01:21:44 +00:00
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
jfro/rm-analyzer!80
No description provided.