whole-tale / dashboard

Whole Tale Dashboard
http://wholetale.org
MIT License
7 stars 2 forks source link

Fix "Run" button in "Run" view during error state #502

Closed bodom0015 closed 5 years ago

bodom0015 commented 5 years ago

Problem

Fixes an issue reported by @Xarthisius while reviewing #459. The inner .finally() was not being called due to a failure in the outer promise.

Approach

Reset disableStartStop and taleTransitioning when we encounter a failure.

How to Test

  1. Checkout and run this branch locally, rebuild the dashboard
  2. Login to the WholeTale Platform
  3. Navigate to Browse and launch as many Tales as possible
    • You should start seeing the "too many instances" errors appear
  4. Hover over a stopped Tale and click "View"
    • You should be taken to the Run view for the chosen Tale
  5. At the top-right, click the "Run" button
    • You should see an error message appear on the Interact tab
    • You should see the run button change to its error state - an exclamation icon and the word "Run" on a clickable button
    • You should NOT see an infinite spinner on the "Run" button
    • NOTE: Styling in this case can be adjusted to make the button red or something more prominent, if desired