DEV Community

Discussion on: What's the longest you've ever spent debugging a single bug?

Collapse
 
geirawsm profile image
geirawsm

Not specifically a bug, but hear me out.

Me and a colleague found out that we want to make a tool specific for our work. We're both into programming and seem to know our stuff, but is not our primary work tasks and we're not hired as such. Pretty easy stack tbh: sql and php. He did backend, I did frontend.

I set up sql-server locally with all the correct tables and got my colleague's code and started my tweaking.
At first I was having some issues with running the php-site directly through php -S localhost:8000 . and connecting to the database. Having some experience with programming in Python and knowing that a clean environment is the best environment, I thought why not just make a clean virtual machine with ubuntu server and XAMPP. Set it up with a NAT network adapter and forwarded ports from localhost to the VM. The I installed the newest Ubuntu Server and started coding on that instead.

But I experienced the same issue.

Start DBeaver to check out the db, yep seems fine, the db and tables are all there and looks great. I have another go. Same issue.
As a dirty fix, I started coding directly on the staging/prod-server just to make sure that my changes are working as intended. They do, and gradually it crawls to a completion.

It's only after two months and about 200 commits later I realise that I never stopped the local sql-server running on my machine and changing the host and credentials to the sql-server.

It was the same database the whole time 🤦‍♂️