Gate the statistics module (#35539)

This commit is contained in:
Joseph Hall 2016-08-17 16:06:09 -06:00 committed by Nicole Thomas
parent adbbd472f2
commit 669e979dec

View File

@ -10,7 +10,19 @@ values are stored and computed, such as averages etc.
# import python libs
from __future__ import absolute_import
import statistics
try:
import statistics
HAS_STATS = True
except ImportError:
HAS_STATS = False
def __virtual__():
'''
The statistics module must be pip installed
'''
return HAS_STATS
def calc(name, num, oper, ref=None):