Change `CompletionView.on_clear_completion_selection()` to call the Qt selection model getter, instead of our one. Since it can be called when the selection model has already been cleared and our one asserts that there is a selection model to return. Back in the distant past there was a change to handle the completion widget's selection model being None when the `on_clear_completion_selection()` slot was called: https://github.com/qutebrowser/qutebrowser/commit/88b522fa167e2f97b More recently a common getter for the selection model was added so we could have a single place to apply type narrowing to the returned object from the Qt getter (the type hints had been updated to be wrapped in `Optional`): https://github.com/qutebrowser/qutebrowser/commit/92dea988c01e745#diff-1559d42e246323bea35fa064d54d48c990999aaf4c732b09ccd448f994da74cf It seems this is one place where it does, and already did, handle that optional. So it didn't need to change to use the new getter. This is called from the `Command.on_mode_left` signal, not sure why the selection model is None here. Perhaps it already gets cleared by the effects of the `hide_cmd` signal that gets fired earlier, or perhaps even from the `self.hide()` on the line before. Anyway, this was working for several years and seems harmless enough. |
||
|---|---|---|
| .. | ||
| end2end | ||
| helpers | ||
| manual | ||
| unit | ||
| conftest.py | ||
| test_conftest.py | ||