# Errors

## timenet.errors

TimeNet's exception hierarchy.

Every TimeNet-raised error derives from :class:`TimeNetError`. Validation and manifest errors also
derive from :class:`ValueError` so existing `except ValueError` handlers keep working. Builtin
`FileNotFoundError` / `FileExistsError` are still raised directly for user-supplied paths.

### DatasetNotFoundError

Bases: `TimeNetError`

A requested dataset id or version is not present in a registry or on disk.

### InvalidCardError

Bases: `TimeNetError`, `ValueError`

A dataset card YAML is malformed or fails schema validation (raised while curating).

### InvalidManifestError

Bases: `TimeFFormatError`, `ValueError`

A `manifest.json` is missing required blocks/fields or cannot be parsed.

### RegistryError

Bases: `TimeNetError`

A registry could not be loaded, reached, or served a request.

### TimeFEditError

Bases: `TimeFValidationError`

An edit would leave a dataset referentially inconsistent (e.g. a dangling reference).

### TimeFFormatError

Bases: `TimeNetError`

An on-disk TimeF artifact is corrupt or uses an unsupported format version.

### TimeFValidationError

Bases: `TimeNetError`, `ValueError`

A dataset or its arrays violate a TimeF invariant (raised while building or writing).

### TimeNetError

Bases: `Exception`

Base class for all TimeNet errors.
