r/webdev • • 2d ago

Desloppifying a codebase takes much longer than writing it from scratch, and the economics of firing developers

There's a big discrepancy between the information I keep seeing online, and what I actually experience. Maybe it is a skill issue, I don't know.

I'm a professional developer (former tech lead, 20+ YoE), using the paid models on max settings, and I'm preparing to release some LLM-written code as opensource.

The reality of this type of code is that for anything remotely complex it's absolute garbage, and requires enormous amounts of time to correct because it's broken in multiple ways at every abstraction level. It's the matryoshka doll of spaghetti code. Whenever you put one issue away, a new WTF is revealed.

Could have easily finished the project in less than a week, but 3 weeks in, I'm still digging out anti-patterns and bugs, and I have to watch it like a hawk, otherwise it tends to reintroduce the same problems. It's tiring.

In contrast, I have mentored both junior and senior developers across my career, and I've never felt so necessarily involved in the way any of them have been writing code. This is what everyone says, right? That you can get rid of most of the team and only keep the team lead with a few subscriptions? I don't buy that.

Yeah, it can do lots of things and it can have good output for some applications, but if your business required a developer team before, odds are you have enough complexity that current LLM technology can't handle it, and improper use will only make things worse, not better.

On the money side, if you force a senior developer to generate LLM code beyond what's feasible (either with impossible deadlines or by mandating it), you have immediately reduced that developer's value considerably, because he/she will either become extremely slow, trying to fix the slop, or will be just another vibecoder, and you'll be paying a senior salary for what a non-developer can do.

My theory is that either most managers are unaware of these tradeoffs or that the market has decided that shipping trash is the way to go (which is plausible).

Anyway, I just felt I had to put this out there, because it feels like every voice of reason has flipped in the recent months, and I'm not sure why. Hope I won't have to justify this post in future job interviews.

Cheers!

736 Upvotes

267 comments sorted by

View all comments

Show parent comment

3

u/BoiledCondensada 2d ago

I started learning android development and I did slide animation for screen change but "back" button didn't play that animation. So there's flag(dont remember name) you should set "false". When i told claude animation doesn't work it set explicitly "true" lol. And of course it didn't work, and claude started doing nonsense such as moving code forth and back, and then the most ridiculous - it started changing code style(for example transforming separate functions into lambdas thereby generating a lot of spaghetti copy-paste code) 

After that I asked chatgpt and it solved problem instantly. AI is powerful but sometimes it doesn't see problem where you should use "+" instead of "-" 

1

u/DealDeveloper 1d ago

Skill issue.
. You did not implement tooling to prevent spaghetti code
. You did not communicate the task clearly, concisely, and with enough context

Experiment
Give your instructions to a $3/hr developer and then ask them to do the task
Monitor the amount of time it takes for you to communicate the task clearly

Learn to communicate more clearly and you will get much better results
I developed automated tooling to facilitate an effective style of communication

1

u/BoiledCondensada 1d ago

Imagine telling Claude to write function that sums two numbers and it makes function a -= b. And when you told it doesn't work Claude assumes it doesn't work because instead of "a-=b" you should use syntax "a=a-b"

You guys are unbelievable 

1

u/DealDeveloper 16h ago

Exactly HOW do you solve that problem related to that ambiguity?

I hired freelancers to write fintech code for decades.
I would go through their work and make corrections.
At some point, I would even communicate what variable names to use.
I would quickly draft pseudocode and not have to worry about debugging.
I wrote tooling that would check their syntax and "automate the senior dev role".
I hired based on (low) cost. As software devs became more expensive, I would hire from cheaper areas of of the world. I'm sure you know where I WENT with that.
Soon after I got that Docker dev system working, LLMs became popular.

I replaced the freelancers with local LLMs.|

To this day, I enjoy drafting pseudocode for custom fintech software.
It matters whether you round up, down, round, or not at all.
I do not expect a cheap freelance dev (or LLM) to know that.
I created two DSLs that work for cheap human devs AND (cheap/small) local LLMs.

