File tree Expand file tree Collapse file tree 5 files changed +16
-8
lines changed
apps/webapp/app/v3/services Expand file tree Collapse file tree 5 files changed +16
-8
lines changed Original file line number Diff line number Diff line change 1+ ---
2+ " trigger.dev " : patch
3+ " @trigger.dev/core " : patch
4+ ---
5+
6+ Correctly display errors on attempts and during indexing
Original file line number Diff line number Diff line change @@ -97,7 +97,7 @@ export class CrashTaskRunService extends BaseService {
9797 event : event ,
9898 crashedAt : opts . crashedAt ,
9999 exception : {
100- type : "Worker crashed ",
100+ type : opts . errorCode ?? "TASK_RUN_CRASHED ",
101101 message : opts . reason ,
102102 stacktrace : opts . logs ,
103103 } ,
@@ -119,6 +119,7 @@ export class CrashTaskRunService extends BaseService {
119119 {
120120 reason : opts . reason ,
121121 logs : opts . logs ,
122+ code : opts . errorCode ,
122123 }
123124 ) ;
124125 }
Original file line number Diff line number Diff line change @@ -61,7 +61,7 @@ async function indexDeployment({
6161 const $env = await cliApiClient . getEnvironmentVariables ( projectRef ) ;
6262
6363 if ( ! $env . success ) {
64- throw new Error ( `Failed to fetch environment variables: ${ env . error } ` ) ;
64+ throw new Error ( `Failed to fetch environment variables: ${ $ env. error } ` ) ;
6565 }
6666
6767 const workerManifest = await indexWorkerManifest ( {
Original file line number Diff line number Diff line change @@ -784,12 +784,6 @@ class ProdWorker {
784784 error,
785785 } ) ;
786786
787- try {
788- await this . _taskRunProcess . cancel ( ) ;
789- } catch ( error ) {
790- logger . error ( "Failed to cancel task run process" , { error } ) ;
791- }
792-
793787 try {
794788 await this . #submitAttemptCompletion( execution , {
795789 id : execution . run . id ,
Original file line number Diff line number Diff line change @@ -395,6 +395,13 @@ export function exceptionEventEnhancer(
395395 }
396396 break ;
397397 }
398+ case TaskRunErrorCodes . TASK_PROCESS_MAYBE_OOM_KILLED :
399+ case TaskRunErrorCodes . TASK_PROCESS_OOM_KILLED : {
400+ return {
401+ ...exception ,
402+ ...prettyInternalErrors [ exception . type ] ,
403+ } ;
404+ }
398405 }
399406
400407 return exception ;
You can’t perform that action at this time.
0 commit comments