# PollingTaskRunner.RunForever

```go
func (*PollingTaskRunner) RunForever(ctx context.Context) error
```

Run the polling runner continuously, polling for tasks when idle.

## Parameters

**ctx**

`context.Context`

required: true

The context controlling the polling loop lifetime.

## Returns

An error if the polling loop fails.

```go title="Go"
if err := runner.RunForever(ctx); err != nil {
    return err
}
```
