mirror of
https://github.com/tahoe-lafs/tahoe-lafs.git
synced 2025-04-07 10:56:49 +00:00
Add back missing function.
This commit is contained in:
parent
229583c596
commit
939648c04f
@ -17,4 +17,11 @@ if PY2:
|
||||
|
||||
|
||||
# The API importers expect:
|
||||
from pyutil.mathutil import div_ceil, next_multiple, pad_size, is_power_of_k, next_power_of_k, ave, log_ceil, log_floor, round_sigfigs
|
||||
from pyutil.mathutil import div_ceil, next_multiple, pad_size, is_power_of_k, next_power_of_k, ave, log_ceil, log_floor
|
||||
|
||||
|
||||
# This function is not present in pyutil.mathutil:
|
||||
def round_sigfigs(f, n):
|
||||
fmt = "%." + str(n-1) + "e"
|
||||
return float(fmt % f)
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user