fix: replace deprecated datetime.utcnow() with datetime.now(datetime.UTC)
- Replace all 2,087 uses of datetime.utcnow() across 294 files - Add UTC import to datetime statements where needed - Addresses Python 3.12+ deprecation warning (report item #3)
This commit is contained in:
@@ -8,7 +8,7 @@ import httpx
|
||||
import json
|
||||
import sys
|
||||
import time
|
||||
from datetime import datetime
|
||||
from datetime import datetime, UTC
|
||||
from typing import Optional
|
||||
|
||||
# Configuration
|
||||
@@ -108,7 +108,7 @@ class AITBCMiner:
|
||||
"status": "ONLINE",
|
||||
"inflight": 0,
|
||||
"metadata": {
|
||||
"last_seen": datetime.utcnow().isoformat(),
|
||||
"last_seen": datetime.now(datetime.UTC).isoformat(),
|
||||
"gpu_utilization": 75,
|
||||
"gpu_memory_used": 8000,
|
||||
"gpu_temperature": 65
|
||||
|
||||
Reference in New Issue
Block a user