Skip to content

Commit

Permalink
fix: make type_extensions import only for type checking
Browse files Browse the repository at this point in the history
  • Loading branch information
tklockau committed Nov 18, 2024
1 parent c1940f8 commit c5c8425
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 3 deletions.
3 changes: 2 additions & 1 deletion raillabel/filter/filter.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@
import typing as t
from warnings import warn

from typing_extensions import deprecated
if t.TYPE_CHECKING:
from typing_extensions import deprecated

from .. import format
from . import _filter_classes
Expand Down
3 changes: 2 additions & 1 deletion raillabel/stats/generate_timespan.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@
from decimal import Decimal
from warnings import warn

from typing_extensions import deprecated
if t.TYPE_CHECKING:
from typing_extensions import deprecated

from ..format import Scene

Expand Down
4 changes: 3 additions & 1 deletion raillabel/validate/validate.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,9 @@

import fastjsonschema
import jsonschema
from typing_extensions import deprecated

if t.TYPE_CHECKING:
from typing_extensions import deprecated

from .. import exceptions

Expand Down

0 comments on commit c5c8425

Please sign in to comment.