summaryrefslogtreecommitdiff
path: root/pint
diff options
context:
space:
mode:
authorKeewis <keewis@posteo.de>2021-08-18 01:27:17 +0200
committerKeewis <keewis@posteo.de>2021-08-18 01:27:17 +0200
commitfd74206c52e1876cc6bb09f5bb6fd0e4b1ecc806 (patch)
treea1680995f6a403e2da84381a445a8b557a5dc9ae /pint
parent30a42bcccca40b07e77d8b83ba4a7172d41b91fc (diff)
downloadpint-fd74206c52e1876cc6bb09f5bb6fd0e4b1ecc806.tar.gz
also pass the registry in `Measurement.__format__`
Diffstat (limited to 'pint')
-rw-r--r--pint/measurement.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/pint/measurement.py b/pint/measurement.py
index feb509d..4e8e8aa 100644
--- a/pint/measurement.py
+++ b/pint/measurement.py
@@ -112,7 +112,7 @@ class Measurement(Quantity):
# Also, SIunitx doesn't accept parentheses, which uncs uses with
# scientific notation ('e' or 'E' and sometimes 'g' or 'G').
mstr = mstr.replace("(", "").replace(")", " ")
- ustr = siunitx_format_unit(self.units)
+ ustr = siunitx_format_unit(self.units._units, self._registry)
return r"\SI%s{%s}{%s}" % (opts, mstr, ustr)
# standard cases