MCPcopy Create free account
hub / github.com/TactilityProject/Tactility / get_boolean_property_or_false

Function get_boolean_property_or_false

device.py:77–82  ·  view source on GitHub ↗
(properties: ConfigParser, group: str, key: str)

Source from the content-addressed store, hash-verified

75 return get_property_or_default(properties, group, key, None)
76
77def get_boolean_property_or_false(properties: ConfigParser, group: str, key: str):
78 if group not in properties.sections():
79 return False
80 if key not in properties[group].keys():
81 return False
82 return properties[group][key] == "true"
83
84def safe_int(value: str, error_message: str):
85 try:

Callers 3

write_usb_variablesFunction · 0.70
write_usbhost_variablesFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected