What problem does it solve?
This Skill helps you diagnose and resolve production-breaking errors caused by incorrect Document Controller hook usage in Frappe, including naming failures, validation loops, missing lifecycle logic, permission/query issues, and NestedSet or controller class override conflicts.
Core Features & Use Cases
- Lifecycle-phase error diagnosis: Map a failing controller behavior to the correct hook phase (naming, validation/save, submit/cancel, and permission/get_list) and identify the most likely root cause.
- Production-safe fixes for common controller mistakes: Prevent autoname failures, avoid recursion from self.save() in hooks, ensure submit validation happens in before_submit, use db_set for on_update changes, and guarantee super() is called in overrides.
- Guardrails for advanced edge cases: Handle extend_doctype_class conflicts (v16+), permission_query_conditions SQL errors and injection risks, NestedSet circular references, and recursion via flags for cross-document updates.
Quick Start
Use the frappe-errors-controllers skill to analyze why a specific controller hook is failing and request a corrected hook implementation and naming/permission fix for your Frappe version (v14, v15, or v16).