diff --git a/CHANGELOG.md b/CHANGELOG.md index e0da63d0a..041976d33 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -12,6 +12,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/). - Fixed zero division error https://github.com/Textualize/textual/issues/2673 - Fix `scroll_to_center` when there were nested layers out of view (Compositor full_map not populated fully) https://github.com/Textualize/textual/pull/2684 +- Fix crash when `Select` widget value attribute was set in `compose` https://github.com/Textualize/textual/pull/2690 - Issue with computing progress in workers https://github.com/Textualize/textual/pull/2686 - Issues with `switch_screen` not updating the results callback appropriately https://github.com/Textualize/textual/issues/2650 diff --git a/src/textual/widgets/_select.py b/src/textual/widgets/_select.py index 2038a46a5..ce667f526 100644 --- a/src/textual/widgets/_select.py +++ b/src/textual/widgets/_select.py @@ -273,6 +273,7 @@ class Select(Generic[SelectType], Vertical, can_focus=True): self.prompt = prompt self._initial_options = list(options) self._value: SelectType | None = value + self._options = options def set_options(self, options: Iterable[tuple[RenderableType, SelectType]]) -> None: """Set the options for the Select.