JuliusBrussee/caveman · error
${label}:${lineNo}: row must start with an inline "provider"
Error message
${label}:${lineNo}: row must start with an inline "provider" value What it means
Thrown by the catalog parser when a top-level "- ..." row's first key has no inline value — specifically when the row does not start with "provider: <value>". Every row must open with an inline provider value because downstream generation keys rows by provider name; a valueless opening key ("- provider:" with nothing after the colon) leaves the row unidentifiable.
Source
Thrown at scripts/generate-agent-catalog.mjs:66
const rows = [];
let row = null;
let blockKey = null;
const lines = text.split("\n");
for (let index = 0; index < lines.length; index++) {
const line = lines[index].replace(/\s+$/, "");
const lineNo = index + 1;
if (line === "" || /^ *#/.test(line)) continue;
const shape = /^( *)(- )?(.*)$/.exec(line);
const indent = shape[1].length;
const dash = shape[2] !== undefined;
const rest = shape[3];
if (indent === 0) {
if (!dash) throw new Error(`${label}:${lineNo}: expected a top-level "- provider: ..." row`);
row = {};
rows.push(row);
blockKey = null;
const entry = splitKeyValue(rest, label, lineNo);
if (entry.value === undefined) throw new Error(`${label}:${lineNo}: row must start with an inline "provider" value`);
row[entry.key] = entry.value;
continue;
}
if (row === null) throw new Error(`${label}:${lineNo}: indented line before any row`);
if (indent === 2) {
if (dash) throw new Error(`${label}:${lineNo}: unexpected sequence item at row level`);
const entry = splitKeyValue(rest, label, lineNo);
if (Object.prototype.hasOwnProperty.call(row, entry.key)) {
throw new Error(`${label}:${lineNo}: duplicate key "${entry.key}"`);
}
if (entry.value === undefined) {
blockKey = entry.key;
row[entry.key] = undefined;
} else {
blockKey = null;
row[entry.key] = entry.value;
}
continue;View on GitHub (pinned to 27d5a3981a)
Solutions
- Put the provider value inline on the dash line: "- provider: anthropic".
- If the row started with a different key, reorder so provider comes first with its value, then add other keys as indented "key: value" lines below.
Example fix
# before - provider: anthropic # after - provider: anthropic
Defensive patterns
Strategy: validation
Validate before calling
function rowsStartWithInlineProvider(text) {
return text.split("\n").every((line) => {
if (/^- /.test(line)) return /^- provider: \S/.test(line.replace(/\s+$/, ""));
return true;
});
} Try / catch
try {
parseCatalog(text);
} catch (err) {
if (/row must start with an inline/.test(err.message)) {
// fix the named line to "- provider: <value>" and re-run
} else throw err;
} Prevention
- Copy an existing provider row as the template for new rows.
- Never split the provider name onto its own line.
When it happens
Trigger: Writing "- provider:" with the value intended on following indented lines, or starting a row with a different key entirely ("- name: foo") — splitKeyValue returns value undefined for a key with no " value" suffix, and only provider-with-inline-value is accepted as the row opener.
Common situations: Authoring the catalog for the first time from an example that put the provider on the next line; trimming what looked like a redundant value; a row starting with a metadata key instead of provider.
Related errors
- ${label}:${lineNo}: expected a top-level "- provider: ..." r
- ${label}:${lineNo}: indented line before any row
- ${label}:${lineNo}: unexpected sequence item at row level
- ${label}:${lineNo}: duplicate key "${entry.key}"
- ${label}:${lineNo}: nested line without an open block
AI-assisted analysis of JuliusBrussee/caveman@27d5a3981a (2026-08-15).
Data as JSON: /api/errors/5c82e653f804566c.
Report an issue: GitHub.