| 396 | self.event_stream = None |
| 397 | |
| 398 | def _assert_valid_value(self, value): |
| 399 | if not (value in [True, False, float("inf"), -float("inf")]): |
| 400 | value = str(value) |
| 401 | if len(value) > self.length_limit: |
| 402 | raise (exceptions.InvalidCloudValue(f"Value exceeds length limit: {str(value)}")) |
| 403 | if not self.allow_non_numeric: |
| 404 | x = value.replace(".", "") |
| 405 | x = x.replace("-", "") |
| 406 | if not (x.isnumeric() or x == ""): |
| 407 | raise (exceptions.InvalidCloudValue("Value not numeric")) |
| 408 | |
| 409 | def _enforce_ratelimit(self, *, n): |
| 410 | # n is the amount of variables being set |