mirror of
https://github.com/saltstack/salt.git
synced 2025-04-17 10:10:20 +00:00
Merge pull request #49187 from erwindon/py27fixnumberformat
Fix for #45620: "Salt CLI is rounding floats to 2 decimal places"
This commit is contained in:
commit
5ba7f60f03
1 changed files with 3 additions and 1 deletions
|
@ -81,12 +81,14 @@ class NestDisplay(object):
|
|||
)
|
||||
# Number includes all python numbers types
|
||||
# (float, int, long, complex, ...)
|
||||
# use repr() to get the full precision also for older python versions
|
||||
# as until about python32 it was limited to 12 digits only by default
|
||||
elif isinstance(ret, Number):
|
||||
out.append(
|
||||
self.ustring(
|
||||
indent,
|
||||
self.LIGHT_YELLOW,
|
||||
ret,
|
||||
repr(ret),
|
||||
prefix=prefix
|
||||
)
|
||||
)
|
||||
|
|
Loading…
Add table
Reference in a new issue