Day 021 / Frappe / ERPNext Utilities

Bench Doctor Lite

View source ↗Scroll to explore ↓
Bench Doctor Lite project cover
/ Overview

A read-only Python CLI that checks a Frappe bench’s structure and configuration health without exposing configuration values.

NameBench Doctor Lite

ClientIndependent daily build

IndustriesDeveloper and operations tooling

DateDay 021 · September 20, 2026

/ Challenge

A Frappe bench can look intact while expected directories, app registries, JSON configuration or scheduler state contain simple problems. Ordinary troubleshooting can also expose passwords when full configuration files are printed.

/ Provided services

Clear thinking.
Practical delivery.

01

Bench structure checks

Checks apps and sites directories, Procfile, the app registry and discovered site configuration files.

02

Privacy-conscious diagnostics

Reports key counts and health statuses while deliberately omitting database passwords and every other configuration value.

03

Automation-ready reporting

Produces stable text or JSON output with distinct exit codes for clean checks, findings and invalid input.

Bench Doctor Lite feature visual
/ Solution

Bench Doctor Lite performs a read-only structural inspection of a chosen bench directory. It checks expected folders and files, validates common and per-site JSON, identifies a paused scheduler flag, counts local apps and reports only statuses, paths and key counts—not configuration values.

/ Impact

Read-only bench inspection

Structural and JSON checks

Paused-scheduler warning

Configuration values omitted

Nine passing standard-library tests

/ Tech stack

Python standard library

Pathlib, json, argparse and dataclasses provide the full read-only diagnostic without external packages.

Frappe bench conventions

The checks model common bench folders, app registries, common configuration and per-site configuration files.

Unittest

Nine temporary-fixture tests cover missing structure, invalid JSON, empty registries, scheduler state, value omission and exit codes.

Next project

Config Diff

View case study ↗