Skip to content

When relative is set to True, microsecond offset still accumulate #5198

@ckdanny

Description

@ckdanny

path: celery/util/time.py
When relative is set to True, the day, hour, minutes second will be round to the nearest one, however, the original program do not update the microsecond (reset it). As a result, the run-time offset on the microsecond will then be accumulated.

For example, given the interval is 15s and relative is set to True

  1. 2018-11-27T15:01:30.123236+08:00
  2. 2018-11-27T15:01:45.372687+08:00
  3. 2018-11-27T15:02:00.712601+08:00
  4. 2018-11-27T15:02:15.987720+08:00
  5. 2018-11-27T15:02:31.023670+08:00

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions