Skip to content

Commit be29fc9

Browse files
authored
Fix "DeprecationWarning: SelectableGroups dict interface is deprecated. Use select."
Previously, the change line issued the above deprecation warning. This code fixes it. I also tested it locally. To reproduce the error before the change, simply run `python -W error -c 'import can.interfaces'`.
1 parent 4136f37 commit be29fc9

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

can/interfaces/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
if sys.version_info >= (3, 8):
3636
from importlib.metadata import entry_points
3737

38-
entries = entry_points().get("can.interface", ())
38+
entries = entry_points(group="can.interface")
3939
BACKENDS.update(
4040
{interface.name: tuple(interface.value.split(":")) for interface in entries}
4141
)

0 commit comments

Comments
 (0)