Import the app and return it. Exits on failure.
(self)
| 410 | logging.getLogger("uvicorn.access").propagate = False |
| 411 | |
| 412 | def load_app(self) -> Any: |
| 413 | """Import the app and return it. Exits on failure.""" |
| 414 | try: |
| 415 | return import_from_string(self.app) |
| 416 | except ImportFromStringError as exc: |
| 417 | logger.error("Error loading ASGI app. %s" % exc) |
| 418 | sys.exit(1) |
| 419 | |
| 420 | def load(self) -> None: |
| 421 | assert not self.loaded |
no test coverage detected