You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
No guard against deleting a schema with extended_by children — descendants silently lose all inherited fields/relationships #2889
Surfaced by a codebase scan focused on the extends-chain/ADR-078 bug class. This may be an explicitly out-of-scope/accepted gap for ADR-078 rather than a bug — filed as a decision item for a maintainer to weigh in on, not prescribed for auto-implementation.
Problem
delete_node (packages/core/src/services/node_service/crud.rs:1882+) has no schema-specific guard for a schema node that has extended_by children or live subtype instances. Every chain-walking resolver in the codebase (resolve_field_owners schema.rs:552-557, resolve_relationships schema.rs:632-636, resolve_effective_fields schema/mod.rs:780-786, resolve_declared_relationship relationship.rs:493-495) treats a missing mid-chain schema the same way: continue past it silently.
Consequence: deleting the task schema while issue extends task nodes exist makes every issue instance silently lose all inherited fields and relationships, with no error raised anywhere in the delete path or afterward.
There IS an existing precedent for this kind of delete-side dependency guard: plays_referencing_schema (packages/core/src/playbook/engine.rs:957) already blocks/warns on deleting a schema that Plays reference.
Suggested approach
Not prescribed — needs a maintainer decision on the right UX (block the delete outright if descendants exist? cascade-delete descendants? require an explicit --force?), following the same pattern plays_referencing_schema already established for a different dependency kind (Plays, not extends children).
Non-goals
Not proposing an implementation — this needs product/architecture input on intended behavior before any code changes.
Activity
malibio commentedon Sep 26, 2026
Frontend baseline: 5405 passed, 1 failed (architecture-benchmarks perf threshold — known machine-load flake). Decision: refuse delete_node on a schema that other schemas extend (typed error naming children), and refuse deleting core schemas.
Refuse deleting an extended or core schema (closes #2889)