Skip to content

Commit f02998b

Browse files
committed
fix gt
1 parent a33ad3e commit f02998b

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

Diff for: src/pint_array/__init__.py

+8-1
Original file line numberDiff line numberDiff line change
@@ -117,6 +117,13 @@ def __mul__(self, other):
117117
units = self.units
118118
return ArrayUnitQuantity(magnitude, units)
119119

120+
def __gt__(self, other):
121+
if hasattr(other, "units"):
122+
magnitude = self._call_super_method("__gt__", other.magnitude)
123+
else:
124+
magnitude = self._call_super_method("__gt__", other)
125+
return ArrayUnitQuantity(magnitude, None)
126+
120127
## Linear Algebra Methods ##
121128
def __matmul__(self, other):
122129
return mod.matmul(self, other)
@@ -190,7 +197,7 @@ def fun(self, name=name):
190197
"__and__",
191198
"__eq__",
192199
"__ge__",
193-
"__gt__",
200+
# "__gt__",
194201
"__le__",
195202
"__lshift__",
196203
"__lt__",

0 commit comments

Comments
 (0)