petio-team / petio

Petio Request, Discover, Review
https://petio.tv
MIT License
251 stars 28 forks source link

MongoDB Connection Test on Initial Setup doesn't get interrupted when you change tab. #573

Closed rlaphoenix closed 2 years ago

rlaphoenix commented 3 years ago

Describe the bug The MongoDB Connection Test asks you to test on Docker, Raid, and "Other". (all differing preset ways to connect to MongoDB). The problem is let's say you are on Windows and accidentally start a test on Docker tab, then proceed to the "Other" tab for Windows. You have to wait for the connection test to finish (for Docker tab), it would then fail. A user may assume this failed for the Other tab, not for the Docker tab.

To Reproduce Steps to reproduce the behavior:

  1. Go to '/admin' on initial setup on a non-docker Machine (or just change the "Docker" tab in next steps to something else).
  2. Get to the MongoDB Connection Test.
  3. Click "Test" on the Docker tab.
  4. Proceed to the "Other" tab, and wait for the test to finish.
  5. The user may assume the test for "Other" tab failed, not the "Docker" tab test.

Expected behavior It would be expected that you cannot change the tab when a connection test is happening, or when you change tab cancel the test.

Screenshots N/A

Desktop (please complete the following information):

Smartphone (please complete the following information): N/A

Additional context N/A

AshDyson commented 2 years ago

This is a limitation of Mongoose the MongoDb driver we currently use. This may be resolved in the backend rebuild currently under way. The spinning circle also indicates the test is still in progress even when changing tabs so I wouldn't class this as a bug as Petio is still performing as expected.