# emit_startup_failure

> **Function** in `deepagents_code`

📖 [View in docs](https://reference.langchain.com/python/deepagents-code/_startup_error/emit_startup_failure)

Report a server graph startup failure to the parent app process.

Emits the full traceback for logs/debugging, then a
single-line `{STARTUP_ERROR_MARKER}{type}: {summary}` line that
`server._extract_startup_error_marker` parses to upgrade an opaque
"Server process exited with code N" into an actionable summary.
Known credential/package errors also include JSON recovery fields so the
client can restore their types without constructing a provider model.

## Signature

```python
emit_startup_failure(
    exc: BaseException,
) -> None
```

## Parameters

| Name | Type | Required | Description |
|------|------|----------|-------------|
| `exc` | `BaseException` | Yes | The exception raised during graph initialization. |

---

[View source on GitHub](https://github.com/langchain-ai/deepagents/blob/caaa7e7c12d214afa5cf0a1afed8eb6232aa6f7b/libs/code/deepagents_code/_startup_error.py#L104)