Skip to content
Permalink
Browse files

YAPF'd everything.

Change-Id: Ie36238e9a0343239a57cf04c07c755ddd39a3920
  • Loading branch information
svenpanne committed Dec 18, 2019
1 parent 4d02560 commit 8194e8a0e4e57bde880d04ec6f10ea36d86eb2b7
@@ -64,13 +64,13 @@ def azure_iter_informative_attrs(resource, include_keys=('location',)):


def check_azure_metric( # pylint: disable=too-many-locals
resource,
metric_key,
cmk_key,
display_name,
levels=None,
levels_lower=None,
use_rate=False):
resource,
metric_key,
cmk_key,
display_name,
levels=None,
levels_lower=None,
use_rate=False):
metric = resource.get('metrics', {}).get(metric_key)
if metric is None:
return None
@@ -321,7 +321,10 @@ check_info['emcvnx_storage_pools.tieringtypes'] = {
# '----------------------------------------------------------------------'


def _emcvnx_get_text_perf(data, key, perfname, format_func=get_bytes_human_readable,
def _emcvnx_get_text_perf(data,
key,
perfname,
format_func=get_bytes_human_readable,
factor=1024**3):
field = data.get(key, "unknown")
try:
@@ -305,14 +305,14 @@ TempParamType = Optional[Union[TwoLevelsType, FourLevelsType, TempParamDict]]


def check_temperature(
reading, # type: Number
params, # type: TempParamType
unique_name, # type: Optional[AnyStr]
dev_unit="c", # type: AnyStr
dev_levels=None, # type: Optional[TwoLevelsType]
dev_levels_lower=None, # type: Optional[TwoLevelsType]
dev_status=None, # type: Optional[StatusType]
dev_status_name=None, # type: AnyStr
reading, # type: Number
params, # type: TempParamType
unique_name, # type: Optional[AnyStr]
dev_unit="c", # type: AnyStr
dev_levels=None, # type: Optional[TwoLevelsType]
dev_levels_lower=None, # type: Optional[TwoLevelsType]
dev_status=None, # type: Optional[StatusType]
dev_status_name=None, # type: AnyStr
):
# type: (...) -> CheckType
"""Check temperature levels and trends.
@@ -123,8 +123,8 @@ def perfometer_logarithmic_dual(value_left, color_left, value_right, color_right
return render_perfometer(data)


def perfometer_logarithmic_dual_independent\
(value_left, color_left, half_value_left, base_left, value_right, color_right, half_value_right, base_right):
def perfometer_logarithmic_dual_independent(value_left, color_left, half_value_left, base_left,
value_right, color_right, half_value_right, base_right):
data = []
data.extend(
calculate_half_row_logarithmic("left", value_left, color_left, half_value_left, base_left))
@@ -280,11 +280,11 @@ def _list_user_icons_and_actions():


def SNMPCredentials( # pylint: disable=redefined-builtin
title=None, # type: TypingOptional[Text]
help=None, # type: TypingOptional[Text]
only_v3=False, # type: bool
default_value="public", # type: Text
allow_none=False # type: bool
title=None, # type: TypingOptional[Text]
help=None, # type: TypingOptional[Text]
only_v3=False, # type: bool
default_value="public", # type: Text
allow_none=False # type: bool
): # type: (...) -> Alternative
def alternative_match(x):
if only_v3:
@@ -614,10 +614,10 @@ def passwordstore_choices():


def PasswordFromStore( # pylint: disable=redefined-builtin
title=None, # type: TypingOptional[Text]
help=None, # type: TypingOptional[Union[Text, Callable[[], Text]]]
allow_empty=True, # type: bool
size=25, # type: int
title=None, # type: TypingOptional[Text]
help=None, # type: TypingOptional[Union[Text, Callable[[], Text]]]
allow_empty=True, # type: bool
size=25, # type: int
): # -> CascadingDropdown
return CascadingDropdown(
title=title,
@@ -642,10 +642,10 @@ def PasswordFromStore( # pylint: disable=redefined-builtin


def IndividualOrStoredPassword( # pylint: disable=redefined-builtin
title=None, # type: TypingOptional[Text]
help=None, # type: TypingOptional[Union[Text, Callable[[], Text]]]
allow_empty=True, # type: bool
size=25, # type: int
title=None, # type: TypingOptional[Text]
help=None, # type: TypingOptional[Union[Text, Callable[[], Text]]]
allow_empty=True, # type: bool
size=25, # type: int
):
return Transform(
PasswordFromStore(

0 comments on commit 8194e8a

Please sign in to comment.
You can’t perform that action at this time.