feat(chores): chore dependencies / unlocks (FEAT-1)#603
Merged
Conversation
A chore can now depend on other chores: it stays unavailable for a child until every chore in its depends_on has an approved completion by that same child today. - models: Chore.depends_on (+ from_dict/to_dict) - coord_chores.is_chore_available_for_child: dependency gate (so it flows through the availability matrix, the cards, get_due_chores and the todo platform automatically) - websocket: depends_on in the add/update schema + editable-fields set (applied generically); async_add_chore param - sensor: depends_on exposed in _build_chores_list so the editor shows the current selection - panel: 'Depends on' multi-select in the chore editor (mirrors the assigned_to chip picker), wired through the draft + save - i18n: panel.chore_depends_label/_hint in all 8 locales Tests: 4 gating cases (unmet blocks, met unlocks, unapproved doesn't unlock, other-child doesn't unlock). Verified live on ha-dev: B (depends on A) was unavailable until A was approved for the child, then became available; panel picker + locale labels served live.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
FEAT-1 — chore dependencies / unlocks
A chore can now depend on other chores: it stays unavailable for a child until every chore in its
depends_onhas an approved completion by that same child today. (e.g. "Get dressed" only unlocks after "Make bed" is approved.)Surfaces
Chore.depends_on(+ from_dict/to_dict)is_chore_available_for_child, so it flows through the availability matrix, the cards,get_due_chores_for_childand the new todo platform automaticallydepends_onin the add/update schema +_CHORE_EDITABLE_FIELDS(applied generically);async_add_choreparamdepends_onexposed in_build_chores_listso the editor pre-selects current depsassigned_tochip picker), wired through the draft + savepanel.chore_depends_label/_hintin all 8 localesTesting
False) until A was approved for the child, thenTrue; picker + locale labels confirmed served live. Test chores cleaned up.From AUDIT_REPORT.md §5 (FEAT-1).