What problem does it solve?
This Skill helps you diagnose and resolve the most common, production-breaking errors in Frappe Server Scripts—especially sandbox ImportError/NameError issues, misconfigured script type/event problems, permission failures, missing scheduler commits, and API scripts returning empty or incorrect responses.
Core Features & Use Cases
- Server Script sandbox error mapping: Translates common sandbox error messages into precise causes and safe fixes, focusing on restricted imports, blocked try/except/raise, and restricted builtins.
- Correct script type and event troubleshooting: Guides you to verify Document Event vs API vs Scheduler context so the right variables are available (or not) and the script actually runs as intended.
- Production guardrails for scheduler and API scripts: Ensures scheduler changes persist via required commit behavior, and ensures API scripts always populate frappe.response["message"] with the correct structure.
- Security hardening: Prevents SQL injection by requiring frappe.db.escape() (or safe query approaches) when user input affects SQL conditions.
Quick Start
Use the frappe-errors-serverscripts skill to debug your failing Server Script by pasting the exact error text and describing whether it is a Document Event, API script, or Scheduler script.