- Feature Articles
- CodeSOD
- Error'd
-
Forums
-
Other Articles
- Random Article
- Other Series
- Alex's Soapbox
- Announcements
- Best of…
- Best of Email
- Best of the Sidebar
- Bring Your Own Code
- Coded Smorgasbord
- Mandatory Fun Day
- Off Topic
- Representative Line
- News Roundup
- Editor's Soapbox
- Software on the Rocks
- Souvenir Potpourri
- Sponsor Post
- Tales from the Interview
- The Daily WTF: Live
- Virtudyne
Admin
Isn't that a general characteristic of version control systems? I'm pretty sure I could obtain the same story if the code was stored in Perforce, Subversion, Hg, CVS, RCS, or even SCCS. Or PVCS, if anyone else remembers that.
Admin
Clearly no one ever looked at the code to "fix it", but more to stop their ESLint from complaining about it.
Admin
Haha, I read the headline "Maximizing Code Quality" and was expecting some great discussion topic and then I see it's just Javascript lol Nice clickbait :P
Admin
If this function is actually used, I have to assume that calling "loadSomeData" with "undefined" was actually doing the correct-ish thing, so no one bothered to fix it.
Admin
except that in js, referencing an undefined variable (as opposed to a property) throws a ReferenceError
so either:
Admin
The best thing is that JavaScript doesn't care whether you end a line with a semi-colon in the first place...
(Oh, and what's betting that userId is a global, and so this function has always worked, just never as it was intended to?)
Admin
Maybe user is a device. IT'S A ROBOT!
Admin
How dare you question the godlike qualities of Git, the best version control system in the history of the entire universe? Please tell me you already switched to distributed version control by committing all your stuff to GitHub, the most centralized code repository in the world.
Admin
It was a running joke on my team that when we had to commit something to the core team's repository (in Objective-C), the PR always attracted a complaint about spaces missing before a semicolon. We did everything in our repo in Swift, which generally does not need a semicolon.
Admin
But not SourceSafe. Even Microsoft's own programmers hated that piece of shut.
Admin
In the initial draft, I did say "Git and other VCSes" but I cut it because it wasn't adding much, and I like to leave people opportunities to be pedants in the comments.
Admin
SourceSafe was an amazing piece of technology. Amazing that anyone in their right mind was willing to release that POS.
Admin
And this is why I describe JS to my daughter as "mainly voodoo"
Admin
TFS (now "Azdo") is not much better. I had the misfortune to look at their backing databases. What a total absolute mess. Result: slow performance, ridiculous SQL queries, etc.
Admin
The real fake WTF is that some scoundrel could rebind this. Make it an arrow function already!
Admin
Yeah, it was especially lovely when a coworker checked out something, forgot to unlock it and went on a two week vacation. Good times.
Admin
Yeah, they only made TFS because they needed something to compete with the back then super popular spiritual CVS successor SVN. So at least they got rid of eager locking, but by the time they crunched the thing out git was already super popular... so ironically if you check old MS blocks, they started recommending git as a replacement for their own product as soon as there was rudimentary support in their build pipeline available :-)
Admin
Indeed. Not SourceSafe. I've used it in the past (1999-2003), and to express how I feel, I'd need that projectile-vomiting emoji we have on the forums here.
Admin
At work, I use, by necessity, git (but not in Github), but at home I have a Perforce depot with 23 years' worth of commits. (Yes, the oldest commits, er, changelists are older than git.
Addendum 2024-06-05 10:35: And I k'bah to migrate.
Admin
Excepting a brief stint with CVS, I started out with SourceSafe. Locking files wasn't "the wrong way", it was "the only way". To the point that when we switched to TFS around 2010, we actually kept the "Locking" model for a few more years.
Of course, that was then. Now I'm a total Git noob experiencing the joy of resolving Git merge conflicts for the first time.
Addendum 2024-06-05 10:55: And coping with the fact that Git doesn't track file renames.
Addendum 2024-06-05 10:59: Or the fact that the recommended strategy for migrating your repository and its history to Git is "don't bother with the history, any changes older than six months are forfeit anyway".
Admin
Well, that rather depends upon what you'd experienced before SourceSafe. If it was, working backwards in time before SourceSafe, VMS versioned files - so only your recent history up to the file purge limit, no source control at all and no change history at all other than comments in source, then SourceSafe was pretty bloody good. Was it problematic at times? Certainly, but it was a damn sight better than that.
Admin
or - and I think this is the most likely - getData is never actually called anywhere and it's dead code that should be pruned except that would require testing to make sure it really actually isn't called anywhere. So shutting up the linter is the most they're allowed to do.
Six years of a function with an obvious error in it and no bugs that have ever been traced back to it is suspicious unless it's actually never used.
Admin
I accepted a job offer as a web developer in 2008 on the condition that the first task assigned to me would be "migrate everything to subversion". A big win for everyone involved.
Admin
oh, you were coding on VAX/VMS? Then you could have used DEC/CMS (first available in 1982) instead of SourceSafe (first available in 1995). I certainly did.
Admin
Three people have attempted to clean up technical debt. The first was someone trying to get rid of the userID global.
Admin
Not the only occassion you see this: Code changes in hopes to "get rid of errors", which means altering the source code, linter hints, unit tests, compiler options etc. in order to avoid any warnings and errors, because when there are no warnings and errors, the program compiles and runs and works as expected - because that is what this whole stupid "build system" is supposed to do, right? If it doesn't complain, the program does what the manager wants, and that is the only aspect of quality that counts. (Sidenote: "trial & error" is also a good development technique leading to high quality programs.) No error - no problem!
Admin
Okay this one made me laugh at loud literally. And I had to comment. First time in over a year visiting TDWTF and this made me comment.
Admin
"What do you use for source control?" is a question I always ask in job interviews. Some time around 2010 I did get an answer of "Uh, nothing." and replied that if I was hired, that would be changing immediately. I did not get the job.
Admin
I worked on a Fortran project on VMS that used a source code control system - I forget what it was called, but it was much better than just the versioned files.
Addendum 2024-06-06 07:36: Just read dpm's comment. The one I used was CMS.
Admin
Conversely, when I interviewed developers, I would always ask what source code control systems they liked to use. Not seeing the point of source code control was not an automatic rejection, but it made their task of getting the job much harder.
Even in my personal projects, setting up source control is almost a reflexive action, like putting my seatbelt on in a car.
Admin
CMS on (Open)VMS was my first encounter with version control as well. The good thing about CMS is that I don't remember anything about it any more. Which probably means it didn't have any annoying bugs or quirks, unlike VSS, PVCS, svn and git.
Admin
Admin
Arguably, this could be the result of some CI/CD linting script. Still unacceptable, but I get how this could happen without the knowledge of the requestor (due diligence aside) in modern coding environments.