santifer/career-ops · warning
⚠️ not found
Error message
⚠️ ${label} not found: ${path} What it means
lib/golden-budget-analysis.mjs's readFile() helper checks existsSync() before reading a context file; when the file is absent it warns with the label and path and returns a placeholder string '[<label> not found]' so the analysis can proceed. The resulting analysis is computed against a missing input and its numbers will be misleading.
Solutions
- Restore the missing file at the printed path (e.g. checkout modes/_shared.md from the upstream repo)
- Run the script from the repository root so ROOT resolves correctly
- Check whether a market modes_dir layout moved the file and pass the right path
- Treat any output produced with '[not found]' placeholders as invalid and re-run after the file exists
Example fix
// before $ node lib/golden-budget-analysis.mjs # run from /tmp → modes/_shared.md missing // after $ cd /path/to/career-ops && node lib/golden-budget-analysis.mjs
Defensive patterns
Strategy: validation
Validate before calling
const required = ['modes/_shared.md', 'cv.md', 'config/profile.yml'];
for (const f of required) {
if (!existsSync(join(repoRoot, f))) throw new Error('Missing required context file: ' + f);
} Prevention
- Run analysis scripts only from the repository root
- Check `git status` / fresh-clone state before running golden-budget analysis
- Never trust analysis output containing '[not found]' placeholder sections — re-run after restoring files
When it happens
Trigger: Running the golden-budget analysis from a working directory or checkout where a required context file (e.g. modes/_shared.md via join(ROOT, 'modes', '_shared.md')) does not exist — fresh clone without the file, wrong ROOT resolution, or a renamed/deleted mode file.
Common situations: Running the script from a different repo root, a sparse/partial checkout, or after renaming modes/_shared.md; running against a fork that dropped some mode files.
Understand the failure class
Background: "File not found" and ENOENT errors: why libraries can't find a file that should exist — this error's family across 50 libraries.
Related errors
- ⚠️ not found at
- Application Answers section has
- requires a path
- config/profile.yml not found: fill it in first
- ⚠️ Could not save report
AI-assisted analysis of santifer/career-ops@aac998c7ed (2026-09-16).
Data as JSON: /api/errors/0b7b730df0050f58.
Report an issue: GitHub.
Appendix: source
Thrown at lib/golden-budget-analysis.mjs:36
import { readFileSync, readdirSync, existsSync } from 'fs';
import { join, dirname } from 'path';
import { fileURLToPath } from 'url';
import { buildBudgetedPrompt, SECTION_PRIORITY } from './context-budget.mjs';
const ROOT = join(dirname(fileURLToPath(import.meta.url)), '..');
const GOLDEN_DIR = join(ROOT, 'evals', 'golden');
if (!existsSync(GOLDEN_DIR)) {
console.error('Golden directory not found:', GOLDEN_DIR);
process.exit(1);
}
// ---------------------------------------------------------------------------
// Load context files
// ---------------------------------------------------------------------------
function readFile(path, label) {
if (!existsSync(path)) {
console.warn(` ⚠️ ${label} not found: ${path}`);
return `[${label} not found]`;
}
return readFileSync(path, 'utf-8').trim();
}
const sharedContent = readFile(join(ROOT, 'modes', '_shared.md'), '_shared.md');
const ofertaContent = readFile(join(ROOT, 'modes', 'oferta.md'), 'oferta.md');
const p0Keys = Object.entries(SECTION_PRIORITY)
.filter(([, p]) => p === 0)
.map(([k]) => k);
// ---------------------------------------------------------------------------
// Synthetic CVs — a real cv.md is 500-3000 lines of markdown.
// ---------------------------------------------------------------------------
const CV_BLURB = [
'',
'### Head of AI — TechCorp (2022-Present)',View on GitHub (pinned to aac998c7ed)