To me, the code itself is the product. I want the code to look like a beautiful painting—the fact that it does something is secondary. I’ll sit there for hours working on things like const correctness, and making sure each class has the bare minimum amount of state/instance variables, making sure function arguments are named and ordered consistently, even though it has no effect on user-visible bugs or runtime performance. I’m the kind of person that paints the back of the cabinet. Even though no user will see it, I will know it is there.
Obviously this mentality is at odds with commercial software’s imperative to shit out barely working spaghetti code as fast and cheaply as possible, so I opted out.
I'm strongly against the "move fast and break things" mentality. But there is a happy middle ground between architecting works of art, and shipping urinals with faulty plumbing.
You do you, I'm sorry if I come across rude and stupid, but I am both things. But "code is the product" is what IMO caused the downfall of this entire profession. No wonder everyone is trying to get rid of us. I wouldn't want a plumber that's obsessed with the tubes itself and not whether my house has working plumbing in a reasonable time frame and within budget.
I have worked at a never-ending list of places where people shipped the first thing that worked, built spaghetti around it, something else got built on top, and the original thing is now critical infrastructure that takes 10x longer to fix bugs or add needed features to than it would have if we’d taken 1.5x longer to ship it in the first place. I have worked at a never-ending list of places where developers beg for time to be set aside to deal with the worst parts that sap their time, energy, or will to continue working at the job. I have worked at a never-ending list of places that eventually sets aside a few days to tackle these tasks, when the engineers estimate two or three weeks. I have worked at a never-ending list of places that then uses the failure of these momentary diversions as evidence that their engineers don’t know what they’re talking about and should shut up and ship more features.
I sure wish I knew what masterpiece factories you must have spent your career working at.
I have come across the architecture astronaut before. But I feel like they’re the result of the culture of the ecosystem the language. The Java and C# programmers whose language requires you to juggle weak types with visibility keywords and null ability. They can be forgiven for not being able to implement a priority queue without a committee and a class hierarchy deeper than the Mariana Trench.
But the perfectionist that never ships anything useful and only ever tweaks interfaces and types? Never met one.
Most people are just trying to balance progress with practical concerns.
My take on this is that we need both, because the market is cyclical. It’s just that it’s hard to perceive any of those cycles if you (a) live them (b) are not experienced enough to introspect.
I absolutely would love an obsessed plumber (and got one!) when it comes to deciding that we’re going to do PTFE tubing in our new house. An obsessed electrician in charge to overinvest into our grid, rather than a 3-month timeframe executive. Otherwise our critical infrastructure gets myopically degraded.
I also want the “working within timeframe” outcome.
And we, as an industry, swing wildly in both direction. The Cambrian explosion of shareware was the the former. We course-corrected into cathedrals of good software (I still love Windows 2000’s stability, the pinnacle of NT line), followed by the “reasonable timeframe” 4GB Electron apps, etc.
It will swing. Every complex system from logistic equation upwards will oscillate .
You may have worked with people whose meaning of "code quality" encompassed things that you found inconsequential and a waste of effort. They may have even told you that if you didn't care about those things, then you didn't care about code quality. But that's not true. It only meant you disagreed with them about what code quality is and how to recognize it.
You draw a distinction between aspects of code that tend to lead to better outcomes and aspects of code that don't matter. You say you know what tech debt looks like. When you look at a codebase, you have opinions on where time should be spent to improve it. "Code quality" is shorthand for the heuristics underlying those opinions.
Instead of accepting that other, possibly dumber people get to define what code quality is, own your own definition of it and use it when you communicate with other people.
> You may have worked with people whose meaning of "code quality" encompassed things that you found inconsequential and a waste of effort. They may have even told you that if you didn't care about those things, then you didn't care about code quality. But that's not true. It only meant you disagreed with them about what code quality is and how to recognize it.
Who's these "people" you're referring to? This is an imaginary conversation you've added.
What I actually said was that there's a balance between design and output.
I did generalize that often product people will push too far towards output and often developers will push too far between design, but like all generalizations, I know there are exceptions (eg me).
But the crux of my point is that there are tradeoffs between the two, and thus times when it makes more sense to lean towards output and times when it makes more sense to focus on design.
What you've replied with isn't even remotely the same sentiment as the comment I made.
> You draw a distinction between aspects of code that tend to lead to better outcomes and aspects of code that don't matter. You say you know what tech debt looks like. When you look at a codebase, you have opinions on where time should be spent to improve it. "Code quality" is shorthand for the heuristics underlying those opinions.
No. Code quality is just a subjective term that means nothing in reality because everyone will have different goals in mind when they think about the purpose of the code.
So the underlying heuristics require far insight into project goals, deadlines, and resources than just "code quality".
> Instead of accepting that other, possibly dumber people get to define what code quality is,
The original reason I replied (albeit I did digress quite a bit) was to demonstrate that you cannot extrapolate how smart or dumb an engineer is from their "code quality" alone. So please refrain from calling people dumb in your rebuttals.
> own your own definition of it and use it when you communicate with other people.
That's literally what I've done.
---
This comment better summarizes my point: https://news.ycombinator.com/item?id=48555191
There’s far, far too many people who confuse code quality for speed of development and start treating code quality as the product for customer base in the hundreds and active customers in the dozens and for most features to be basically unused.
The reality is that tech debt as a concept these days is hardly real: to be in debt means previous decisions or a previous implementation makes current work extremely hard or impossible, but, the truth is that the human factors such as knowing what to build, team collaboration and even speaking to customers matter far more and can get you “in debt” so so much faster than code alone. At least in your typical SaaS company.
If you ship code in a way that you let tech debt pile up to the point that customers notice it, you have an organisational problem, not code issues per se.
The fact that a lot of people don’t get this is really baffling to me.
Good codebases sort of read themselves. You can guess where things are, how they are sorted and how they work, by understanding and relying on the authors ideas.