Skip to content

refresh_view()/refresh_rows()/update_loading() don't re-sync ViewAction button state #23

Description

@gkennos

Pre-flight

  • I searched existing issues and this is not a duplicate.

Summary

Workbench.show_surface() calls show_actions(view.actions) to sync each ViewAction button's label/variant/disabled state, but the two in-place refresh paths used by refresh_view() never called show_actions()

when a page is rendered via show_view(), subsequent refresh_view() calls leave action buttons stuck at whatever state they had on first render, even if the view's actions change on every refresh

Reproduction

run a long job with a button

Actual behaviour

add self.show_actions(view.actions) to both refresh_rows() and update_loading() in src/groundskeeping/widgets/workbench.py

Expected behaviour

show_actions(view.actions) is called every time a view is refreshed so that downstream consumers don't need to keep calling refresh as per the old flickering refresh path

Error output

System info

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions