Join devRant
Do all the things like
++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatar
Sign Up
Pipeless API
From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple API
Learn More
Search - "wk351"
-
Craziest bug, not so much in the sense of what it was (although it was itself wacky too), but in what I went through to fix it.
The year was 1986. I was finishing up coding on a C64 demo that I had promised would be out on a specific weekend. I had invented a new demo effect for it, which was pretty much the thing we all tried to do back then because it would guarantee a modicum of "fame", and we were all hyper-ego driven back then :) So, I knew I wanted to have it perfect when people saw it, to maximize impressiveness!
The problem was that I had this ONE little pixel in the corner of the screen that would cycle through colors as the effect proceeded. A pixel totally apart from the effect itself. A pixel that should have been totally inactive the entire time as part of a black background.
A pixel that REALLY pissed me off because it ruined the utter perfection otherwise on display, and I just couldn't have that!
Now, back then, all demos were coded in straight Assembly. If you've ever done anything of even mild complexity in Assembly, then you know how much of a PITA it can be to find bugs sometimes.
This one was no exception.
This happened on a Friday, and like I said, I promised it for the weekend. Thus began my 53 hours of hell, which to this day is still the single longest stretch of time straight that I've stayed awake.
Yes, I spent literally over 2+ days, sitting in front of my computer, really only ever taking bio breaks and getting snacks (pretty sure I didn't even shower)... all to get one damn pixel to obey me. I would conquer that f'ing pixel even if it killed me in the process!
And, eventually, I did fix it. The problem?
An 'i' instead of an 'l'. I shit you not!
After all these years I really don't remember the details, except for the big one that sticks in my mind, that I had an 'i' character in some line of code where an 'l' should have been. I just kept missing it, over and over and over again. I mean, I kinda understand after many hours, your brain turns to mush. and you make more mistakes, so I get missing it after a while... but missing it early on when I was still fresh just blows my mind.
As I recall, I finally uploaded the demo to the distro sight at around 11:30pm, so at least I made my deadline before practically dropping dead in bed (and then having to get up for school the next morning- D'oh!). And it WAS a pretty impressive demo... though I never did get the fame I expected from it (most likely because it didn't get distributed far and wide enough).
And that's the story of what I'd say was my craziest bug ever, the one that probably came closest to killing me :)5 -
If user was on the right screen, and if random error dialog happened to show, it would delete his account.
For example, if user got "Server error, please try again later", it would delete his account, after dismissing dialog.
Luckily it didn't make it to production.7 -
My boss back in 2013 asked me to figure out why he was getting birthday notifications from his pet social media project almost a week early. It turns out the previous developers had written their own date library in which every month had exactly 30 days, leading to a year that was 5–6 days short of what it should have been. Apparently those morons didn’t know that some months have a different number of days than others. Or that leap years are a thing. Or that there’s a standard library full of tried-and-true functions that handle these kinds of things for you.5
-
JS Console: user_name is undefined
Señor Dev: can't be the API response has it!
The API response: usre_name8 -
I don't know if it's the craziest, but once we had an issue with a new release that caused a few forms inside the application to launch with a different scale, resulting very small on 4K monitors.
It turned out the issues were caused by importing "System.Windows" in a new module.2 -
Crazy... Hm, that could qualify for a *lot*.
Craziest. Probably misusage or rather "brain damaged" knowledge about HTTP.
I've seen a lot of wild things when devs start poking standards, but the tip of the iceberg was someone trying to use UTF-8 in headers...
You might have guessed it - German umlauts. :(
Coz yeah. Fucktard loved writing everything in german, so why not write custom header names in german.
The fun thing is: It *can* work, though the usual sane thing is to keep it in ASCII range for the obvious reason that using UTF-8 (or ISO-8859-1, which is *not* ASCII) is a gamble you gonna loose.
The fun game was that after putting in a much needed load balancer between services for monitoring / scaling etc suddenly *something* seemed off.
It took me 2 days and a lot of Wireshark hoola hooping to find out why, cause the header was used for device detection aka wether it's a bot or not. Or in the german term the dev used: "Geräte-Art".
As the fallback was to assume a bot, but only rate limit based on IP, only few managed to achieve the necessary rate limit to get blocked.
So when I say *something* seemed off, I really mean a spooky kind of "sometimes IP blocked for seemingly no reason at all".
Fun stuff. The dev btw germanized everything. Untangling the code base was a lot of non fun. -.-6 -
Some days I feel like I really know what I am doing and today was not one of these days...
Working on a game engine using Vala and now using Raylib in the backend for rendering and input.
Wrote a VAPI for Raylib and when I was doing the 'Rectangle' struct... I made it's members integers when they are floats...
So this whole time; when using a camera everything would jitter like crazy.... because I was taking the transform which is all floats... rounding it then casting to an int only for the int to be cast into a float again....
Lo and behold; changing the members to floats and removing the rounding and casting makes everything silky smooth...
I have been debugging every bit of my current render loop trying to work this out when it was 100% unrelated.... I hate myself sometimes1 -
I ranted about it already.
```c++
if (vec.size() > 0) { // or whatever
cout << vec.size();
// ....
}
```
Its output was zero. And before you ask, it was a single thread program.
Aince it was for my thesis and I was in a hurry I didn't care too much for it.
Yet I think that it was a bug in clang. I removed that piece of code, compiled, rewritten it a bit differently and worked as expected. Never looked back.9 -
I upgraded a Linux server one time and data that was serialized in yaml stopped being parsed properly.
It turns out the libyaml people decided to change how hashes were handled, which made any previous hashes come back as blank.
A whole database of valid data in dev was coming back invalid in prod. It was maddening.
It took a day to figure out the problem and how to update the data to the new format in rails.
I now serialize in json.11 -
Worked on a HR system where someone needed to add an 8th dependent and the system gave an error. I took a look and found the problem: The dependent table was designed with a set of columns for each dependent…like this, DepFirstName1,2,3,etc. That was fun to explain.2
-
I was refactoring a 4000 lines JavaScript file, turning whatever I could into components. It was a pretty old project that I ended up being one of the few wizards to actually know how most of it works.
At one point, I noticed that login into a user account redirected us to the dev-test server, even when working on a local Docker container.
I never quite understood the issue, but ended up having the bug mysteriously disappear.
Until it came back two months later, then disappeared again.
At one point, all of the dev team on the project (four developers, me included, and one project manager) was investigating the issue, and we never figured out how or why this was happening.
Just Symfony routes shenanigans I guess.15 -
That was in the digitally-controlled analog equalizer I worked on (and still AM working on) with my dad, we kept sending something through the SPI line that was consistently sending clown vomit and corrupted data to the display and as a result my whole code was hanging and bootlooping like crazy.
The fix? No idea! Because I had (and still don't have) ANY step-based debugging, all I could do is try multiple ideas and see if one of them would stick. That ended up being the solution.
I still have a video of this issue, I just need to find it. I will post it here when I have it.3 -
Someone didn’t properly set the httpcookies domain for our staging and production websites. Yep, this was a C#/.NET site. The cookie domain for the staging site was set to the production domain instead of the staging domain (which was a subdomain). So if someone logged into the staging admin, that would also grant them access to production admin if they also had an account in the production site.
The staging site technically had an additional login to enter the site, but the username and password weren’t too hard to guess. It was like that for years until I was hired to be an in-house dev (the role was previously outsourced to a software development company).
The admin side of the website wasn’t very sophisticated. But there was enough personal identifying info for a hacker to do something with.
I don’t know how they weren’t hacked yet. Honestly, I’d tell my employer to go back to that software agency and ask for a refund and cite the shotty work.2