entropy-lab / entropy

BSD 3-Clause "New" or "Revised" License
30 stars 13 forks source link

Dashboard - Re-enabling hot reload using "hupper" #191

Closed urig closed 2 years ago

urig commented 2 years ago

This PR resolves issue https://github.com/entropy-lab/entropy/issues/186.

The issue was that the Entropy Dashboard was not "hot reloading" itself when code files (such as user generated Python files containing PlotGenerator classes). The reason for this was that we've switched from serving the Dashboard using Dash's built-in Flask server to serving using waitress and this made "hot reloading" fail somehow.

This PR re-introduces hot reloading using the hupper monitoring library.

Acceptance test:

  1. Run the Dashboard on a database where you have an experiment plotted with a custom PlotGenerator class.
  2. Make a change to the PlotGenerator code that should be visible in the Dashboard.
  3. Observe that the Dashboard browser page refreshes itself within 1-5 seconds and the change is visible.
github-actions[bot] commented 2 years ago

Unit Test Results

    1 files      1 suites   51s :stopwatch: 194 tests 190 :heavy_check_mark: 4 :zzz: 0 :x:

Results for commit 76b4da55.

:recycle: This comment has been updated with latest results.