Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

goplastic's avatar

Laravel 9.19, job batches wrong pending count (negative) in production server

I'm running Laravel 9.19 on two environments: development and production.

The batch job system works fine in development, but in production, the pending_jobs count in the job_batches table is going negative.

I can't figure out why this is happening only in production.

I tried comparing both environments to ensure they have the same configuration. I expected the pending_jobs count to decrease as jobs are completed, but instead, it drops below zero in production.

The count is correct in development.

0 likes
1 reply
tisuchi's avatar

@goplastic It's really hard to assist you without checking your code.

You better share your code.

Please or to participate in this conversation.