mirror of
https://gitlab.archlinux.org/archlinux/aurweb.git
synced 2025-02-03 10:43:03 +01:00
housekeep: replace deprecated datetime functions
tests show warnings for deprecated utc functions with python 3.12 Signed-off-by: moson <moson@archlinux.org>
This commit is contained in:
parent
ffddf63975
commit
afb7af3e27
9 changed files with 21 additions and 21 deletions
|
@ -15,7 +15,7 @@ import os
|
|||
import random
|
||||
import sys
|
||||
import time
|
||||
from datetime import datetime
|
||||
from datetime import UTC, datetime
|
||||
|
||||
import bcrypt
|
||||
|
||||
|
@ -263,7 +263,7 @@ for p in list(seen_pkgs.keys()):
|
|||
out.write(s)
|
||||
|
||||
# Cast votes
|
||||
utcnow = int(datetime.utcnow().timestamp())
|
||||
utcnow = int(datetime.now(UTC).timestamp())
|
||||
|
||||
track_votes = {}
|
||||
log.debug("Casting votes for packages.")
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue