Worksheet: Cord to-do duplicates

Scott reported that every task made from the calendar shows up twice in the Cord to-do list. The cause is that the sync job runs once on the phone and once on the server, and neither checks what the other already created.

Proposed fix

Give every task a stable id built from the calendar event and the day. Before saving, look for that id. If it exists, update it instead of adding a new one.

Risk

Tasks Scott already deleted could come back. We avoid that by keeping a list of dismissed ids for 30 days.

Next step

Build on staging, run it against Scott's real calendar, then ask for a go.