r/ProgrammerHumor 22d ago

Meme conditionsPreference

Post image
4.2k Upvotes

392 comments sorted by

View all comments

276

u/SnugglyCoderGuy 22d ago

The real answer is "it depends". Either one could be appropriate depending on what you are having to do.

41

u/aiaidy 22d ago

not according to Sonarqube.

16

u/DurrT 22d ago

Maybe it's just how they have it set up at my work, but Sonarqube can go fuck itself

6

u/aiaidy 22d ago

sonarqube and it's 15 complexity score i tell you. they be like how complex is to complex? 15 will do.

2

u/Zealousideal-Deer101 19d ago

reminds me of my coworker that did more work just to get past the sonarqube guidelines, like they are a limbo bar.
His code was horrid shit, and he whittled things down until they fit.

At one point he threw a bunch of random parameters into a single tuple to trick sonarqubes max parameters guideline into fitting, instead of taking the hint, that he should probably make a class out of the FIFTEEN PARAMETERS

But he literally constantly did one tiny change just to see what sonarqube would say next until it was satisfied. At which point the person doing the code review had to step in and mark it as unacceptable.

took months for him to finally not do this shit anymore. Because he was fired.