The Debugging of a Frustrating Error that solved by itself

Hello,

Welcome to another article. In this article, I will talk about an error that I faced & I tried my best to fix it but the error was not fixed. In the en, the error was fixed by itself :-)

About the project

I participated in a web competition. It was CodinGuru 5.0 & I have to make MVP of a website. I have to implement Maps on the website. First I thought of using Google Maps API, but Google Maps API is PAID & its trial version requires a credit card and I don't have one. So I switched to MapBox, an alternative to Google Maps. I used REACT JS as the front end, Mapbox for showing Maps & Firebase for the database.

I had 2 days to complete the MVP of the website & then present it. So I gave all of my time to completing the website. I implemented the MapBox and Maps was showing on the website. Then I moved on to other features of the website.

Error in the website

Before presenting it, I need to deploy it & have to present the deployed version. I used Netlify to deploy it. After deploying it, I opened the website and saw that the map was not showing on the website. Also there was no error on console.

My process of solving the error

So like always, I searched on the internet & found that I need to downgrade the MapBox package as there are some issues with current version of Mapbox in production. So I reinstall the package, build the bundle again & reupload the website to netlify. Now the website stopped working completely :-) & I was doing this debugging 30 minutes before presenting it.

I tried my best to make the website work like previously but I don't know the reason why the website was not working. There were no errors on the console. So I was trying to fix the error & I don't know the cause of it :-)

I changed the API key, and change the code but nothing worked. The map was working perfectly in the development server but not in production.

How the Error was solved

I was not able to solve the error. Now there was our turn of presenting the website. I got up as I was sitting on the floor solving the error :-)

I got up & open the laptop again & saw the map was showing on the website. I error was fixed. I don't know what was the cause of the error & how the error was solved.

That's the story of a frustrating bug that was fixed by itself :-)

If you like my story, then comment on your story. Give a reaction to the article & I will see you in the next one :-)