Details
-
AboutI've been in the business since quite a young age. Older colleagues have warned me about becoming ranty way too soon. They weren't wrong. Glad to have y'all right with me.
-
SkillsPython, Linux, Git, Postgres, MongoDB, pretty much whatever, except fancy frontend
-
LocationBelgrade, Serbia
-
Github
Joined devRant on 7/5/2016
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
-
This code review gave me eye cancer.
So, first of all, let me apologize to anyone impacted by eye cancer, if that really is a thing... because that sounds absolutely horrible. But, believe me, this code was absolutely horrible, too.
I was asked to code review another team's script. I don't like reviewing code from other teams, as I'm pretty "intense" and a nit-picker -- my own team knows and expects this, but I tend to really piss off other people who don't expect my level of input on "what I really think" about their code...
So, I get this script to review. It's over 200 lines of bash (so right away, it's fair game for a boilerplate "this should be re-written in python" or similar reply)... but I dive in to see what they sent.
My eyes.
My eyes.
MY EYES.
So, I certainly cannot violate IP rules and post any of the actual code here (be thankful - be very thankful), but let me just say, I think it may be the worst code I've ever seen. And I've been coding and code-reviewing for upwards of 30 years now. And I've seen a LOT of bad code...
I imagine the author of this script was a rebellious teenager who found the google shell scripting style guide and screamed "YOU'RE NOT MY REAL DAD!" at it and then set out to flagrantly violate every single rule and suggestion in the most dramatic ways possible.
Then they found every other style guide they could, and violated all THOSE rules, too. Just because they were there.
Within the same script... within the SAME CODE BLOCK... 2-space indentation... 4-space indentation... 8-space indentation... TAB indentation... and (just to be complete) NO indentation (entire blocks of code within another function of conditional block, all left-justified, no indentation at all).
lowercase variable/function names, UPPERCASE names, underscore_separated_names, CamelCase names, and every permutation of those as well.
Comments? Not a single one to be found, aside from a 4-line stanza at the top, containing a brief description of that the script did and (to their shame), the name of the author. There were, however, ENTIRE BLOCKS of code commented out.
[ In the examples below, I've replaced indentation spacing with '-', as I couldn't get devrant to format the indentation in a way to suitably share my pain otherwise... ]
Within just a few lines of one another, functions defined as...
function somefunction {
----stuff
}
Another_Function() {
------------stuff
}
There were conditionals blocks in various forms, indentation be damned...
if [ ... ]; then
--stuff
fi
if [ ... ]
--then
----some_stuff
fi
if [ ... ]
then
----something
something_else
--another_thing
fi
And brilliantly un-reachable code blocks, like:
if [ -z "$SOME_VAR" ]; then
--SOME_VAR="blah"
fi
if [ -z "$SOME_VAR" ]
----then
----SOME_VAR="foo"
fi
if [ -z "$SOME_VAR" ]
--then
--echo "SOME_VAR must be set"
fi
Do you remember the classic "demo" programs people used to distribute (like back in the 90s) -- where the program had no real purpose other than to demonstrate various graphics, just for the sake of demonstrating graphics techniques? Or some of those really bad photo slideshows, were the person making the slideshow used EVERY transition possible (slide, wipe, cross-fade, shapes, spins, on and on)? All just for the sake of "showing off" what they could do with the software? I honestly felt like I was looking at some kind of perverse shell-script demo, where the author was trying to use every possible style or obscure syntax possible, just to do it.
But this was PRODUCTION CODE.
There was absolutely no consistency, even within 1-2 adjacent lines. There is no way to maintain this. It's nearly impossible even understand what it's trying to do. It was just pure insanity. Lines and lines of insanity.
I picture the author of this code as some sort of hybrid hipster-artist-goth-mental-patient, chain-smoking clove cigarettes in their office, flinging their own poo at their monitor, frothing at the mouth and screaming "I CODE MY TRUTH! THIS CODE IS MY ART! IT WILL NOT CONFORM TO YOUR WORLDLY STANDARDS!"
I gave up after the first 100 lines.
Gave up.
I washed my eyes out with bleach.
Then I contacted my HR hotline to see if our medical insurance covers eye cancer.32 -
1. Customer wants X.
2. Developer delivers X.
3. Customer wants developer to change X to Y for free.
4. Developer demands money.
5. Customer gets mad.
6. Developer compares situation to ordering a hamburger, consuming it, and demanding a pizza for free because customer didn't like the hamburger.
7. Customer pays20 -
PM: We really need to solve this problem fast...
Me: So you want me to solve the element width or to reimplement the template?
PM: Yes! (and leaves before I can say anything)
Me: *poker face*4 -
Let's clarify:
* Github is not Git
* Android is not Java
* Unit test is not TDD
* Java is not OOP
* Docker is not Devops
* Jenkins is not CI
* Agile is not institutionalised total chaos
* Developer is not Printer Support52 -
For the first time that I can remember I see ordinary people everywhere are unhappy with windows. In XP through win8 days I'd see people complaining about one crash here or there, but most of the times you had to be more experienced to notice why windows sucks.
Now, this week I already heard three complaints of people wanting to back to windows 7.
And I feel so happy... I feel waves of joy growing in me, as I burst in a sarcastic, obscure laughter.
Why do?
Because somewhere deep inside I hate windows.
Not becausebthe great amounts of frustration I used to have with it. But because it's so crazy I don't even consider it an OS, but rather a patchwork.
Microsoft's code base must be so fucked up they don't even know what to it with anymore.
That's my idea at least.
Buy it's good to see ordinary people are getting fed up of windows. This might be a way one of my dreams will come true, the day which Microsoft will not be able to maintain Windows anymore, and I think it's not more than ten years until we reach this day.
As a final result, if one day windows really gets to die, I want to be present, but not unnarmed, so I can shoot it at least 15 times, just to make sure this piece of crap is already dead.
Bye2 -
Client had our company build them a site, they refused our hosting suggestions, and did not want any maintenance on their site.
They eventually left us as a client all together(they were getting other services so they occasionally got an edit or two) and sent several rude emails to delete their passwords so we wouldn't have access to their stuff anymore. I gladly gave the site over to the new company with a solid "good luck." I wanted nothing to do with this client anymore anyway.
Now I'm 9 months down the line and my AM sends me an email that the client wants maintenance. I'm already typing up a ranting email to tell them no, when I decide to check the site. There are WordPress php errors all over the site.
Idk what this other company did, but I want nothing to do with cleaning up someone else's screwups. If I were freelance, this would be a HUGE up charge.7 -
I was struggling to make advancements in my task because I was so oriented by the "more code means more work done"... I wasn't producing at all. Now that I grabbed a notebook and a pen and started to think things through, things are finally rolling. Sometimes it's 90% thinking and 10% coding. In addition to that, I can't even write spagetti code after getting a solid concept written in pen. I just hate that I spend so much time thinking until something good comes up. But hey now it's rollinnnnnn.undefined pen productivity less is more notebook efficient implementations mean more puzzles work smart not hard4
-
Every fucking time, I apply for a role that suits, NOT SOME SUPER SENIOR ROLE THAT REQUIRES HUGE FUCKING EXPERIENCE, I get an email "After careful consideration, we've decided not to move on" BITCH YOU HAVENT EVEN MENTIONED WHAT YOU HAVE "CAREFULLY" CONSIDERED, I HAVENT APPLIED FOR SOME SPECIAL SPACE SCIENTIST POSITION YA CUNT.10
-
"Apple, it just works"
People, we might have misinterpreted the "just"!
"Apple, it only works [the way Apple meant for it to work]"9 -
!rant
As seen on a marquee:
Tetris taught me that when you try to fit in, you will disappear.
#stayweird1 -
SWIFT!!!!! I understand that you're a relatively new language so I forgave you for all of your wrong doings..BUT WHAT THE FINGER IS THIS SHIT YOU HAVE IMPLEMENTED IN YOUR STRING DATATYPE? WHY THE FUCK CAN'T YOU FORM A CHARACTER FROM AN EMPTY STRING? AND WHAT THE ACTUAL FUCK HAPPENED TO THE SUBSCRIPT OPERATOR? WHY NOT JUST ADOPT THE "\0" AS OTHER LANGUAGES? But NOOOOO...We're Apple we'll not adopt it..I WAS UNDER THE IMPRESSION THAT STUPIDITY AND LUCK OF INNOVATION RAN IN THE IPHONE TEAM BUT APPARENTLY ITS EVERYWHERE..Its annoying because the String datatype is one of the most common and basic data types so the last thing you expect is this shit..APPLE........SERIOUSLY AND SINCERELY FUCK OFF4
-
When a newb asks you 'what's the difference between git and github?' rhetorically ask them 'What's the difference between porn and pornhub?'8
-
fuck you fucking Indian programmers, how it is possible that you are so fucking messy to code?, why can't you have some decency and write some readable code!, for fucks sake!
What really grind my gears, is that 90% of the project is built with dynamic Javascript, WTF????
Every component for every page is done in javascript while loading, seriously?, there wasn't a better way to do it? -.-
And SQL... oh dear fucking GOD!, I mean, how am I supposed to understand your code if you can't even use some alignment with TABS or spaces.
Better go to my lunch break so I can rethink my work to do tonight :(24 -
The Perfect Storm:
My worst coding mistake? Yeah, let me tell you about that. I pushed a simple JavaScript/HTML change without knowing that the stupid header was shared with another "not so important" section of the site called "My Account" where people go to pay for their services. I call it the perfect storm because I left early that Friday for a weekend cruise and right before leaving I pushed the change, sent the request to push for production and left. When they noticed that clients were complaining about not being able to pay they started reversing most changes of all teams trying to fix it but they never touched mine because they knew I wasn't working on the backend. My whole team worked over the weekend trying to find the issue while I was having fun in the cruise. They ended up reversing all changes by Sunday night and it took us about 4 more days to figure out that my simple JavaScript/HTML change broke the site and prevented 30 million customers from making payments that weekend plus it broke the whole 2nd release of the month.... yeah, nothing major.21 -
On his first week at job, the junior says:
Hey guys! Check out this new website I found! You'll thank me later.27 -
Messing with HTML/CSS for the first time. Gonna have a dropdown menu where it's empty in the header. JS(Jquery) will be used.7
-
Interviewed for a Q&A position.
Found bugs and errors on the test questions just fine.
Found broken assets and errors within the test itself outside of the questions. (Misspellings, typos, broken images, botched styling, etc.)
Didn't get hired because they thought I'd spend too much time finding bugs.
What gives?7 -
Co-worker that is awesome at copying and pasting and later asks for help cause something doesn't work.3