Tell about stupid and funny programming mistakes you have made

Okay… I’ll start. I was trying to create a “This site uses cookies” pop-up on a web page. I was able to get it working in every other browser, such as all mobile browsers and most desktop browsers like Firefox and Safari, but not in Chrome. No matter what I did, that cookie element did not show up visible in Google Chrome. I spent days trying to figure out how to get it to work in Google Chrome. Even AI could not tell why it wouldn’t work.

Then I finally figured it out:

A few weeks back, I installed some fancy extension on my trusty Chrome browser. That automatically blocks and hides all cookie pop-ups from web pages. I had completely forgotten about this extension.

Oh, the days I wasted, chasing after a phantom issue that was never there! But hey, at least now I know that my coding skills weren’t to blame.
:face_in_clouds: :sweat_smile:

12 Likes

i once spent two and a half hours trying to debug a program and the issue was that i had reversed x and y values of coordinates. sure felt stupid.

7 Likes

I once spent days trying to upgrade a Repl to a newer version of python for one function. I ended up stealingprogramming the function myself instead. I then also had to move the project across Repls because I broke the original one in the process.

6 Likes

That’s happened to me too lol

3 Likes

Often I assume completely random things about programming languages then randomly google it and find out that I was incorrect, like once I thought JS didn’t have classes :skull:

3 Likes

What!! No classes!! :exploding_head:

3 Likes

I’ve had an idea to code something, looked at my previous projects to use as a base for the code, and realised I’ve had the same idea before, and already coded it. :sweat_smile:

6 Likes

In a Django project, I realized that the “objects” that were showing up were going like “model_name object(1)”, and I added the __str__ to the wrong class in the wrong file in the wrong directory.

3 Likes

Not knowing too much about coding is a mistake

2 Likes

I spent about 30 min trying to fix an error that had to do with the curly brackets ( {} ) not linking up with the right function. I undid the debugging I did, and it fixed itself.
image

8 Likes

Javascript with the semi colons, I always forget them.

4 Likes

they’re not needed, though

3 Likes

It’s so weird that they’re not needed

3 Likes

Python’s the same way, although it used to be like JS semicolons were required and Python semicolons would error

2 Likes

@QwertyQwerty88 thats why its even dumber LOL.

2 Likes

i was debugging for literal hours when i realized i made not one but THREE of the same typo… it didnt work after i fixed the typos anyway

1 Like

Always,always writing for(int i=0;… in javascript and python!
And always writing self in JS and this in python.
I guess that I’m an inductor.(ee pun)

2 Likes

When I’m done programming, I check my program and add missing semi-colons and only then close the tab.

2 Likes

I have worked on a manual encryption esolang for half a year and many stupid error I have made during it lol, including but not only:

Coded an entire main function, and somehow forgot to call main(), published 3 versions in both replit, GitHub and pypi before noticing this error

in an encrypt module I made it so that it shifts places, and in my decrypt module I never shift it back and wonder why it fails to decrypt, struggled for one and a half month before noticing I forgot to shift it, got multiple wrong output including a face from here

Yep I’m always stupid when sitting and code, until I got to the washroom and sit on the toilet for 2.718281828 seconds

3 Likes

Once I had to unindent hundreds of lines in one of my programs, I knew you could select a bunch of text and press tab to indent it but I never knew how to do the opposite, so I just did it manually, which takes forever. This has happened to me so much when I discovered you could just press shift-tab I kept thinking about how much time I wasted just unindenting code

Also typing semicolons in python

Also building a project, and your friend telling you they are making/have made the exact same thing. (Although I love it when you build a project that they’ve been thinking about and they have even started building it yet)

Also any sort of collaboration (your friends end up doing their own thing and you are left on your own with a giant project)

7 Likes