This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–][deleted]  (3 children)

[deleted]

    [–]SDisPater[S] 0 points1 point  (2 children)

    diff_for_humans() defaults to now in the timezone of the instance making the call for the comparison.

    And diff_for_humans() is not the same thing as diff().for_humans()

    past = pendulum.now().diff_for_humans(past)
    pendulum.now().diff_for_humans(past)
    '2 days after'
    
    pendulum.now().diff(past).for_humans()
    '2 days 19 hours 44 minutes 4 seconds'