Parent
Sub-issue of #9515 (Rebuild Video.availableLanguages as one cycle-safe, recursively-correct source of truth).
What to build
Removing a video from a container's children correctly drops a language it uniquely provided from that container's availableLanguages. Today, removing a child fires reconciliation for its variants, but by the time that reconciliation runs the parent-child relation is already severed, so the old parent is structurally unreachable through the normal path and the stale language sticks forever.
videoUpdate's child-removal handling is changed to explicitly recompute the old parent (using the engine from #9517) after the relation is severed, and cascade that recompute upward to the root.
Acceptance criteria
Blocked by
Parent
Sub-issue of #9515 (Rebuild Video.availableLanguages as one cycle-safe, recursively-correct source of truth).
What to build
Removing a video from a container's children correctly drops a language it uniquely provided from that container's
availableLanguages. Today, removing a child fires reconciliation for its variants, but by the time that reconciliation runs the parent-child relation is already severed, so the old parent is structurally unreachable through the normal path and the stale language sticks forever.videoUpdate's child-removal handling is changed to explicitly recompute the old parent (using the engine from #9517) after the relation is severed, and cascade that recompute upward to the root.Acceptance criteria
childIdsresults in the container'savailableLanguagesno longer including X.availableLanguagesunchanged.availableLanguagesalso updates when appropriate).childIdsin the same mutation continues to work as before (no regression on the already-correct add path).Blocked by