# tmux.MissingTargetError

- **Module:** tmux
- **Package:** github.com/libtmux/libtmux-go/tmux
- **Language:** Go
- **Kind:** struct
- **Source:** https://github.com/libtmux/libtmux-go/blob/52968a3181c1c9e6d1b26c565d4b170968ae61c0/tmux/target.go#L46
- **Page:** https://libtmux.org/en/go/latest/reference/tmux-missingtargeterror/

MissingTargetError reports an operation attempted on a zero-value model identity. It matches [ErrMissingTarget] through errors.Is; callers can recover Object with errors.As.

A relation accessor such as [Session.ActiveWindow] or [Session.Windows]
returns ok false rather than a value with no id, and a creation call such
as [Server.NewSession] carries no relations at all - so using a discarded
or freshly created value's zero-value fields reaches this error on the
first operation. Resolve live state with a Resolve* method or a fresh
[Server.Snapshot] instead.

## Members

- `Object` (attribute): Object names the tmux object kind with no id: "session", "window", "pane", or "client".
- `Error` (method): Error implements error.
- `Unwrap` (method): Unwrap makes MissingTargetError compatible with ErrMissingTarget.
