Project

General

Profile

Bug #86888

can't subtract offset-naive and offset-aware datetimes

Added by Frédéric Péters 20 days ago. Updated 20 days ago.

Status:
Solution déployée
Priority:
Normal
Target version:
-
Start date:
12 February 2024
Due date:
% Done:

0%

Estimated time:
Patch proposed:
No
Planning:
No

Description

Exception:
  type = '<class 'TypeError'>', value = 'can't subtract offset-naive and offset-aware datetimes'

Stack trace (most recent call first):
  File "/usr/lib/python3/dist-packages/wcs/wf/jump.py", line 326, in check_condition
   324             last = formdata.last_update_time
   325             if last and timeout_seconds:
>  326                 diff = (localtime() - last).total_seconds()
   327                 if diff < timeout_seconds:
   328                     return False

  locals:
     __class__ = <class 'wcs.wf.jump.JumpWorkflowStatusItem'>
     args = ()
     formdata = <_wcs_Signaler-Un-Probleme-Concernant-La-Voirie-Modif-Ns 'La voirie - n°171-353' id:353>
     kwargs = {}
     last = datetime.datetime(2024, 2, 12, 17, 48, 5, 98818)
     result = True
     self = <JumpWorkflowStatusItem 4 in status "En attente de retour de GRU" (40) in workflow "V7 - WF - Signalement Voirie - Tous canaux" 
(245)>
     timeout_seconds = 3600.0
     timeout_str = 3600
     trigger = None

Associated revisions

Revision 80b4de8e (diff)
Added by Frédéric Péters 20 days ago

misc: use tz-aware time for last_jump_datetime (#86888)

History

#2

Updated by Robot Gitea 20 days ago

  • Status changed from Nouveau to En cours

Frédéric Péters (fpeters) a ouvert une pull request sur Gitea concernant cette demande :

#3

Updated by Robot Gitea 20 days ago

  • Status changed from En cours to Solution proposée
#4

Updated by Robot Gitea 20 days ago

  • Status changed from Solution proposée to Solution validée

Lauréline Guérin (lguerin) a approuvé une pull request sur Gitea concernant cette demande :

#5

Updated by Robot Gitea 20 days ago

  • Status changed from Solution validée to Résolu (à déployer)

Frédéric Péters (fpeters) a mergé une pull request sur Gitea concernant cette demande :

#6

Updated by Transition automatique 20 days ago

  • Status changed from Résolu (à déployer) to Solution déployée

Also available in: Atom PDF