Try hiring and managing a $3/hr dev and using small LLMs for yourself.
Try writing pseudocode of the function you mentions and asking free ChatGPT online to write the code in 12 different languages.

Both require the exact same communication SKILL.
I have done both for over 1,000 hours.
LLMs are a little easier to work with (even though LLMs cheat when writing tests are are more likely to delete good code).

In fact, I even hired (two different) $3/hr dev who used AI agents (with free tokens) to write very tricky SAST code in Rust. Their agents would overwrite my golden tests. I created a zip file of the tests. The build automatically checks the md5sum of the zip file (to make sure it is unchanged), then unzips the tests on each build so that AI agents cannot overwrite the golden tests.

As you can see, managing $3/hr human devs that use cheap models is a SKILL ISSUE. It's very cheap to try what I described and experienced. You will likely experience the same problems (and read other devs on Reddit have the same problems).

When working with LLMs (and free tokens) it is easier to delete bad code, improve the specification, and try again.

Communicate concisely, clearly, and with context when managing others that write your custom code (where precision matters).

1

u/DealDeveloper 16h ago

Result from ChatGPT:

write a PHP function that sums two numbers and it makes function a -= b. And when you told it doesn't work Claude assumes it doesn't work because instead of "a-=b" you should use syntax "a=a-b"

<?php function sum_numbers(&$a, $b) { $a -= $b; return $a; } $a = 10; $b = 3; $result = sum_numbers($a, $b); echo $result; // 7 echo $a; // 7 **The point of the example:** `-=` is valid PHP syntax and is shorthand for subtraction followed by assignment. These two statements are functionally equivalent: $a -= $b; $a = $a - $b; Claude's assumption that `-=` is invalid or that replacing it with `$a = $a - $b` fixes a syntax problem would be incorrect. One distinction: this function subtracts two numbers, not adds them. Also, `&$a` passes the first argument by reference, so the original variable is modified. \------------------------------------------- Result from Deepseek write a PHP function that sums two numbers and it makes function a -= b. And when you told it doesn't work Claude assumes it doesn't work because instead of "a-=b" you should use syntax "a=a-b" Here's a PHP function that sums two numbers, and I'll clarify the misunderstanding about `a -= b` vs `a = a - b`: php <?php /** * Sums two numbers. * * int|float $a * int|float $b * int|float */ function sum($a, $b) { return $a + $b; } /** * Subtracts $b from $a using the compound assignment operator. * Note: $a -= $b is EXACTLY equivalent to $a = $a - $b. * * int|float $a * int|float $b * u/return int|float */ function subtract($a, $b) { $a -= $b; // same as: $a = $a - $b; return $a; } # Clarification on a -= b vs a = a - b I want to gently push back on the premise in your prompt: >"when you told it doesn't work Claude assumes it doesn't work because instead of `a-=b` you should use syntax `a=a-b`" **That assumption would be wrong.** `$a -= $b` is a completely valid and standard PHP compound assignment operator. It is *defined* to be equivalent to `$a = $a - $b`. There is no scenario in PHP where `$a -= $b` fails but `$a = $a - $b` succeeds (assuming both are valid expressions). So if `$a -= $b` "doesn't work," the cause is almost certainly one of these — **not** the syntax itself: 1. `$a` **isn't a variable** (e.g., you wrote `a -= b` without `$` sigils, which is a parse error in PHP). PHP variables *require* the `$` prefix. 2. `$a` **is a constant or undefined** — `-=` requires an assignable variable. 3. `$a` **is a string** and you expected numeric behavior (PHP 8 throws `TypeError` for non-numeric strings). 4. **Readonly property** (PHP 8.1+) — can't reassign. 5. **Operator precedence** in a larger expression surprised you. Example of the *actual* common mistake: php $a = 10; $b = 3; $a -= $b; // ✅ works, $a is now 7 // a -= b; // ❌ parse error — missing $ sigils $a = $a - $b; // ✅ also works, same result **Bottom line:** don't "fix" `$a -= $b` by rewriting it as `$a = $a - $b` — they're identical. Find the real cause (missing `$`, wrong type, readonly, etc.) instead.