Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
G
gsauthof-utility
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
external
gsauthof-utility
Commits
2bf657de
Commit
2bf657de
authored
9 months ago
by
Georg Sauthoff
Browse files
Options
Downloads
Patches
Plain Diff
fix utcnow deprecation warning
deprecated since at least python 3.12
parent
7779fa57
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
check-cert.py
+1
-1
1 addition, 1 deletion
check-cert.py
with
1 addition
and
1 deletion
check-cert.py
+
1
−
1
View file @
2bf657de
...
@@ -32,7 +32,7 @@ class Cert_Error(Exception):
...
@@ -32,7 +32,7 @@ class Cert_Error(Exception):
# In[ ]:
# In[ ]:
def
check_not_expired
(
lines
,
now
=
datetime
.
datetime
.
utc
now
()):
def
check_not_expired
(
lines
,
now
=
datetime
.
datetime
.
now
(
datetime
.
UTC
)):
exp
=
re
.
compile
(
"
expires `([^
'
]+) UTC
'"
)
exp
=
re
.
compile
(
"
expires `([^
'
]+) UTC
'"
)
thresh
=
now
+
datetime
.
timedelta
(
days
=
20
)
thresh
=
now
+
datetime
.
timedelta
(
days
=
20
)
for
l
in
lines
:
for
l
in
lines
:
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment