Skip to content

Commit

Permalink
Get Traversable from importlib_resources.
Browse files Browse the repository at this point in the history
  • Loading branch information
jaraco committed Sep 12, 2024
1 parent f736fde commit e33999e
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions pytest_enabler/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,10 @@

if sys.version_info >= (3, 12):
from importlib import resources
from importlib.resources.abc import Traversable
else:
import importlib_resources as resources

if sys.version_info >= (3, 9):
from importlib.abc import Traversable
else: # pragma: no cover
from pathlib import Path as Traversable
from importlib_resources.abc import Traversable

if TYPE_CHECKING:
from _typeshed import SupportsRead
Expand Down

0 comments on commit e33999e

Please sign in to comment.