This document outlines the directory structure and development philosophy of the Orange Dev Tracker. To ensure stability during rapid iteration, the project follows a "Core vs. Lab" (Sandbox-to-Production) lifecycle.
This is where the logic lives. It is partitioned by stability:
code/core/: Production-ready data pipelines. Scripts here are expected to be stable and are used to rebuild the main dashboard.code/governance/: Logic for high-complexity domain data (BIPs, Mailing Lists). This is "Infrastructure" that supports both core and lab features.code/lib/: Shared Python utilities, constants, and logging handlers.
All data artifacts are partitioned to prevent experimental data from polluting production:
data/core/: Final.jsonand.parquetfiles used by the root dashboard.data/governance/: Intermediate and final governance artifacts.data/lab/: Data generated specifically for experimental pages.data/cache/: API caches, lookup files (aliases, sponsors), and persistent metadata.
This is the area for rapid UI and functional prototyping. Each sub-folder is a "Feature Bundle":
lab/gloria/: Experimental Maintainer Spotlight. Contains its ownstory.htmlandprep.py.lab/bips/: Early-stage Governance Dashboard.
One-off research scripts, debug tools, and insight generators that are not part of the monthly production cron job.
Only stable, deployment-ready HTML files live in the root (e.g., story.html, index.html).
New features should follow this lifecycle to ensure the repository remains clean and the main dashboard stays functional:
- Exploration: Create a script in
analysis/to test a hypothesis or extract a new dataset. - Sandbox (The Lab):
- Create a folder in
lab/feature_name/. - Develop the UI (
story.html) and local data prep logic (prep.py) there. - Write experimental data to
data/lab/.
- Create a folder in
- Refinement: Iterate until the feature is stable and visually polished.
- Graduation (Production):
- Move the HTML from
lab/.../story.htmlto root (e.g.,feature.html). - Move logic from
lab/.../prep.pytocode/core/. - Update data outputs to write to
data/core/. - Integrate the graduated script into the main
rebuild.py.
- Move the HTML from
- Respect the Prefix: Frontend JS must use
DATA_PATH_PREFIX(defined injs/utils.js) for allfetchcalls to ensure they work at any directory depth. - No Root Pollution: Do not add new
.htmlfiles to the root until they have been validated in thelab/. - Data Isolation: Never write experimental data directly to
data/core/. Usedata/lab/or specialized subdirectories.