Earlier quoted context omitted.
I've also seen "scaffolding" used to generate code that shouldn't be manually modified. E.g.: https://learn.microsoft.com/en-us/ef/core/managing-schemas/s...
That's someone who doesn't know what words mean. When a building is built, the scaffolding isn't an immutable part of the final product.
Don't be clever
141–150 of 231 posts
Re: Don't be clever
#142Right now, I'm working on two databases that almost do the same thing. One is legacy, the other is the new and improved. I can't delete the old one because there are several teams that generate their reports from it, I can't delete the new one because new functionality depends on it. When we add a new feature, we run update queries on both databases (but not always). We need several months of work and create training…
Also, I would put other DB in keep the lights on (KTLO) and not provide any support or patches. You need to make your problem thier problem.
Re: Don't be clever
#143Earlier quoted context omitted.
Making things worse, I suspect there's at least two (and probably more) definitions for 'clever' that are thrown around and the intent half the time is that one definition is masquerading as the other. One plausible definition for clever code is that it's code that only works because of a non-obvious dependency on some other fact being true in the code base or outside of the code base. Once the fact is no longer true…
The other option is "yes this works well and is very neat, but it's not going to withstand 5 years of people changing it and only reviewing the diffs."
Nothing can stop morons from ruining good code. Good devs will evolve code into something that makes more sense.
Re: Don't be clever
#144You can also have system level cleverness, which is fine as long as you can explain the cleverness in a few sentences. Sometimes the data access layer is clever and the other stuff isn't....
at the end of the day, as long as you leave things such that they are easy to change, or at least you're brave enough to change them, none of it really matters. Someone is going to replace the "clever" code with other code that does more or less the same thing, and then next engineer will replace that code with something else.
Re: Don't be clever
#145So everything is a class
The majorities language's community has this super weird Java obsession The other half has a Rails obsession
The best career decision I ever made was to watch the Rich Hickey talks
2x my wage in a few years and don't have to care about any of this obvious mis-match ever again
Re: Don't be clever
#146Earlier quoted context omitted.
Generated code is fine if it's newly generated on every build. If you're going to have to maintain the generated code, it's not generated code anymore, but duplicated code.
Yes and the original article is about how duplicated code is ok. The discussion finally went the full circle.
Re: Don't be clever
#147Re: Don't be clever
#148Maybe I'm not clever enough. Maybe I don't hate copy and pasting enough.
Re: Don't be clever
#149Re: Don't be clever
#150Being clever during feature development is a red flag to me. I’m a huge fan of the YAGNI principle.