# installed_debug_log_path

> **Function** in `deepagents_code`

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

Return the path of the active debug log file, or `None` if not logging.

Reflects the file handler actually attached by `configure_debug_logging`,
not the current `DEEPAGENTS_CODE_DEBUG` env value. The two diverge when the
variable is set after import — e.g. via a project/global `.env` loaded during
settings bootstrap — in which case the variable reads truthy but no handler
was installed and no log file exists. Callers that surface "full error in
<path>" hints must use this rather than the env var to avoid pointing users
at a file that was never created.

## Signature

```python
installed_debug_log_path() -> Path | None
```

---

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