Skip to content

Commit 685fc4d

Browse files
committed
Replace generic exception and use f-string.
1 parent d51a9ec commit 685fc4d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

cap1xxx/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -303,7 +303,7 @@ def __init__(
303303
self.product_id = self._get_product_id()
304304

305305
if self.product_id not in self.supported:
306-
raise Exception("Product ID {} not supported!".format(self.product_id))
306+
raise RuntimeError(f"Product ID {self.product_id} not supported!")
307307

308308
if skip_init:
309309
return

0 commit comments

Comments
 (0)