bull icon indicating copy to clipboard operation
bull copied to clipboard

TypeError: Cannot read property 'remove' of null

Open andrewtamura opened this issue 10 years ago • 2 comments

TypeError: Cannot read property 'remove' of null
  File "/var/node_modules/bull/lib/queue.js", line 838, in null.<anonymous>
    return job.remove();
  File "domain.js", line 287, in bound
  File "domain.js", line 300, in runBound
  File "/var/node_modules/bull/node_modules/bluebird/js/release/util.js", line 16, in tryCatcher
    return target.apply(this, arguments);
  File "/var/node_modules/bull/node_modules/bluebird/js/release/reduce.js", line 145, in Object.gotValue
    ret = fn.call(promise._boundValue(), value, this.index, this.length);
  File "/var/node_modules/bull/node_modules/bluebird/js/release/reduce.js", line 134, in Object.gotAccum
    return gotValue.call(this, value);
  File "domain.js", line 287, in bound
  File "domain.js", line 300, in Object.runBound
  File "/var/node_modules/bull/node_modules/bluebird/js/release/util.js", line 16, in Object.tryCatcher
    return target.apply(this, arguments);
  File "/var/node_modules/bull/node_modules/bluebird/js/release/promise.js", line 502, in Promise._settlePromiseFromHandler
    x = tryCatch(handler).call(receiver, value);
  File "/var/node_modules/bull/node_modules/bluebird/js/release/promise.js", line 559, in Promise._settlePromise
    this._settlePromiseFromHandler(handler, receiver, value, promise);
  File "/var/node_modules/bull/node_modules/bluebird/js/release/promise.js", line 596, in Promise._settlePromiseCtx
    this._settlePromise(ctx.promise, ctx.handler, ctx.receiver, ctx.value);
  File "/var/node_modules/bull/node_modules/bluebird/js/release/async.js", line 143, in Async._drainQueue
    fn.call(receiver, arg);
  File "/var/node_modules/bull/node_modules/bluebird/js/release/async.js", line 148, in Async._drainQueues
    this._drainQueue(this._normalQueue);
  File "[as _onImmediate] (/var/node_modules/bull/node_modules/bluebird/js/release/async.js", line 17, in Immediate.Async.drainQueues
  File "[as _immediateCallback] (timers.js", line 383, in processImmediate

It looks like https://github.com/OptimalBits/bull/pull/275 should resolve this issue. getJob returns null if there is a job index that doesn't have any job data.

andrewtamura avatar May 16 '16 17:05 andrewtamura

@chuym should this still happen with https://github.com/OptimalBits/bull/pull/291 ?

bradvogel avatar May 16 '16 18:05 bradvogel

this issue should be fixed by now, reopen if not.

manast avatar Jun 21 '16 08:06 manast