Wrong display of error message "There was an error: Internal Server Error"
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:
- Go to My Dashboard section in "http://localhost:3000/"
- Click on any of your program
- Then click on Articles Section which is in your program navbar
- Click on the "Available Articles" tab
- Click on the "Add available articles" button
- Add your desired article title or url. Note: This should be one per line.
- 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
After clicking on "Add Articles" button
After refreshing the page
System Information
- OS: [Fedora Linux]
- Browser [e.g. brave]
- Version [39]
@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.
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.
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.
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