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 {
97
97
event : event ,
98
98
crashedAt : opts . crashedAt ,
99
99
exception : {
100
- type : "Worker crashed ",
100
+ type : opts . errorCode ?? "TASK_RUN_CRASHED ",
101
101
message : opts . reason ,
102
102
stacktrace : opts . logs ,
103
103
} ,
@@ -119,6 +119,7 @@ export class CrashTaskRunService extends BaseService {
119
119
{
120
120
reason : opts . reason ,
121
121
logs : opts . logs ,
122
+ code : opts . errorCode ,
122
123
}
123
124
) ;
124
125
}
Original file line number Diff line number Diff line change @@ -61,7 +61,7 @@ async function indexDeployment({
61
61
const $env = await cliApiClient . getEnvironmentVariables ( projectRef ) ;
62
62
63
63
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 } ` ) ;
65
65
}
66
66
67
67
const workerManifest = await indexWorkerManifest ( {
Original file line number Diff line number Diff line change @@ -784,12 +784,6 @@ class ProdWorker {
784
784
error,
785
785
} ) ;
786
786
787
- try {
788
- await this . _taskRunProcess . cancel ( ) ;
789
- } catch ( error ) {
790
- logger . error ( "Failed to cancel task run process" , { error } ) ;
791
- }
792
-
793
787
try {
794
788
await this . #submitAttemptCompletion( execution , {
795
789
id : execution . run . id ,
Original file line number Diff line number Diff line change @@ -395,6 +395,13 @@ export function exceptionEventEnhancer(
395
395
}
396
396
break ;
397
397
}
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
+ }
398
405
}
399
406
400
407
return exception ;
You can’t perform that action at this time.
0 commit comments