Skip to content

Commit

Permalink
Trick mypy
Browse files Browse the repository at this point in the history
  • Loading branch information
GianlucaFicarelli committed Oct 18, 2023
1 parent 166490e commit 6823a12
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/build/_importlib.py
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
import sys


if sys.version_info < (3, 10, 2):
if sys.version_info >= (3, 10, 2):
from importlib import metadata # type: ignore[attr-defined]
else:
try:
import importlib_metadata as metadata
except ModuleNotFoundError:
# helps bootstrapping when dependencies aren't installed
from importlib import metadata
else:
from importlib import metadata
from importlib import metadata # type: ignore[attr-defined]

Check warning on line 11 in src/build/_importlib.py

View check run for this annotation

Codecov / codecov/patch

src/build/_importlib.py#L11

Added line #L11 was not covered by tests

__all__ = ['metadata']

0 comments on commit 6823a12

Please sign in to comment.