Turborepo "Could not find the following tasks in project" in CI
Turborepo could not match the task name you ran to any task in turbo.json or any matching package.json script. The task is misspelled, not declared, or not present in the filtered packages.
What this error means
A turbo run X step fails with "error preparing engine: Could not find the following tasks in project: X" before any package runs.
x error preparing engine: Could not find the following tasks in project: typecheckCommon causes
The task is not in turbo.json or any package.json
No tasks entry in turbo.json and no package script matches the name, so Turbo has nothing to schedule.
The filter excludes every package that defines it
The task exists, but the --filter narrows to packages that do not declare it, so Turbo finds none to run.
How to fix it
Declare the task and add a script
- Add the task to
turbo.jsonundertasks. - Ensure at least one package has a
package.jsonscript with that name. - Re-run, or widen the
--filterso a matching package is included.
{
"tasks": {
"typecheck": { "dependsOn": ["^build"] }
}
}Add the script to the package
Give the package a matching script so Turbo has something to invoke.
{
"scripts": { "typecheck": "tsc --noEmit" }
}How to prevent it
- Declare every task you run in
turbo.json. - Keep package scripts aligned with task names.
- Check that your
--filterstill includes packages defining the task.