Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Panel button.loading not working perfectly #3233

Closed
govinda18 opened this issue Mar 10, 2022 · 2 comments
Closed

Panel button.loading not working perfectly #3233

govinda18 opened this issue Mar 10, 2022 · 2 comments

Comments

@govinda18
Copy link
Contributor

ALL software version info

panel==0.13.0a38

Description of expected behavior and the observed behavior

The panel button.loading=True is not working as expected in deployed app. It works fine in a jupyter notebook though. Check the gif below:

panel-button-loading-bug

Complete, minimal, self-contained example code that reproduces the issue

  def app():
      hint_box = pn.pane.Alert('Ready')
      submit_button = pn.widgets.Button(name='Submit', width=100)

      def on_click(event):
          submit_button.loading = True
          hint_box.object = 'Loading'
          hint_box.alert_type = 'warning'

          time.sleep(5)

          submit_button.loading = False
          hint_box.object = f'Clicked {submit_button.clicks} times'
          hint_box.alert_type = 'primary'

      submit_button.on_click(on_click)
      return pn.Column(hint_box, submit_button)

  app().servable()

Stack traceback and/or browser JavaScript console output

No errors thrown

Screenshots or screencasts of the bug in action

Added above

@philippjfr
Copy link
Member

Could you try again with 0.13.0a42? I think #3231 should have addressed this.

@govinda18
Copy link
Contributor Author

Thanks @philippjfr this is indeed fixed, sorry for the delayed response.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants