Skip to content

Feat/budgets - #749

Merged
sadespresso merged 2 commits into
internalfrom
feat/budgets
Jul 25, 2026
Merged

Feat/budgets#749
sadespresso merged 2 commits into
internalfrom
feat/budgets

Conversation

@sadespresso

Copy link
Copy Markdown
Collaborator

No description provided.

A pinned widget stored the ObjectBox id of the budget it was pinned to.
Budget.toJson omits that id, so restoring a backup reinserts every budget
and ObjectBox hands out fresh ones -- "Eating out" comes back as a
different number, and that number may already belong to something else. A
widget pinned before the restore would then render a different budget's
name and progress, confidently, with no sign it had changed subject.

The payload now carries Budget.uuid alongside the id, and everything that
*persists* a choice keys on it: the iOS AppEntity id (Int -> String, so
the sentinel for "any budget that needs attention" is now "automatic"
rather than -1) and the Android preference (budgetId_ -> budgetUuid_,
where an absent key means auto, so no sentinel value is needed).

The id stays in the payload and still backs the deep link -- that URL is
built from the payload being rendered, so its id is current by
construction. The gap that leaves, a tap landing between a restore and
the re-sync, is documented at the call site rather than papered over.

payloadVersion goes to 2. Both extensions gate on it exactly, so a v1
payload still sitting in shared storage renders the placeholder until the
app next syncs, rather than a budget list nothing can be pinned to.

No migration for configurations written under the old keying: these
widgets have never shipped, so the only devices holding one are ours.

Claude-Session: https://claude.ai/code/session_01E2LauLnkDjeYh4veiEQ9jk
@sadespresso
sadespresso merged commit 4105d69 into internal Jul 25, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant