@@ -2265,8 +2265,8 @@ def average(values):
22652265 """
22662266 Computes the arithmetic mean of a list of numbers.
22672267
2268- >>> round( average([0.9, 0.9, 0.9, 1.0, 0.8, 0.9]), 1 )
2269- 0.9
2268+ >>> "%.1f" % average([0.9, 0.9, 0.9, 1.0, 0.8, 0.9])
2269+ ' 0.9'
22702270 """
22712271
22722272 return (1.0 * sum (values ) / len (values )) if values else None
@@ -2278,8 +2278,8 @@ def stdev(values):
22782278
22792279 # Reference: http://www.goldb.org/corestats.html
22802280
2281- >>> round( stdev([0.9, 0.9, 0.9, 1.0, 0.8, 0.9]), 3 )
2282- 0.063
2281+ >>> "%.3f" % stdev([0.9, 0.9, 0.9, 1.0, 0.8, 0.9])
2282+ ' 0.063'
22832283 """
22842284
22852285 if not values or len (values ) < 2 :
@@ -4701,10 +4701,7 @@ def prioritySortColumns(columns):
47014701 def _ (column ):
47024702 return column and "id" in column .lower ()
47034703
4704- if six .PY2 :
4705- return sorted (sorted (columns , key = len ), lambda x , y : - 1 if _ (x ) and not _ (y ) else 1 if not _ (x ) and _ (y ) else 0 )
4706- else :
4707- return sorted (sorted (columns , key = len ), key = functools .cmp_to_key (lambda x , y : - 1 if _ (x ) and not _ (y ) else 1 if not _ (x ) and _ (y ) else 0 ))
4704+ return sorted (sorted (columns , key = len ), key = functools .cmp_to_key (lambda x , y : - 1 if _ (x ) and not _ (y ) else 1 if not _ (x ) and _ (y ) else 0 ))
47084705
47094706def getRequestHeader (request , name ):
47104707 """
0 commit comments