|
31 | 31 |
|
32 | 32 | if TYPE_CHECKING: |
33 | 33 | from ..context import Context |
| 34 | + from pint import Quantity, Unit |
34 | 35 |
|
35 | | -# from pint import parser, Quantity, Unit |
36 | 36 | from ... import parser |
37 | 37 | from ..._typing import QuantityOrUnitLike, UnitLike |
38 | 38 | from ..._vendor import appdirs |
|
65 | 65 | ScaleConverter, |
66 | 66 | UnitDefinition, |
67 | 67 | ) |
68 | | -from .objects import PlainQuantity, PlainUnit, Quantity, Unit |
| 68 | +from .objects import PlainQuantity, PlainUnit |
69 | 69 |
|
70 | 70 | if TYPE_CHECKING: |
71 | 71 |
|
@@ -799,7 +799,7 @@ def _get_dimensionality_ratio(self, unit1, unit2): |
799 | 799 |
|
800 | 800 | def get_root_units( |
801 | 801 | self, input_units: UnitLike, check_nonmult: bool = True |
802 | | - ) -> Tuple[Number, "Unit"]: |
| 802 | + ) -> Tuple[Number, PlainUnit]: |
803 | 803 | """Convert unit or dict of units to the root units. |
804 | 804 |
|
805 | 805 | If any unit is non multiplicative and check_converter is True, |
@@ -912,7 +912,7 @@ def _get_root_units_recurse(self, ref, exp, accumulators): |
912 | 912 |
|
913 | 913 | def get_compatible_units( |
914 | 914 | self, input_units, group_or_system=None |
915 | | - ) -> FrozenSet["Unit"]: |
| 915 | + ) -> FrozenSet[Unit]: |
916 | 916 | """ """ |
917 | 917 | input_units = to_units_container(input_units) |
918 | 918 |
|
|
0 commit comments