mirror of
https://github.com/prymitive/karma
synced 2026-05-05 03:16:51 +00:00
fix(demo): fix python warnings
This commit is contained in:
committed by
Łukasz Mierzwa
parent
895c0e19d2
commit
cfacc30842
@@ -310,7 +310,7 @@ class SilencedAlert(AlertGenerator):
|
||||
]
|
||||
|
||||
def silences(self):
|
||||
now = datetime.datetime.utcnow().replace(microsecond=0)
|
||||
now = datetime.datetime.now(datetime.UTC).replace(microsecond=0)
|
||||
return [
|
||||
(
|
||||
[newMatcher("alertname", self.name, False)],
|
||||
@@ -356,7 +356,7 @@ class MixedAlerts(AlertGenerator):
|
||||
]
|
||||
|
||||
def silences(self):
|
||||
now = datetime.datetime.utcnow().replace(microsecond=0)
|
||||
now = datetime.datetime.now(datetime.UTC).replace(microsecond=0)
|
||||
return [
|
||||
(
|
||||
[
|
||||
@@ -475,7 +475,7 @@ class SilencedAlertWithJiraLink(AlertGenerator):
|
||||
]
|
||||
|
||||
def silences(self):
|
||||
now = datetime.datetime.utcnow().replace(microsecond=0)
|
||||
now = datetime.datetime.now(datetime.UTC).replace(microsecond=0)
|
||||
return [
|
||||
(
|
||||
[newMatcher("alertname", self.name, False)],
|
||||
@@ -507,7 +507,7 @@ class PaginationTest(AlertGenerator):
|
||||
]
|
||||
|
||||
def silences(self):
|
||||
now = datetime.datetime.utcnow().replace(microsecond=0)
|
||||
now = datetime.datetime.now(datetime.UTC).replace(microsecond=0)
|
||||
return [
|
||||
(
|
||||
[
|
||||
|
||||
Reference in New Issue
Block a user