WikiEduDashboard icon indicating copy to clipboard operation
WikiEduDashboard copied to clipboard

Wrong display of error message "There was an error: Internal Server Error"

Open omChauhanDev opened this issue 2 years ago • 4 comments

What is happening?

As an instructor whenever we try to add any available article in our program, we go to the available articles section inside our program where after providing the title or url of the desired article in the input field, we click on the "Add Articles" button, then instead of displaying that our article is added successfully it show an error message "There was an error: Internal Server Error"

Not only this, after that as we refresh our page we will find that there is no error and our desired article got added successfully.

To Reproduce

Steps to reproduce the behavior:

  1. Go to My Dashboard section in "http://localhost:3000/"
  2. Click on any of your program
  3. Then click on Articles Section which is in your program navbar
  4. Click on the "Available Articles" tab
  5. Click on the "Add available articles" button
  6. Add your desired article title or url. Note: This should be one per line.
  7. Click on "Add articles"

Expected behavior

The right behavior is when we click on the "Add Articles" button it should automatically repaint the required component and render our desired article instead of displaying that error message or if there is any genuine error which is displaying that message then it should be fixed.

Screenshots

Before clicking on "Add Articles" button

Before Clicking on button

After clicking on "Add Articles" button

Screenshot from 2023-12-31 09-50-27

After refreshing the page

Screenshot from 2023-12-31 09-51-44

System Information

  • OS: [Fedora Linux]
  • Browser [e.g. brave]
  • Version [39]

omChauhanDev avatar Dec 31 '23 04:12 omChauhanDev

@om-chauhan1 what error appears in the server console when this happens? I'm not clear about whether this is a bug that can occur in production, or if it's related to your dev environment.

ragesoss avatar Jan 02 '24 18:01 ragesoss

Through this attached video i have shown both of these errors that appears on ui and console while adding and removing articles in a program.

Recording of issue of "Internal Server Error".webm

omChauhanDev avatar Jan 06 '24 04:01 omChauhanDev

In the video, you're showing the browser console error. There will be more details about the initial error in the rails server console (typical in the terminal where you are running guard or rails s). This is an error that has occurred in the Ruby backend, but we can't tell what exactly went wrong from the JS side.

ragesoss avatar Jan 08 '24 17:01 ragesoss

Yes i understand your point, here is video showing what is happening in the console of rails server.

https://github.com/WikiEducationFoundation/WikiEduDashboard/assets/119471995/c50c3171-0018-47c4-9750-b7f016ac3a56

omChauhanDev avatar Jan 13 '24 01:01 omChauhanDev