# acp_thread: Fix compaction button stuck at loading state on error \(\#59161\) · gitcafe/zed

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

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

Visibility: public

Requested revision: d8eb569cc5a823506142af3c09a1d65bb7279279

Requested commit: d8eb569cc5a823506142af3c09a1d65bb7279279

Commit: d8eb569cc5a823506142af3c09a1d65bb7279279

Tree: 76fe5d32d9b12dc3546792af0b8b218582f984ae

Author: Danilo Leal

Committer: GitHub

## Message

```
acp_thread: Fix compaction button stuck at loading state on error (#59161)

Closes AI-393

When the user proactively cancels a turn, we mark all pending entries as
cancelled. But if something else stops/halts a turn, we weren't doing
that in the case of compaction, which means we would be stuck in a
loading state forever.

Release Notes:

- N/A _(feature hasn't been publicly released yet so no notes)_
```

## Parents

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

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