Skip to content
Get started
Get started
bunqueue v2.7.6
View Markdown
blog · release

bunqueue v2.7.6

Fixes 7 bugs. Systemic silent no-op in ~20 job methods (Issue #82 follow-up), Across 6 factories (processor.ts, jobProxy.ts, flowJobFactory.ts, jobConversion.ts, sandboxed worker, flow), many job methods (retry, moveToWait…

bun add bunqueue@2.7.6
npm install bunqueue@2.7.6
bun add bunqueue@latest
  • Systemic silent no-op in ~20 job methods (Issue #82 follow-up), Across 6 factories (processor.ts, jobProxy.ts, flowJobFactory.ts, jobConversion.ts, sandboxed worker, flow), many job methods (retry, moveToWait, updateProgress, log, remove, etc.) were hardcoded to no-op or silently returned stale values in TCP mode. Same class of silent corruption as the original #82 report. All wired to real handlers with explicit errors on unsupported transitions.
  • job.retry() BullMQ contract: Previously always routed to retryDlq, which silently no-op’d when the job was not in DLQ (e.g. removeOnFail: true, or retry attempted before DLQ persistence). Now state-dispatched: failed→retryDlq (throws if 0), active→moveActiveToWait, waiting/prioritized/delayed→no-op, other→throw.
  • moveToWait semantic divergence between embedded and TCP: Embedded called moveActiveToWait (active→waiting) while the TCP server handler called promote() (delayed→waiting). Same API, opposite outcomes. Server handler now state-dispatches to match embedded; jobProxy embedded path also state-dispatches.
  • Queue.obliterate() leaked active jobs + completed state + SQLite rows: Only shard state was cleared; jobIndex (processing variant), processingShards, completedJobs, completedJobsData, jobResults, jobLogs, jobLocks, repeatChain, customIdMap, DLQ, and persistence tables all survived. Pagination reported wrong counts, memory leaked, obliterated jobs could re-materialize after restart. Now fully purged.
  • Sandboxed worker ModuleNotFound on concurrent spawn (macOS), Two root causes: (1) $TMPDIR trailing slash produced // in wrapper path; (2) concurrent new Worker() raced for Bun’s bundler cache. Fixed by (1) path.join normalization + fsync on write + existence poll that throws on miss, and (2) serializing the first worker spawn so the bundle is cached before siblings load.
  • res.ok truthy read on unknown: 4 sites (extendLock handlers, moveToWait) used loose res.ok ? x : y; harmonized to === true.
  • jobProxy.extendLock dropped the user-provided token in TCP mode: Server saw null and could reject or no-op depending on jobLocks ownership. Token now passed through.
  • New test/obliterate-clears-completed.test.ts (3 tests: post-complete, pagination, active-job purge).
  • New test/retry-contract.test.ts (2 tests: BullMQ contract on DLQ and non-DLQ failed jobs).
  • New test/movetowait-semantics.test.ts (3 tests: delayed, active, waiting idempotence).
  • New test/audit-unwired-processor-methods.test.ts + test/wired-job-methods-embedded.test.ts proving every previously-unwired method is now reachable.
  • Post-condition assertions added for remove() inside processor.

← bunqueue v2.7.5 · Release on GitHub · Commits since v2.7.5 · Full changelog · All posts