windmill-labs/windmill · error · UnresolvableScriptContentFileError
No script file found next to ${filePath} — a script cannot b
Error message
No script file found next to ${filePath} — a script cannot be deployed from its metadata alone. Add the matching script file (e.g. ${toCandidate('.ts')} or ${toCandidate('.py')}) or remove ${filePath}. What it means
Error "No script file found next to ${filePath} — a script cannot be deployed from its metadata alone. Add the matching script file (e.g. ${toCandidate('.ts')} or ${toCandidate('.py')}) or remove ${filePath}." thrown in windmill-labs/windmill.
Source
Thrown at cli/src/commands/script/script.ts:1201
dbtCandidate.slice(0, -("__dbt/" + DBT_DESCRIPTOR_NAME).length),
);
const nonDbtCandidates = validCandidates.filter((c) => c !== dbtCandidate);
if (dbtProject && nonDbtCandidates.length > 0) {
throw dbtPathCollisionError(dbtProject, nonDbtCandidates.join(", "));
}
if (validCandidates.length > 1) {
throw new UnresolvableScriptContentFileError(
`Multiple script files found next to ${filePath}: ${validCandidates.join(", ")} — ` +
`cannot tell which one the metadata belongs to. Keep exactly one.`
);
}
if (validCandidates.length < 1) {
// Resolving to the absent descriptor keeps one content path for every
// caller; reading it yields an empty descriptor.
if (dbtProject) {
return dbtCandidate;
}
throw new UnresolvableScriptContentFileError(
`No script file found next to ${filePath} — a script cannot be deployed from its metadata alone. ` +
`Add the matching script file (e.g. ${toCandidate(".ts")} or ${toCandidate(
".py"
)}) or remove ${filePath}.`
);
}
return validCandidates[0];
}
export function filePathExtensionFromContentType(
language: ScriptLanguage,
defaultTs: "bun" | "deno" | undefined
): string {
if (language === "python3") {
return ".py";
} else if (language === "nativets") {
return ".fetch.ts";
} else if (language === "bun") {View on GitHub (pinned to e474e8803c)
Solutions
- Add the matching script file next to the metadata, e.g. <name>.script.ts or <name>.script.py.
- Remove the orphan metadata file if the script no longer exists locally.
Defensive patterns
Strategy: fallback
When it happens
Trigger: Thrown at cli/src/commands/script/script.ts:1201 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of windmill-labs/windmill@e474e8803c (2026-09-03).
Data as JSON: /api/errors/7a1da8329c91b20f.
Report an issue: GitHub.