---
title: RunHookTimeout
description: "A timeout for the run, resume, suspend, or terminate hook: 1..=60 seconds."
---

```python
@final
class RunHookTimeout
```

A timeout for the `run`, `resume`, `suspend`, or `terminate` hook: 1..=60 seconds.

A distinct class from \[`PyBuildHookTimeout`] and deliberately not interchangeable with
it — see the module docs.

## Constructor

```python
RunHookTimeout(seconds: SupportsIndex)
```

A run-family timeout, or a refusal naming **both** ceilings.

The message names the other family's limit too, because the caller who hits this is
nearly always someone who picked a build-hook number: telling them 60 is the limit
answers a question they did not ask.

## Properties

### `seconds`

```python
seconds: int
```

## Attributes

### `MAX_SECS`

```python
MAX_SECS: Final[int]
```

The service ceiling for this family: 60.

## Special methods

### `__repr__`

```python
def __repr__() -> str
```

### `__str__`

```python
def __str__() -> str
```

## Provenance

This page is generated from `bindings/microvms-py/microvms.pyi` by Griffe 2.3.0, run from `site/scripts/gen-reference.mjs` on every `pnpm run sync`, so an edit made here is overwritten by the next run.

To change the page, change the doc comment in the binding's Rust source, then regenerate the declarations with `mise run stubs`. `mise run stubs:check` fails when the committed file no longer matches the source.