Skip to content
This repository has been archived by the owner on Jul 10, 2023. It is now read-only.

Commit

Permalink
Update ThundraWrapper.ts
Browse files Browse the repository at this point in the history
  • Loading branch information
hamitb committed Feb 25, 2020
1 parent f61a343 commit 10b9d78
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions src/ThundraWrapper.ts
Original file line number Diff line number Diff line change
Expand Up @@ -506,10 +506,15 @@ class ThundraWrapper {
return setTimeout(() => {
if (this.debuggerProxy) {
// Debugger proxy exists, let it know about the timeout
if (!this.debuggerProxy.killed) {
this.debuggerProxy.kill('SIGHUP');
try {
if (!this.debuggerProxy.killed) {
this.debuggerProxy.kill('SIGHUP');
}
} catch (e) {
ThundraLogger.getInstance().error(e);
} finally {
this.debuggerProxy = null;
}
this.debuggerProxy = null;
}
wrapperInstance.report(new TimeoutError('Lambda is timed out.'), null, null);
wrapperInstance.reported = false;
Expand Down

0 comments on commit 10b9d78

Please sign in to comment.