NEW in v2.0: Parse all build errors at once, fix in batches, reduce compile cycles.
AI agents fix one error at a time while the compiler reports ALL errors. This wastes:
- CPU cycles (recompiling after each single fix)
- Time (waiting for build to complete repeatedly)
- Context (AI loses track of related errors)
- Run build ONCE and capture ALL errors
- Parse errors into categorized JSON/Markdown
- Fix multiple errors before recompiling
- Only rebuild after completing a category or fixing 5+ errors
# Run build and parse all errors
.\batch_error_system\parse_build_errors.ps1 -RunBuild
# Or use the batch file
.\batch_error_system\Parse-Build-Errors.bat| File | Purpose |
|---|---|
.ralph/build_errors.json |
Structured JSON for automation |
.ralph/build_errors.md |
Human-readable markdown table |
.ralph/build_output_cache.txt |
Raw build output |
Errors are automatically categorized and prioritized:
| Priority | Category | Description | Fix First? |
|---|---|---|---|
| 1 | missing_include |
Missing headers | ✅ YES |
| 2 | duplicate_definition |
Multiple definitions | ✅ YES |
| 3 | namespace_error |
Namespace issues | ✅ YES |
| 4 | missing_symbol |
Undefined symbols | May auto-resolve |
| 5 | type_mismatch |
Type conversion | No |
| 6 | syntax_error |
Syntax issues | No |
| 7 | template_error |
Template issues | Complex |
| 8 | linker_error |
Linker issues | Often symptom |
| Code | Meaning | Category |
|---|---|---|
| C1083 | Cannot open include file | missing_include |
| C2065 | Undeclared identifier | missing_symbol |
| C2084 | Duplicate definition | duplicate_definition |
| C2143 | Syntax error | syntax_error |
| C2440 | Cannot convert | type_mismatch |
| C2653 | Not a class/namespace | namespace_error |
| LNK2001 | Unresolved external | linker_error |
| LNK2019 | Unresolved external symbol | linker_error |
# 1. Run build and parse errors
.\parse_build_errors.ps1 -RunBuild
# 2. Read the error report
cat .ralph\build_errors.md
# 3. Route errors to appropriate fixer agents (see table below)
# 4. Wait for fix reports
# 5. Rebuild
.\parse_build_errors.ps1 -RunBuild
# 6. Repeat until clean## Fix Report
- File: <path>
- Line: <number>
- Error Code: <C2143, etc.>
- Fix Applied: <description>
- Status: FIXED| Error Pattern | Assigned To |
|---|---|
bind_*.cpp, pybind11 |
debug-agent |
physics/*.cpp, Bullet* |
agent5-physics |
vr/*.cpp, OpenXR* |
agent4-vr |
*.py syntax/import |
agent9-python |
CMakeLists.txt |
agent1-build |
| All other C++ | debug-agent |
The parser identifies:
- Root Causes: Errors that should be fixed first (often clears cascading errors)
- Cascade Errors: Errors that may auto-resolve after root causes are fixed
Example: A missing include (C1083) often causes 10+ "undeclared identifier" (C2065) errors downstream.
{
"Timestamp": "2026-01-21T04:00:00Z",
"TotalErrors": 42,
"RootCauseCount": 8,
"CascadeCount": 34,
"ByCategory": {
"missing_include": { "Count": 3, "ErrorIds": [1, 2, 3] },
"missing_symbol": { "Count": 15, "ErrorIds": [...] }
},
"ByFile": {
"Renderer.cpp": { "Count": 5, "ErrorIds": [1, 4, 7, 9, 12] }
},
"Errors": [
{
"Id": 1,
"File": "C:\\path\\to\\file.cpp",
"Line": 42,
"Column": 10,
"Code": "C2065",
"Message": "'foo': undeclared identifier",
"Category": "missing_symbol",
"Fixed": false
}
],
"RootCauses": [...],
"Cascades": [...],
"FixPriority": ["missing_include", "duplicate_definition", ...]
}- Fix by category - Complete all
missing_includebefore moving on - Fix root causes first - Check the RootCauses list
- Group by file - Fix all errors in one file together
- Minimum batch size - Fix at least 5 errors before recompiling
- Update progress - Mark errors as fixed in the markdown table