python: replace warning with logging

This commit is contained in:
Adeeb Shihadeh 2023-08-05 14:10:33 -07:00
parent dc07975446
commit 130092e669
1 changed files with 1 additions and 2 deletions

View File

@ -7,7 +7,6 @@ import struct
import hashlib
import binascii
import datetime
import warnings
import logging
from functools import wraps
from typing import Optional
@ -427,7 +426,7 @@ class Panda:
if len(serial) == 24:
ret.append(serial)
else:
warnings.warn(f"found device with panda descriptors but invalid serial: {serial}", RuntimeWarning)
logging.warning(f"found device with panda descriptors but invalid serial: {serial}", RuntimeWarning)
except Exception:
continue
except Exception: