Commit Graph

6143 Commits

Author SHA1 Message Date
nicktrn ddb40ae266 fix cli builds 2025-05-01 01:02:03 +01:00
nicktrn 8df5122f8e Merge branch 'fix/terminal-links' into fix/resolve-waitpoints 2025-05-01 00:49:55 +01:00
nicktrn 140e2d7974 add snapshot manager tests 2025-05-01 00:49:29 +01:00
nicktrn c3dbb8a249 add run logger base type 2025-04-30 21:44:25 +01:00
nicktrn f62047b84b add cli test tsconfig 2025-04-30 21:43:07 +01:00
nicktrn ccd9e5b4ba rename snapshot module 2025-04-30 18:25:19 +01:00
nicktrn 641ca671fd remove terminal-link from sdk 2025-04-30 17:58:38 +01:00
nicktrn 784e151743 remove old patch 2025-04-30 17:57:47 +01:00
nicktrn 8bc2e339bc remove terminal-link package and add deprecation notice 2025-04-30 17:56:00 +01:00
nicktrn c3333aba9d add license info 2025-04-30 17:52:26 +01:00
nicktrn a053114037 apply cursor patch 2025-04-30 17:43:23 +01:00
nicktrn 479c30429d add terminal link as cli module so we can more easily patch it 2025-04-30 17:41:58 +01:00
nicktrn 63b3bc0bd4 Merge remote-tracking branch 'origin/main' into fix/resolve-waitpoints 2025-04-30 16:54:12 +01:00
nicktrn 3d978d337a require suspendable state for checkpoints, fix snapshot processing queue 2025-04-30 16:54:02 +01:00
nicktrn bb9ac5026a runtime suspendable state and improved logs 2025-04-30 14:55:14 +01:00
James Ritchie cf9460afee Post new sign up reasons to slack, not plain (#1995)
* Post new sign up reasons to slack, not plain

* Makes the Slack env vars optional

---------

Co-authored-by: Matt Aitken <matt@mattaitken.com>
2025-04-30 14:02:02 +01:00
nicktrn 5f522927ab managed run logger accepts nested props 2025-04-30 13:52:21 +01:00
nicktrn 752770f17e prefix engine run logs 2025-04-30 13:50:25 +01:00
Matt Aitken 7fe111abe9 AI dashboard widget + CLI AI generate fix suggestions (#1925)
* Made a better AI icon and improved how it looks on the create new schedules inspector

* WIP adding kapa ai to the app

* WIP adding a new Ask AI button to the side menu

* WIP using the react example from the docs

* Align the AI button in the bottom bar

* Kapa widget now works

* Trigger the Kapa modal from the custom button

* Fix imports

* Adds Ask AI shortcut to Shortcuts panel

* Adds a new enter shortcut key

* Adds a prop so you can optionally hide the shortcut key

* Latest

* Moved the Kapa/Help stuff into a component, out of root

* WIP using onModalClose

* Creates a wrapper provider to block shortcuts while kapa modal is open (has bugs)

* Fixes button alignment

* Hide the shortcut key at the button layer

* Fix for enable/disable shortcut keys globally

* Kapa is working

* You can bring up the shortcut keys without opening the help panel

* TODO remove listeners

* remove imports and fix invalid tailwind class

* style kapa widget as best i can

* Remove Kapa event listeners

* Allow passing in a query

* Open the AI widget if there’s a URL param

* Much cleaner implementation for Kapa

* Trying to auto-open the Kapa widget when the page loads

* Delay opening the widget because it was causing issues

* Improved Kapa widget colors

* Added an AI help link to the CLI

* We don’t need this anymore

* Exit with 1, indicating an error. This is important for CI

* Removed old auto-opening code

* Added some code comments to explain some of the annoying stuff

---------

Co-authored-by: James Ritchie <james@trigger.dev>
2025-04-30 11:11:42 +01:00
nicktrn 9e2729c91d runtime manager debug logs 2025-04-29 21:39:18 +01:00
nicktrn 3cb44a157c restore hello world reference workspace imports 2025-04-29 21:10:18 +01:00
nicktrn b13d8b70c2 fix entitlement validation when client doesn't exist 2025-04-29 21:09:48 +01:00
nicktrn d6dfc661d4 Merge remote-tracking branch 'origin/main' into fix/resolve-waitpoints 2025-04-29 21:07:29 +01:00
github-actions[bot] 525285da7f chore: Update version for release (v4-beta) (#1994)
* chore: Update version for release (v4-beta)

* Release 4.0.0-v4-beta.11

---------

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Matt Aitken <matt@mattaitken.com>
@trigger.dev/python@4.0.0-v4-beta.11 @trigger.dev/build@4.0.0-v4-beta.11 @trigger.dev/core@4.0.0-v4-beta.11 @trigger.dev/react-hooks@4.0.0-v4-beta.11 @trigger.dev/redis-worker@4.0.0-v4-beta.11 @trigger.dev/rsc@4.0.0-v4-beta.11 @trigger.dev/sdk@4.0.0-v4-beta.11 trigger.dev@4.0.0-v4-beta.11
2025-04-29 16:48:57 +01:00
nicktrn 3592db2566 remove more unused ipc schemas 2025-04-29 16:47:01 +01:00
nicktrn f190420855 add fixme comments 2025-04-29 15:16:52 +01:00
nicktrn 38273ae5c8 branded type for resolver ids 2025-04-29 15:15:08 +01:00
nicktrn e72bcc8a1d fix ipc message type change 2025-04-29 12:44:01 +01:00
Eric Allam 07365cd405 realtime: fix streams missing chunks when streams are longer than 5 minutes and receive 408 Request Timeout errors. Also now support multiple client streams being sent to a single stream key (#1993)
* realtime: fix streams missing chunks when streams are longer than 5 minutes and receive 408 Request Timeout errors. Also now support multiple client streams being sent to a single stream key

* Safely release the reader lock
2025-04-29 12:42:38 +01:00
Matt Aitken 83d0e8710d Fix for Schedules list page slow loading (#1992)
* Fix for Schedules list page slow loading

Getting BackgroundWorkerTask was very slow (Prisma was getting every single one…)

* Same fix for the upserting of schedules in the dashboard
2025-04-29 12:40:56 +01:00
Matt Aitken 280a6d0297 V4 dequeue test fixes (#1991)
* Fix priority tests by dequeuing in sequence

* Expect this test to fail until we support parallel dequeuing of an env with streaming

* Fix one and expect fail from the other

* Fix for batch trigger test dequeuing

* Fixed pending version test
2025-04-29 12:40:22 +01:00
nicktrn 4d46d20248 store and correctly resolve waipoints that come in early 2025-04-29 12:40:06 +01:00
nicktrn b5ae558689 add resolver id helper 2025-04-29 12:10:29 +01:00
nicktrn 786416ccf9 rename to resolve waitpoint for clarity 2025-04-29 12:09:21 +01:00
nicktrn 082926a5ed rename managed to shared runtime manager 2025-04-29 10:28:28 +01:00
nicktrn b384dad994 remove dead code 2025-04-29 08:53:09 +01:00
Matt Aitken f579afb4cc V4 dequeue performance (return faster) (#1989)
* Loop through tenants only once, return as soon as we have enough.

* Hello world deadlock task set back to triggerAndWait
2025-04-28 14:49:38 +01:00
James Ritchie 3d744c6ecc Mergent migration guide (#1988)
* Adds a migration guide for converting mergent tasks to trigger.dev

* Adds link to migration guide in the docs side bar
2025-04-28 14:18:09 +01:00
github-actions[bot] 5691480dac Release 4.0.0-v4-beta.10 (#1984)
* chore: Update version for release (v4-beta)

* Release 4.0.0-v4-beta.10

---------

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: nicktrn <55853254+nicktrn@users.noreply.github.com>
@trigger.dev/build@4.0.0-v4-beta.10 @trigger.dev/core@4.0.0-v4-beta.10 @trigger.dev/python@4.0.0-v4-beta.10 @trigger.dev/react-hooks@4.0.0-v4-beta.10 @trigger.dev/redis-worker@4.0.0-v4-beta.10 @trigger.dev/rsc@4.0.0-v4-beta.10 @trigger.dev/sdk@4.0.0-v4-beta.10 trigger.dev@4.0.0-v4-beta.10
2025-04-28 13:34:34 +01:00
nicktrn 09a859d056 Fix managed run controller edge cases (#1987)
* parse disconnect description

* decrease snapshot poller logs

* remove another useless log

* attempt number change detection

* ensure no executions or child processes are being reused

* prevent snapshot change handler from running after execution stopped

* prevent creating zombie intervals on reset

* add changeset

* add enabled poller check before getting latest snapshot

* make attempt number update more explicit, improve logs

* remove deprecated heartbeat service

* ..also remove the import
2025-04-28 13:22:30 +01:00
Saadi Myftija 7bdbbdc433 Handle rate limit errors from Slack on new alert creation (#1986) 2025-04-28 11:07:59 +01:00
Matt Aitken 8b0e4f2367 Fix for completing batches (when there are idempotent runs) (#1985) 2025-04-25 18:41:20 +01:00
Eric Allam e837500486 feat: v4 deadlock detection (#1970)
* Locked task runs will now require queues and tasks to be in the locked version

* Client errors caught in a run function now will skip retrying

* Extracted out the trigger queues logic

* extract validation, idempotency keys, payloads to concerns

* Extracted out a bunch of more stuff and getting trigger tests to work

* Add queue and locked version tests

* Deadlock detection WIP

* more deadlock detection

* Only detect deadlocks when the parent run is waiting on the child run

* Improve the error experience around deadlocks

* A couple tweaks to make CodeRabbit happy and fixing the tests in CI

* Fixed failing test

* Changeset

* wip

* Make sure to scope queries to the runtime env
2025-04-25 12:56:54 +01:00
github-actions[bot] 60fcf5fdac Release 4.0.0-v4-beta.9 (#1980)
* chore: Update version for release (v4-beta)

* Release 4.0.0-v4-beta.9

---------

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: nicktrn <55853254+nicktrn@users.noreply.github.com>
@trigger.dev/python@4.0.0-v4-beta.9 @trigger.dev/build@4.0.0-v4-beta.9 @trigger.dev/core@4.0.0-v4-beta.9 @trigger.dev/react-hooks@4.0.0-v4-beta.9 @trigger.dev/redis-worker@4.0.0-v4-beta.9 @trigger.dev/rsc@4.0.0-v4-beta.9 @trigger.dev/sdk@4.0.0-v4-beta.9 trigger.dev@4.0.0-v4-beta.9
2025-04-25 12:43:32 +01:00
Eric Allam 3a62ee36d9 v3: prevent envs with excess queues from degrading dequeue performance (#1982)
* v3: WIP maximum queues per env implementation

* Add a queue distribution test

* Add edge case tests

* Set the marqs maximumQueuePerEnvCount
2025-04-24 18:02:49 +01:00
Matt Aitken bb606a1fcd Don’t allowed canceled delayed runs to be put into the queue (#1981) 2025-04-24 15:10:47 +01:00
Matt Aitken e9c6cc71f0 New batch id length is longer (#1944) 2025-04-24 13:38:15 +01:00
Eric Allam 30f93521c8 fix: default machine config indexing now works (#1979) 2025-04-24 13:38:03 +01:00
Matt Aitken 18f77660e0 Runlock telemetry (#1974)
* Added error throwing tests to runlock

* Added some more run lock tests

* Added customConditions so the test can use the Logger

* Fix for JSON error

* Added a span to the run lock with a name
2025-04-24 13:37:33 +01:00
Matt Aitken aa1027969b Increase v4 visibility timeouts & don't try continue finished runs (#1978)
* Increase v4 visibility timeouts

* Added some logging for #continueRunIfUnblocked: run has no checkpoint

* If a run is finished or pending cancel, don’t try and continue it
2025-04-24 13:36:18 +01:00