Repository navigation
trigger.dev v4.8.6
trigger.dev v4.8.6
Upgrade
npx trigger.dev@latest update # npm
pnpm dlx trigger.dev@latest update # pnpm
yarn dlx trigger.dev@latest update # yarn
bunx trigger.dev@latest update # bunSelf-hosted Docker image: ghcr.io/triggerdotdev/trigger.dev:v4.8.6
Release notes
Read the full release notes: https://trigger.dev/changelog/v4-8-6
What's changed
Highlights
- Allow an explicit audience when signing and verifying JWTs and user-actor tokens. (
01337977e)
Improvements
-
Deploys on the
bun-1.4runtime now compile the run worker and your task files into a Bun executable with bytecode, so runs start faster.import.meta.urland__dirnamestill point at your files under/app, so files you read next to your code must be in the image as before (e.g. withadditionalFiles). Setbuild.bunBytecode: falseintrigger.config.tsto turn compilation off. (8130e5e73) -
trigger devandtrigger deployno longer crash withspawn ... ENOENTon bun runtimes when Bun isn't installed at~/.bun. The CLI now falls back tobunon yourPATH(Homebrew, mise and similar installs), and if Bun still can't be started,trigger devreports a readable error andtrigger deployskips local skill discovery with a warning and carries on. (15797c9f2) -
Bundled task files now keep their project layout (for example
/app/src/trigger/tasks.mjs) when the CLI runs from outside the project, such asnpx trigger.dev deploy. Before, they could land under a path containing the project's location, away from the filesadditionalFilescopies next to them, so reads relative toimport.meta.urlfailed. (0c03b59b9) -
Show CLI command errors in the same error format as other CLI errors, and keep them visible with
--log-level error. (c515c3f74) -
Deploys now report a warmup command that loads your config and task files offline without running any task, so the platform can prepare faster run starts for your deployment. (
5479177af) -
Generate the machine ID and the managed run controller ID on first use instead of at import, so importing these modules draws no randomness and a process restored from a warm start does not reuse IDs drawn before it was saved. (
a8ac49cd3) -
Deploys on the
node-24andnode-26runtimes now build a Node compile cache for your bundled code during the image build, so runs spend less time compiling your tasks and their dependencies before they start.node-22deploys are unchanged. (cb1e7362f) -
Report a run whose process the kernel killed for running out of memory as
TASK_PROCESS_OOM_KILLED, rather than as a generic exit afterSIGKILL, when the out-of-memory kill is counted in the run's cgroup. (7a2a7dc80) -
Deployed task processes now receive secret environment variables only with the run, instead of also in the environment the process starts with. (
489a6dff3) -
Deployed task processes now start with the environment variables that Node, OpenSSL, libuv or the dynamic loader read only at startup (such as
LD_PRELOAD,OPENSSL_CONF,NODE_ICU_DATA,TZandUV_*), and the run's logs warn, by name only, about other startup-only variables (such asNODE_OPTIONS,MALLOC_*orGLIBC_TUNABLES) that arrive too late to take effect. (60d1774df) -
Builds from
trigger devandtrigger deploynow use esbuild 0.28. TypeScript parameter properties are now emitted as class fields, and source map paths are URL-encoded. (af2098570) -
webhooks.notion()endpoints accept Notion's verification request. While the endpoint has no signing secret, theverification_tokenNotion sends is stored as its signing secret, so you can paste it back into Notion and later deliveries verify with it. Redeploy with this version for existing Notion endpoints to pick it up. (4288ea912) -
Support scoped run tokens without an environment key, including offloaded task inputs and stream waits. Explain why a run has no usable credential for an operation. (
ed0147895) -
Public-token helpers and chat token creation now prefer server minting for root API keys too, avoiding the legacy claims endpoint on compatible servers. Trigger, batch, and waitpoint responses missing a token also try server minting first. (
90d677b12)Root-key callers retain local-signing compatibility only when the mint endpoint is missing or an older server specifically rejects an empty scope list. Named API keys and run tokens never self-sign. Authorization failures, expiration validation errors, rate limits, and server or connection failures do not activate the fallback.
Server minting with a root key signs with that same authenticated key, including during its rotation grace period, rather than with its replacement. Tokens stop authenticating when that key's grace period ends or it is immediately revoked. Deploy this server update before upgrading the SDK if you rely on minting during root-key rotation; older servers can still reject grace-window keys.
Server-minted tokens use the API rate-limit budget and follow the server's expiration rules, including its 30-day maximum. Minting tokens without scopes requires self-hosted v4.8.4 or later unless the root-key compatibility fallback is available. The default expiration remains 15 minutes.
-
chat.agentnow passeschatId,turnandclientDatato the callbacks an agent can call a model from, so a mock model injected throughclientDatareaches them. The compactionsummarizethat runs throughchat.MessageAccumulator.prepareStep()and achat.createSessionturn'sprepareStep(),onCompacted,onValidateMessages, and thependingMessagesonReceivedandonInjectedcallbacks previously lacked it. ThemockChatAgentturn methods (sendMessage,sendRegenerate,sendAction) now also wait foronTurnCompleteand the transcript save to finish, so tests can assert on what those hooks recorded without a sleep. (579904220) -
concurrencyKeynow also takes an object, so one run can be limited by two limits keyed by different things, like a cap per session and a cap per organization.defaultis the run's own key and every other entry gives a named limit its own key:concurrencyKey: { default: sessionId, [orgLimit.name]: orgId }. A string key works as before. (4961fc474)
Bug fixes
-
Fix
child_process.fork()andspawn(process.execPath, ...)in compiledbun-1.4deploys. They started the run worker again instead of Bun, so the child never ran and the task hung.process.execPathnow points at the image'sbunbinary, as it does in uncompiled deploys. (d63b49ef3) -
Fix webhook verification for
webhooks.brex(), which now reads thewebhook-id,webhook-timestampandwebhook-signatureheaders Brex sends instead ofsvix-*headers, and forwebhooks.composio(), which now keys the signature with the secret's raw text as Composio does instead of base64-decoding it. PagerDuty, Sentry, Vercel, Zendesk, Attio, DocuSign and Intercom endpoints now default to pasting the provider-issued signing secret, and Linear and Calendly offer both generating and pasting one. Redeploy with this version for existing endpoints to pick up the change. (b5b311407) -
Fix
chat.agenton AI SDK 7 sending the model the same input on every step. Once a step'sprepareStepreturned messages (a steering message, a mid-turnchat.inject, context compaction, or your ownprepareStep), later steps no longer included the newest tool results, so the model kept repeating the same tool call until the step limit. (1a2c99034)If you call
chat.compact()from your ownprepareStep, pass it theresponseMessagesyourprepareStepreceives (chat.compact(messages, steps, { ...options, responseMessages })) so steps after a compaction are rebuilt correctly on AI SDK 7.
Server changes
These changes affect the self-hosted Docker image and Trigger.dev Cloud:
- Ask the Dashboard Agent to watch something, such as a deploy, a task or a model, and it proposes alerts you confirm one by one. When the alerts belong together, it offers to create them as one grouped alert in a single click.
- Dashboard widget menus now have a Watch action that starts an alert from the widget's query, and when the query cannot be alerted on as written or the dashboard has filters applied, the Dashboard agent helps adapt it. The Watch button in the dashboard header is removed.
- Select up to 100 environment variable values on the Environment variables page and delete them together. The confirmation lists every value and its environment, and asks you to type a word before anything is removed.
- Compare the environment variables of two environments on the Environment variables page and see only the keys that differ, with secrets shown as the same or different but never revealed. Copy values from one environment to the other, one key or up to 100 at a time.
- Click a key on the environment variables page to see its value in every environment and preview branch in a side panel, with edit and delete in place. A list showing a single environment can also be sorted by last updated. The edit dialog now starts in the value field, and archived preview branches are no longer accepted as targets.
- Environment variables page: a new Needs attention page lists the keys in one environment that are empty, missing compared with your other environments, changed in the last day, or replaceable with OIDC, with copy, delete and ignore actions. The OIDC page is now a grid of providers with setup in a side panel, it points at environment variables OIDC could replace, and there are setup guides for Azure, Google Cloud, HashiCorp Vault, Doppler, Snowflake and Databricks.
- Add opt-in per-environment encryption keys for runtime and build environment variables, with rotation and migration support.
- Add "Ignored branches" to the Git settings: pull requests from branches matching these patterns no longer get a preview deployment. Patterns are globs matched against the whole branch name, like
dependabot/**. - The OIDC page lists Hugging Face and OpenRouter, and the environment variables page suggests OIDC for their API keys. Each has a setup guide in the docs.
- Organization owners can now require multi-factor authentication for every member, and ask for a fresh MFA check before members view environment variables, create personal access tokens or change the organization's security settings. Find both under Organization settings → Security.
- Add a hosted MCP server so AI clients can work with your projects and runs. It is opt-in per deployment.
- The allowed IP addresses field on API keys now turns each address or CIDR range into its own pill as you type, checks it right away with the same rules used on save, and lets you remove entries one at a time. A "Test an IP" button checks whether an address would be allowed by the current list before you save.
- The assistant can now list alerts across environments and projects, and show which alert channels are set up.
- Environment variables page: after adding a variable, the list switches to the environment you saved it in and opens the page that holds the new key, with a toast naming where it went. The
envfilter in the URL also acceptsdevelopment,stagingandproduction. The compare view has a copy button on each key, and each row's edit and delete buttons are named after the key and environment for screen readers. - Runs started through the hosted MCP server are now recorded with the
mcp-remotetrigger source, so they can be told apart from runs started by the local CLI MCP. - Personal access tokens created on the dashboard can now expire on a custom date, picked from a calendar alongside the preset lifetimes. A token expires at the end of the chosen day (UTC), up to the longest offered lifetime.
- A scheduled task's schedules now have their own tab next to Runs, with every column visible. The side panel shows the schedule when the task has exactly one, and a count with a link when it has more. Next run shows the local time first, followed by the relative time.
- Runs start faster when the platform is busy.
- The alert group page now shows its header and member list right away, and member charts fill in as they load.
- The alert wizard now highlights the suggested option on choice steps instead of the first row.
- The alerts list now shows its rows before the activity sparklines load, and the sparklines load faster.
- Alerts created from the Dashboard Agent are now limited to 200 active alerts per project, with bounded names, scopes and notification channels.
- The dashboard agent now asks you to confirm before resolving an alert.
- The Dashboard Agent can now look up runs, deployments and queries in non-development environments for members whose role can see them but can't view API keys.
- Help links (
?aiHelp=,/ai-help) now prefill the chat composer instead of sending. - Fix dashboard pages that open as a dialog (such as adding environment variables or a new alert) re-rendering the whole page when loaded directly or reloaded.
- Saving an environment variable that someone else deletes at the same moment now shows a clear message asking you to try again instead of a database error, and the API answers with a 409. Deleting a value can no longer remove a value that was being added to the same variable at that moment.
- Runs that exhaust their dequeue attempts while the run or its environment can't be read now fail with
TASK_RUN_DEQUEUED_MAX_RETRIESinstead of staying queued forever. - Fix waitpoint callback URLs returning authentication errors when created inside preview branch runs, including previously issued URLs.
- Restore offloaded payload, output, and stream-wait result downloads for API keys with packet read access.
- Keep waitpoint idempotency keys scoped to a run unless the API key can both read and write all waitpoints.
- An organization's only Owner can no longer leave or be removed while other members remain, so the organization always keeps someone who can manage members, billing and roles.
- Numbered pagination no longer repeats a page number on long lists, and the Tasks page now keeps its page numbers in one bar fixed below the table.
- Revoking or expiring a personal access token now also ends the environment JWTs exchanged from it and the run, batch and session tokens minted with them.
- Runs triggered in the seconds after a deploy no longer get stuck waiting for a version until the next deploy.
- A run released from waiting for a version is no longer occasionally left queued with nothing to pick it up when a worker dequeues it at the same moment.
- Fix sandbox task retries stalling when retry delays are short.
- A task that returns while its run is resuming from a wait it did not await (for example a wait raced against a timeout or an abort signal) can now fail right away with an error that says so. Before, the run stayed in an executing state until its heartbeat timed out, and could then be reported as out of memory. This is off by default: set
RUN_ENGINE_STALE_COMPLETION_MODE=enforceon the webapp to switch it on.
All packages: v4.8.6
@trigger.dev/build, @trigger.dev/convex, @trigger.dev/core, @trigger.dev/linear, @trigger.dev/python, @trigger.dev/react-hooks, @trigger.dev/redis-worker, @trigger.dev/rsc, @trigger.dev/schema-to-json, @trigger.dev/sdk, @trigger.dev/slack, trigger.dev
Contributors
Chris Arderne, Eric Allam, Paul Cioanca, Wes Mason, Katia Bulatova, @d-cs, Saadi Myftija, Oskar Otwinowski, João Dias, @jack, @nicktrn, Matt Aitken, github-actions[bot], Adrien de Peretti, @D-K-P, pullfrog[bot], @Mariefay, claude[bot], James Ritchie
Full changelog: v4.8.5...v4.8.6