The Daily WTF - RSS Feed

Curious Perversions in Information Technology

Latest articles

CodeSOD: Ordering the Hash

Last week, we took a look at a hash array anti-pattern in JSON. This week, we get to see a Python version of that idea, with extra bonus quirks, from an anonymous submitter. In this specific case, the code needed to handle CSV files. The order of the columns absolutely matters, and thus the developer needed to make sure that they always handled columns...

Error'd: By The Clicking On My Thumbs

Music fan Erina leads off this week with a double contraction! "Who knew Tom Waits was such a gravelly-voiced Relational Database poet?" she Mused. "You'd've thought that SQL modes was more of an indy garage esthetic." You might've, Erina, but I wouldn't've.   An anonymous B2B buyer notes "It looks like the ERP software industry has...

CodeSOD: Where You At?

Validating email addresses according to the actual email specification is more complicated than you usually think. Most homebrew validation tends to just get something that's relatively close, because hitting all the rules requires some fancy regex work. And honestly, for most applications, "pretty close to correct" is probably fine. If you actually...

CodeSOD: Validate Freely

Validation highlights the evolution of a programmer as they gain experience. A novice programmer, when given a validation problem, will tend to treat the string like an array or use substrings and attempt to verify that the input is the correct format. A more experienced programmer is going to break out the regexes. A very experienced programmer is...

CodeSOD: Putting the File Out

There's a lot of room for disagreement in technology, but there's one universal, unchangeable truth: Oracle is the worst. But a second truth is that there's nothing so bad a programmer can't make it worse. Someone at Ben's company needed to take data from a database and write it to a file. That file needed to have some specific formatting. So they...

CodeSOD: The Hash Array

When Arbuzo joined a new team, they helpfully provided him some sample code to show him how to interact with their JSON API. It was all pretty standard-looking stuff. If, for example, they fetched a Customer object, it would have some fields about the customer, and an array containing links to orders that customer had made. One of the samples helpfully...

Error'd: Innocents Abroad

This week's opening Error'd submission required a bit of translation for the monoglots among us, but it was worth the work. Not speaking even een beetje of Dutch, I was forced to use Google's own translation service to see what it was that had so worried our friend Sebas. And it's a doozy. "...seek help - Child abuse images are illegal" warns...

CodeSOD: Just a Few Questions

Pete has had some terrible luck with the lead programmers he's worked with. He's had a few which are… well, they don't take feedback well. Like his current team lead, who absolutely doesn't let any of the other developers review or comment on his code. "Don't ask me questions, you should know this already," is a common refrain. Speaking of questions:...

CodeSOD: A Parser Par Excellence

Jan's company has an application which needs to handle an Excel spreadsheet, because as I'm fond of pointing out, users love spreadsheets. The JavaScript code which handles parsing the spreadsheet contains… some choices. These choices caused it to fail on any spreadsheet with more than twenty six columns, and it's not hard to see why. export function...

CodeSOD: Time Sensitive Comments

One of the arguments against comments in code is that they create a need to have two things updated: the code and the documentation have to be kept in sync. Inevitably, they'll drift apart. David works with a junior developer who came onto the team with strong opinions about, well, everything. One of those strong opinions is that every single line...

Discover, share and read the best on the web

Subscribe to RSS Feeds, Blogs, Podcasts, Twitter searches, Facebook pages, even Email Newsletters! Get unfiltered news feeds or filter them to your liking.

Get Inoreader
Inoreader - Subscribe to RSS Feeds, Blogs, Podcasts, Twitter searches, Facebook pages, even Email Newsletters!