# DistributionVersion

> **Class** in `deepagents_code`

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

Structured version facts for a single installed distribution.

Separates three facts that are easily conflated: the live version read from
the running source, whether imported or parsed (`source_version`), the
version recorded in the installed distribution metadata (`metadata_version`),
and whether the install is editable (with its `source_path`). `status`
records whether the metadata lookup succeeded so diagnostic callers can
distinguish a genuinely absent package from an unexpected lookup failure.

## Signature

```python
DistributionVersion(
    self,
    name: str,
    source_version: str | None,
    metadata_version: str | None,
    editable: bool,
    source_path: str | None,
    status: DistributionMetadataStatus,
)
```

## Constructors

```python
__init__(
    self,
    name: str,
    source_version: str | None,
    metadata_version: str | None,
    editable: bool,
    source_path: str | None,
    status: DistributionMetadataStatus,
) -> None
```

| Name | Type |
|------|------|
| `name` | `str` |
| `source_version` | `str \| None` |
| `metadata_version` | `str \| None` |
| `editable` | `bool` |
| `source_path` | `str \| None` |
| `status` | `DistributionMetadataStatus` |


## Properties

- `name`
- `source_version`
- `metadata_version`
- `editable`
- `source_path`
- `status`
- `primary_version`
- `has_drift`

---

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