# x11: Improve error handling \(\#32913\) · gitcafe/zed

[View on GitCafe](https://git.cafe/gitcafe/zed/commit/aa1b2d74ee03395a449f5210e034ec145798be15)

Repository: [gitcafe/zed](https://git.cafe/gitcafe/zed)

Visibility: public

Requested revision: aa1b2d74ee03395a449f5210e034ec145798be15

Requested commit: aa1b2d74ee03395a449f5210e034ec145798be15

Commit: aa1b2d74ee03395a449f5210e034ec145798be15

Tree: ea3235860399a6738f13b46a8d3ad0d8aefff737

Author: Michael Sloan

Committer: GitHub

## Message

```
x11: Improve error handling (#32913)

Continuing this work from a while back in #21079, now greatly aided by
agent + sonnet 4. With this change, there are now only a few spots that
explicitly panic, though errors during initialization will panic.

Motivation was this recent user panic in `handle_event`, figured fixing
all this use of unwrap was a great use of the agent.

> called `Result::unwrap()` on an `Err` value: X11 GetProperty for
_NET_WM_STATE failed.

Release Notes:

- N/A
```

## Parents

- [90aa99bb14d2fcbfd6bbbc6de0fd0de812cdbecf](https://git.cafe/gitcafe/zed/commit/90aa99bb14d2fcbfd6bbbc6de0fd0de812cdbecf?format=markdown)

[Source at this commit](https://git.cafe/gitcafe/zed/tree/aa1b2d74ee03395a449f5210e034ec145798be15?format=markdown)
