queue icon indicating copy to clipboard operation
queue copied to clipboard

Create, Enqueue and Started Datetime Mismatch

Open fredwilliam opened this issue 3 years ago • 2 comments

I created task and here are the datetime recorded

Created Date | 07/03/2022 02:29:11 Enqueue Time | 06/03/2022 23:29:11 Start Date | 07/03/2022 02:29:11

This is the correct time of as of creation 06/03/2022 23:29:11

Created time seems to be pushed +3hrs ahead this makes execution not starting right away.

My Guess this is timezone issue, is it not supposed to store datetime in utc? so that it can be correctly translated to proper timezone accordingly?

Module

queue_job

Describe the bug

Created time seems to be pushed +3hrs ahead this makes execution not starting right away.

To Reproduce

Affected versions: 12.0

Steps to reproduce the behavior:

  1. set your timezone to Africa/Dar es salaam
  2. create task

Expected behavior Expected to have created time to be current time of creation not +3hrs

Additional context Add any other context about the problem here. (e.g. OS, Python version, ...)

fredwilliam avatar Mar 06 '22 21:03 fredwilliam

Hello @fredwilliam I suggest you tu add this line in your systemd service:

ExecStartPre=/usr/bin/sudo -u postgres /usr/bin/psql DataBaseName -c "update queue_job set state='pending' where state in ('started', 'enqueued');"

m3asmi avatar Mar 09 '22 13:03 m3asmi

There hasn't been any activity on this issue in the past 6 months, so it has been marked as stale and it will be closed automatically if no further activity occurs in the next 30 days. If you want this issue to never become stale, please ask a PSC member to apply the "no stale" label.

github-actions[bot] avatar Sep 11 '22 12:09 github-actions[bot]