Commit a399eded authored by Matthias Markl's avatar Matthias Markl Committed by Michael Kuron
Browse files

bug fix in pint_unit_converter.py

parent f1903a70
......@@ -113,12 +113,12 @@ class PintUnitConverter:
elif type(value) is tuple:
try:
result[key] = tuple( [ self.ureg.Quantity(e) for e in value ] )
except (pint.unit.UndefinedUnitError, ValueError, TypeError):
except (pint.UndefinedUnitError, ValueError, TypeError):
result[key] = value
else:
try:
result[key] = self.ureg.Quantity( value )
except (pint.unit.UndefinedUnitError, ValueError, TypeError):
except (pint.UndefinedUnitError, ValueError, TypeError):
result[key] = value
return result
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment