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 - "#badcode"
-
A method that contains over 9000 lines of code.....
Are there really production codebases out there with stuff like that? If yes I am scared as hell because I don't want to work with that kind of code once I graduate
Tell your stories!19 -
I joined a "multi-national" company in middle-east where 90% of the developers are Indian. And since it's a "multi-national" company with 50+ developers I thought they already figured it out. Most of them have 5-10 years of experience. They should know at least how to use git properly, deployment should be done via CI/CD. database changes should be run via migration script. Agile methodology, Code Review - Pull Request. Unit testing. Design Patterns, Clean Code Principle. etc etc
I thought I'm gonna learn new things here. I have never been so wrong in all my life...
Technical Manager doesn't even know what Pull Request is. They started developing the software 4 years ago but used Yii v1 instead which was released almost a decade ago. They combined it with a VueJS where in some files contains around 4000 lines of code. Some PHP functions contain 500+ of code. No proper indentions as well. The web console is bloody red with javascript errors. In short, it's the worst code I've seen so far.
No wonder why they keep receiving complaints from their 30+ clients.10 -
Why would you submit a pull request with the addition of such a comment and expect me to approve? What the hell is wrong with you?
-
Your CC is safe with us.
Most likely dead code was included in 2013, never modified.
Someone was happy to use Wikipedia -
I wish I could share this code with y'all, holy moly, it's bad.
It stinks so much, it hurts.
And now I have to write more bad, stinky code to add a feature that will be used until this thing will get shut down by end of next quarter. Because trying to write good code in this thing is impossible.7 -
Fuck this I need to ventilate.
Thinking about job change because maintaining and extending 3 years old codebase (flask project) is FUCKIN exhausting. It was badly written since start by someone who obviously didn't know much about python. (Going by commit history.)
Examples:
- if var != None / if var == None
- if var is not None / if var is None (well..)
- Returning self-parsed obscure JSONs from dict variable
- Serializing dictionaries into database by str() (both sqlalchemy and mysql support JSON format) - THEY ARE ALMOST UNUSABLE OTHER WAY AROUND (luckily, python can deal even with that)
- celery tasks, the way they are called they BLOCK the whole flask (not bad in itself, but if connection breaks there are no errors, nothing it just hangs)
- obscure generator/yielding that contains return of flask's response in itself
- creating fifteen thousands of variables one by one where they would look so nicely as dict keys, and hey they are then both MANUALLY SERIALIZED into returning dict by "%s" (string formatting) [okey, some of them are objecst like datetime but MATE WTF]
- many, many more, PEP lint shall not pass
I would rather deal with fresh startup owners wanting me to program unicorns in one week then trying to extend and manage zombie-like projects.
Nothing personal against the firm I actually like the place.3 -
Why do big companies hire such loser engineers ??? I mean what the hell man. When you are hiring a fresher to code they should at least know how to apply/write a for loop. I once had a colleague who assigned each array element individually instead of writing a for loop and asked me why I refused to approve his stupid code. What do I reply to this ? It was so dumb, I could not articulate an answer.13
-
Today's software industry is crap!
Ok, a little clickbait tittle ;)
Today, a friend of mine sent me a great text about the laziness and complete lack of care for efficiency and simplicity in software development industry. I totally agree with the author, and encourage you guys to read it, and give it a deep thought:
http://tonsky.me/blog/...5 -
If the codebase quality drops below levels measurable by way of "WTFs per minute", determine further negative code quality by counting the amount of times per hour you wonder if you're in Hell and what exactly you did to deserve this torment
-
Developer annoyance number two: fixing or having to work with or around other people's crappy code with days-long headaches following.
-
my old game had this flow every time a client places an object:
Client A creates a new generic object, and attaches texture paths (yep, global paths are allowed), and... lua code as strings to it.
Client A sends the entire object list to the server
Server receives it, replaces it's own object list
Server copies the entire object list and sends it to all clients
Client A and Client B both receive the object list and replace their versions.
All clients see that the object contains some code as strings
They compile and store it, and then run every frame. UNSANDBOXED.
any client could make all other ones execute any code and i was proud of my idea! -
My company used to just let anyone write code for our customers. Now I am the official development department. I knew someone wrote something very similar to a new request I got from a customer, so I requested his code because I didn't want to rewrite everything. After seeing the code I changed my mind and I want to redo it from scratch.
-
After a massive refactoring of the DAO test aren't running after 6 hours of debugging and traceing I find what some "genius" left behind.He wrote direct database updates from the UI code. WTF? Who gave them git access?
-
The one thing I really don't like is when they give me buggy code to work on. I spend more time debugging than actually writing new stuff. Sometimes the bugs are hard to find to like someone writing a 500 line function that could have been separated into other tasks. This is what sucks about being a student, other students are simply unaware of their horrible code and yet they ask "Why'd I get a C in the final?"
The worst part is being assigned a random partner for a project and the person is absolutely clueless about the class.
Just things I've had to deal with and I'm sure most of us have as well1 -
Theacher said "write 100 times :"I'll not write bad code and also I'll use TDD "... but she specify how "7
-
That moment when you're working at a Parcel Service or Warehouse and realize you're being worked too hard..joke/meme joke badcode blueprints funny thingsgonewrong hilarious haha gamedev warehouse boxes wrong
-
Today a collegue ranted about that he needs 96 variables in his code and also for the database querys and told me that's not possible to do it without so many variables... I just thought wtf.. I definitely need a new job!
-
Was chilling with my team and remembering some very funny code issues (wasn't at the time) we inherited in a product... when we took control of the servers they were dead...
Code somewhat abbreviated... see why a few 100 of these could do that :)
public class Util
{
... lots of nonsense here...
public static DbConnection GetConnection()
{
conn = factory.CreateConnection();
conn.ConnectionString = this.connectionString;
conn.Open();
return conn;
}
}
try {
Util.GetConnection().DoThingsAndStuff();
}
finally {
Util.GetConnection().Close();
}