Exception raised by `RequestHandler.get_argument`. This is a subclass of `HTTPError`, so if it is uncaught a 400 response code will be used instead of 500 (and a stack trace will not be logged). .. versionadded:: 3.1
| 2442 | |
| 2443 | |
| 2444 | class MissingArgumentError(HTTPError): |
| 2445 | """Exception raised by `RequestHandler.get_argument`. |
| 2446 | |
| 2447 | This is a subclass of `HTTPError`, so if it is uncaught a 400 response |
| 2448 | code will be used instead of 500 (and a stack trace will not be logged). |
| 2449 | |
| 2450 | .. versionadded:: 3.1 |
| 2451 | """ |
| 2452 | |
| 2453 | def __init__(self, arg_name: str) -> None: |
| 2454 | super().__init__(400, "Missing argument %s" % arg_name) |
| 2455 | self.arg_name = arg_name |
| 2456 | |
| 2457 | |
| 2458 | class ErrorHandler(RequestHandler): |