Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

move this._addWorkerDataToError to before rollbar reporting #107

Merged
merged 1 commit into from Oct 14, 2016
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
3 changes: 2 additions & 1 deletion src/worker.js
Expand Up @@ -229,6 +229,7 @@ class Worker {
.finally(() => {
this._incMonitor('ponos.finish-error', { result: 'retry-error' })
throw new WorkerStopError('final retry handler finished', {
originalError: err,
queue: this.queue,
job: this.job,
attempt: this.attempt
Expand Down Expand Up @@ -297,10 +298,10 @@ class Worker {
.bind(this)
.then(this._wrapTask)
.then(this._handleTaskSuccess)
.catch(this._addWorkerDataToError)
// If the type is TimeoutError, log and re-throw error
.catch(TimeoutError, this._handleTimeoutError)
.catch(this._enforceRetryLimit)
.catch(this._addWorkerDataToError)
.catch((err) => {
this.errorCat.report(err)
throw err
Expand Down