# Fix blame hover popover not showing on first trigger when inline blame is disabled \(\#50769\) · gitcafe/zed

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

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

Visibility: public

Requested revision: c4a9b1aa4bb64497b4eef84fb7f2c5988bd6c53b

Requested commit: c4a9b1aa4bb64497b4eef84fb7f2c5988bd6c53b

Commit: c4a9b1aa4bb64497b4eef84fb7f2c5988bd6c53b

Tree: 330031fa608d12014253b389bf8392912febcd59

Author: João Soares

Committer: GitHub

## Message

```
Fix blame hover popover not showing on first trigger when inline blame is disabled (#50769)

● Closes #50285

## Summary

When `inline_blame` is disabled in settings and `editor::BlameHover` is
triggered,
the blame popover fails to appear on the first invocation because
`start_git_blame`
kicks off an async task to fetch blame data, but `blame_hover`
immediately tries to
read that data synchronously before it's available.

This fix registers a one-shot observation on the blame entity when it's
freshly
created, so the popover is shown once blame data has finished
generating.

Before you mark this PR as ready for review, make sure that you have:
- [x] Added a solid test coverage and/or screenshots from doing manual
testing
- [x] Done a self-review taking into account security and performance
aspects
- [ ] ~Aligned any UI changes with the [UI
checklist](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist)~
(No UI changes)

## Videos:
### Before:

https://github.com/user-attachments/assets/d2ca4f8e-8186-49af-9908-5a82bfca0de2


Ps: pressed the keybind two times

### After:

https://github.com/user-attachments/assets/08575cd9-2bbc-462d-92fa-f0e7ef23d8d6



## Release Notes:

- Fixed blame hover popover not appearing on first trigger when inline
blame is disabled (#50285)

---------

Co-authored-by: Chris Biscardi <chris@christopherbiscardi.com>
```

## Parents

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

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