Live data from Hacker News

How good engineers write bad code at big companies

seangoedecke.com

41–50 of 333 posts

Re: How good engineers write bad code at big companies

#41
post #24

You have to realise there is a almost full complete disconnect between engineering and business value

* Product folks over-promise

* Engineers are consulted for estimates to facilitate long-term planning

* Middle management slashes those estimates in half due to pathological myopia

* Executives enforce musical chairs to assert their authority

* Consultants muck everything up while collecting enormous payouts

And yet the business cycle keeps cycling.

Re: How good engineers write bad code at big companies

#42
post #30

Earlier quoted context omitted.

It's popular to mock aerospace engineering, but it's usually quite robust. Even if people still sometimes make bad decisions.

And move slowly. So when things turn bad, they will be bad for a decade - or more. See Boeing.

Boeings (software) issues stem from a removal of their Engineering skillset and replacing it with an outsourcing model don't they?

Re: How good engineers write bad code at big companies

#43
post #24

You have to realise there is a almost full complete disconnect between engineering and business value

Ime, a lot of the onus falls on Engineering and Product Management failing to make a case for why certain engineering decisions (eg. Investing in continual tech debt grooming) have business value. The point of a business is to generate revenue. The point of employees is to do work that helps generate revenue. As such, any decision needs to ensure it has a business case aligned with revenue generation. Good engineerin…

I work for some event ticketing business and I'd sign this. My bosses want features quickly. Does not matter to them if I need extra time to make stuff secure, doesn't matter to them if it wont scale. Its about short term revenue. Can always rebuild the software to fit the next short term goal...

Re: How good engineers write bad code at big companies

#44
post #3

I don't really buy that this is the main reason. A good senior engineer is for the most part able to not write bad code from day one, just at a very low speed and with the need to ask other people frequenyly. Even if you do not know the code base or domain yet there are a lot of things you can do to avoid writing bad code. Yes, as someone new you will make mistakes and misunderstand things but a lot of the bad code I…

  > A good senior engineer is for the most part able to not write bad code from day one
This seems unlikely. Self contained, I'd go further and say you're not a senior if your code isn't good you shouldn't be a senior.

But what is good code is in context of the codebase. It takes time to get the context of a reasonably sized codebase and no one is doing that in a single day or single week, even the wizards.

I don't agree with everything the OP writes but I think they're correct in that many companies don't value institutional knowledge. To me that is lunacy. I'm not sure how any programmer could think a reasonably complex codebase could be learned quickly. The larger and more complex your codebase the more valuable institutional knowledge is. Adding new actors just accelerates complexity and redundancy. Pushing people to be quick only worsens this. The best thing to do with new employees is get them deep into the code. Have them write/update docs, do cleanup, or other tasks that force them to understand the code and how everything interacts

Re: How good engineers write bad code at big companies

#45
post #29
post #19

Earlier quoted context omitted.

100% agreed. But to me that sounds like a typical case of rushing instead of working like responsible engineers. If the foundation is built on sand then that needs to be fixed. Engineers being expected to magically paper over a lack of clear requirements is what leads to bad code. I am fine with helping gather the requirements but if I get a list of unclear and shifting requirements and just is expected to fix it I o…

I've worked on projects where if you wait for the requirements to be firmed up, you'll never be able to do anything. Depends on what you're trying to build if that means you need to stop and figure out the requirements or if you need to just deal with the shifting sands. Aircraft built for moving requirements don't work so well; but lots of things are fine with moving requirements. It'd sure be nice to know how users…

Of course you should not wait around. I think rather the opposite that the engineers should be more involved in working on the requirements. The issue is more rushing and being expected to magically just conjure something. Changing requirements is a fact you just have to live with in many industries.

Re: How good engineers write bad code at big companies

#46
post #3

I don't really buy that this is the main reason. A good senior engineer is for the most part able to not write bad code from day one, just at a very low speed and with the need to ask other people frequenyly. Even if you do not know the code base or domain yet there are a lot of things you can do to avoid writing bad code. Yes, as someone new you will make mistakes and misunderstand things but a lot of the bad code I…

Then how do you work with this: https://news.ycombinator.com/item?id=18442941

I did that job, just after university, but that is not my comment. I bookmarked it though because that person said it so well.

You will write bad code, because what you already find there - and that one company is not alone! - is already so bad, there is no way to do a good job on top of literally millions of escalating hacks.

And don't think that you could clean this up - not even with ten years of time is that possible. You can only rewrite from scratch. Trying to rewrite even a tiny part is like picking up one spaghetti and always ending up with the whole bowl on your fork.

Re: How good engineers write bad code at big companies

#47
post #25

Earlier quoted context omitted.

> If the foundation is built on sand then that needs to be fixed. Except this is the system working as designed. Leadership 1000% wants to do things as fast and as cheap as possible.

It works as designed if your goal is to get your next promo package. It does not work as designed if the goal is to actually make the company more profitable. This constant rushing rarely ends up in things bring delivered faster or cheaper in the long term or even the medium term.

It depends a lot on the circumstance.

Re: How good engineers write bad code at big companies

#48
post #9

I don’t think the underlying point is true: big companies don’t necessarily write bad code. A big company is like a collection of small companies. Code quality varies depending on where you are in it. Similarly, nothing leads me to believe small companies are any better. Some are excellent. Some are nightmare spaghetti.

Big companies are insanely slower due to beauracracy and rules, even if talent is identical. I have seen it happen so many times as companies grow and go IPO.

Re: How good engineers write bad code at big companies

#49

what I see alot is that the syntax and overall code architecture is text book, but its the completely wrong approach that creates extremely complicated tech debt. All the code reviews will be on the syntax, and none on the big picture of the business problem, or whether the implementation is overcomplicated. in the short run (1-2 years) there is no repercussion for this, but eventually making changes will be extremel…

100% this. Stuff like database schemas gets comitted in the first sprint and never gets refactored, which completely locks you in to long term design decisions, then every subsequent PR will get held up for days in arguments around meaningless "code quality" arguments which ultimately affect nothing

Re: How good engineers write bad code at big companies

#50
post #24

You have to realise there is a almost full complete disconnect between engineering and business value

The disconnect is more between long term business value, and short term benefit for the most parasitic and manipulative actors within the business.

Engineering and business value go hand-in-hand in a healthy tech/engineering business.

A business that was built on great/innovative engineering, became successful, and then got taken over by various impostors and social manipulators, who's primary goal is gaming various internal metrics for their own gain, is not a healthy business.

Post reply on HN