Mapping a page writes the project's existing todos onto it #78
Loading…
Reference in a new issue
No description provided.
Delete branch "feature/77-seed-on-map"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Closes #77
Linking a page to a Vikunja project now brings the project's existing todos onto the page (Jeremy, Nov 11: "1:1 as possible"). Design in
docs/todo-sync.md→ Polling, "Seeding a newly mapped page".What happens on a new mapping
seeded_atnil and queues its poll.Todos.Seed.plan/3, pure)::add, written by the next poll onto free rows in the app's order. Done tasks aren't seeded (D69).:addrow) that a row matches is replaced by the row, so it isn't drawn twice.seeded_atandpolled_until(the listing's latestupdated) are set, and the poll is queued to write.changes_since/3gets an empty seed.page full, N not written.Sync panel: the first read shows
N linked, N seeded. A seeded task whose line isn't written yet shows–for its row and saysnot on the page yet(it used to show row 1 andwritten on the tablet).Tests
seed_test.exs(pure): empty page, title match, duplicate titles, open before done, known and blank tasks, unwritten:addreplaced.sync_worker_test.exs: real first read (link, create, seed, skip done,polled_until, poll queued, no second seed); ticks on both sides; a failed listing creates nothing; map queues the poll; same-project remap keepsseeded_at; another project re-seeds.poll_worker_test.exs: an unseeded page waits and queues its read; the page-full message.todo_sync_live_test.exs: panel counts and the unwritten row.mix precommit: 1353 tests pass. Thelive_vikunjasuite passes against Vikunja 2.8.0.Browser check at
5c4e7fa(dev, real local Vikunja 2.8.0)Page: our template, with handwriting "Home", "Buy milk" and "Call the bank". Project: Buy milk, Water the plants, Book the dentist, Pay rent (all open) and Renew passport (done). The first read ran for real against Vikunja. Buy milk was linked to the existing task, Call the bank was created, three open tasks were queued, and Renew passport was skipped. There's no tablet cloud in dev, so the write was drawn locally with the same
PageMarksplan WriteBack uses.After the first read (390 / desktop):
After the write (390 / desktop):
The page in the viewer after the write (390 / desktop):
Not in this PR
.rmyet) can't be seeded until something is written on it. The poll saysthe page has no strokes yet.