@staticmethod
    def validate(value):
        try:
            return strutils.bool_from_string(value, strict=True)
        except __HOLE__ as e:
            # raise Invalid to return 400 (BadRequest) in the API
            raise exception.Invalid(e)
dataset/ETHPy150Open openstack/ironic/ironic/api/controllers/v1/types.py/BooleanType.validate