Troubleshooting
FreshCommon Trigger.dev errors and how to fix them.
Development Issues
Task Not Appearing in Dashboard
Symptom: Task file created but not showing up in dashboard.
Causes & Fixes:
File is outside the
/triggerdirectory- Check
trigger.config.ts→dirssetting - Move file inside the configured trigger directory
- Check
Dev server not restarted after adding file
- Stop and restart
npx trigger.dev@latest dev
- Stop and restart
Export missing
- Make sure the task is exported:
export const myTask = task({...})
- Make sure the task is exported:
Syntax error in the file
- Check terminal output for TypeScript/parse errors
Retries Not Triggering
Symptom: Task fails but doesn't retry.
Fix: Your run function must throw an error to trigger retry. If you catch errors, Trigger.dev considers the run successful.
// WRONG — swallowed error, no retry
run: async (payload) => {
try {
await riskyOperation();
} catch (e) {
console.error(e); // Error eaten, no retry
}
}
// CORRECT — rethrow to trigger retry
run: async (payload) => {
try {
await riskyOperation();
} catch (e) {
console.error(e);
throw e; // Rethrow — triggers retry
}
}Version Mismatch Error
Symptom: Version mismatch detected or SDK version errors.
Fix: When running dev, accept the package update prompt:
? @trigger.dev/* packages are outdated. Update now? › YesOr manually update:
npm update @trigger.dev/sdk @trigger.dev/buildCLI Login Fails
Symptom: Login hangs or browser doesn't open.
Fix:
npx trigger.dev@latest logout
npx trigger.dev@latest loginIf using multiple profiles:
npx trigger.dev@latest login --profile productionDeployment Issues
"Failed to build project image: Error building image"
Cause: Remote build provider issue or code error.
Fixes:
Check the build log link in the error message
Try local build:
bashnpx trigger.dev@latest deploy --force-local-buildRequires Docker + Docker Buildx installed.
Dry run to see what's being built:
bashnpx trigger.dev@latest deploy --dry-runEnable verbose debug:
bashnpx trigger.dev@latest deploy --log-level debug
"No loader is configured for .node files"
Cause: Native Node.js addon package can't be bundled.
Fix: Add to build.external in trigger.config.ts:
import { defineConfig } from "@trigger.dev/sdk";
export default defineConfig({
project: "proj_xxx",
build: {
external: ["your-native-package"], // e.g., "sharp", "canvas"
},
});"Cannot find matching keyid" (Node v22 + corepack)
Cause: Incompatibility between Node.js v22 and corepack.
Fix Option A (recommended):
npm i -g corepack@latestFix Option B: Downgrade to Node.js 20 LTS.
"Deployment encountered an error"
Cause: Various — check the guidance below the error.
Fixes:
- Look for the link to build logs in the error output
- Join Trigger.dev Discord → Help forum
- Share your build URL privately (not publicly — logs may contain secrets)
Runtime Issues
Task Stuck / Never Completing
Symptom: Run shows "Executing" indefinitely.
Causes & Fixes:
- Infinite loop in code — add logging to track progress
- External API hanging — add timeouts to fetch calls:ts
const controller = new AbortController(); setTimeout(() => controller.abort(), 30000); // 30s timeout await fetch(url, { signal: controller.signal }); maxDurationexceeded — increase or remove it- Awaiting a cancelled child task — use
onCancelhook for cleanup
Batch Trigger Rate Limited
Symptom: BatchTriggerError with isRateLimited: true.
Fix:
import { BatchTriggerError } from "@trigger.dev/sdk";
try {
await myTask.batchTrigger(items);
} catch (error) {
if (error instanceof BatchTriggerError && error.isRateLimited) {
const waitMs = error.retryAfterMs ?? 10000;
await new Promise(r => setTimeout(r, waitMs));
// Retry...
}
}Large Payload Errors
Symptom: Payload too large or payload rejected.
Limits:
- Hard limit: 10MB
- Auto-S3 upload: above 512KB
- Task output: 100MB limit
Fix for very large payloads:
// Upload to S3 first, pass URL
const presignedUrl = await uploadToS3(largeData);
await myTask.trigger({ url: presignedUrl });Child Task triggerAndWait Stuck
Symptom: Parent hangs waiting for child that never completes.
Common causes:
Child task threw an error with no retries left — check child run in dashboard
Version mismatch — triggerAndWait locks child to parent version, ensure that version is still active
Using
Promise.all()withtriggerAndWait— don't do this:ts// WRONG const [r1, r2] = await Promise.all([ task1.triggerAndWait(a), task2.triggerAndWait(b) ]); // CORRECT const results = await batch.triggerAndWait([ { id: "task-1", payload: a }, { id: "task-2", payload: b }, ]);
onFailure Not Firing
Symptom: Task fails but onFailure hook doesn't execute.
Note: onFailure only fires after all retries are exhausted. It also doesn't fire for:
CrashedstatusSystem failuresCanceledruns
Use onComplete for guaranteed post-run execution.
Getting More Help
- Check run logs in the Trigger.dev dashboard
- Trigger.dev Discord: trigger.dev/discord
- GitHub Issues: github.com/triggerdotdev/trigger.dev
- Debug mode:
npx trigger.dev@latest dev --log-level debug