File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change 3
3
import random
4
4
import subprocess
5
5
import ydb .apps .dstool .lib .grouptool as grouptool
6
- from datetime import datetime , timedelta
6
+ from datetime import datetime , timedelta , timezone
7
7
from collections import defaultdict
8
8
import sys
9
9
@@ -215,7 +215,7 @@ def do_kill_blob_depot():
215
215
216
216
################################################################################################################
217
217
218
- now = datetime .utcnow ( )
218
+ now = datetime .now ( timezone . utc )
219
219
while recent_restarts and recent_restarts [0 ] + timedelta (minutes = 1 ) < now :
220
220
recent_restarts .pop (0 )
221
221
@@ -283,7 +283,7 @@ def pick(v):
283
283
################################################################################################################
284
284
285
285
action_name , action = random .choice (possible_actions )
286
- print ('%s %s' % (action_name , datetime .utcnow ( ).strftime ('%Y-%m-%dT%H:%M:%S' )))
286
+ print ('%s %s' % (action_name , datetime .now ( timezone . utc ).strftime ('%Y-%m-%dT%H:%M:%S' )))
287
287
288
288
try :
289
289
action [0 ](* action [1 :])
You can’t perform that action at this time.
0 commit comments