- 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
WTF?
Admin
So all they needed to do in the db was add a ternary flag?
Sheesh, any boolean can handle that!
Admin
Easy: just hardcode all the reports green. Everyone's happy!
Admin
It is hard to explain to end users sometimes why these things are so complicated. But every time the programmers tried to load the icon into the browser, they kept getting...
wait for it...
File not found!
Admin
They had it all wrong and missed some critical steps:
Admin
I don't get this one..
"..an extreme challenge to manage the thousands of icon files.."
There are only three: red, yellow, green. Why create them dynamically? Just reference static ones?
Or did IBQ just not want to do the work?
Admin
IBQ is missing out on a great opportunity:
Admin
I feel like I missed something in this story. Seems to me that TRWTF is the fact that the developers think it's so hard to add an icon.
Though I don't know the specifics of the system, of course, it seems like you just create green, yellow, and red images, then the code can say something like the following:
if (happy) loadImage(green); else if (ok) loadImage(yellow); else loadImage(red);
So... what's the problem?
Admin
TODO: make a comment on this WTF before it becomes a royal pain to read existing comments
Admin
Well, the comment in the database pretty clearly says that they hadn't actually got a value for what the mood icon should say. So they lied about the reason.
Obviously if they'd been asked to give a numerical value for the risk, then they'd have had to fess up, but as it was,...
Admin
Read the comment at the end of the article.
Read the comment at the end of the article.
Glad to help!
Admin
Comment has been read (again). My previous statement still stands.
I guess the WTF is supposed to be that the development team lied about how hard it would be?
Unless the database is a complete clusterfuck, adding one column to a table to add mood shouldn't be that hard.
Admin
Then, to really annoy the users, they used smiley emoticons instead of a color indicator...
Admin
Good, OK, Bad
Admin
It's possible to Encode the image on the page itself. No need to save anything, just render it. I don't know why they didn't just do that -- I have two web apps where the binary data is encoded right on the webpage, because I wanted a one-page-that's-it app.
Admin
I suspect that they didn't even really do it out of lazyness - after that huge multi-department email conversation they probably just wanted to save face.
Admin
Admin
Admin
alex just blue you
Admin
I've seen many applications where if you can't add a column to the database, just attach the data to the primary key:
Report_ID
1.Red 2.Red 3.Green 4.Red 5.Yellow
Make sure you put it AFTER the ID, to confound anyone who wants to sort on mood. But why would anyone want to do that?
Admin
Also, the TODO comment shows that they did intend at some point to implement 'mood', but forgot. So the 'out of scope' comment was bluster as well.
Admin
Where I work, we would spend three or four days discussing why green should be the "good" mood. Legal would be brought in. We'd need to justify it to communications. Many would have interesting points on various shades of green. Naturally, the process would be repeated for yellow and red.
CAPCHA: odio (Its round on the ends and DI in the middle)
Admin
Admin
Does "blue" mean too healthy, one step above green?
Admin
Don't forget the colorblind!
Admin
Basically they were trying to stop scope creap. It always starts as something little that you can add, then its another item, then another, before you know it the project is months behind and millions over budget. Nip it in the bud before it can grow.
Admin
HTH.
Admin
i'm colorblind, fyi.
Admin
Put me in the column of folks who don't get it.
I'm not a databaser so I'm probably way out of my depth here and will take my insults off the air, thanks, but it strikes me that in the previous system there was some metric used to determine the "goodness" of the report -- that apparently already worked. So how difficult would it be to transfer/port that calculation to the new system and flag the report with whatever icon, background color, bell, or whistle that the user wanted.
What am I missing? I assume it's something obvious, so be gentle.
Admin
Those algorithms are so complicated that they will never get them working. I suggest the following:
Infinitely scalable: just add more interns, printers and scanners. Also infinitely extensible: adapts well to more colors, different shapes, etc.
Admin
I think this site needs to add colored images to every comment.
Admin
TRWTF is the phrase "custom web browser."
Admin
IBQ (the ones responsible for the report app) originally planned to implement the mood in their brand new database, but they forgot. When IBP questioned IBQ about the lack of moods, they made up a whole bunch of bunk to hide their forgetfulness.
Captcha: nibh. It's like a word, but with an "h" at the end.
Admin
But it's a WEB site. That means that you might have thousands of users at a time, so you need thousands of icon files. Maybe millions.
Admin
Racist.
Admin
Not if you have a good backup solution. Every time someone downloads the file you can just restore from backups. It saves the graphic artists people from redrawing all day.
Admin
Nice.
Actually I was thinking that you only need three (or five, ten, whatever) images, and you just choose which one to link to. Or, put them all in the page and use ajax to make one visible.
Admin
Admin
The big question is, of course, what constitutes a good mood for the report; if this was a rewrite, it's possible that the original logic is either hopelessly byzantine or that the design has changed enough to make it irrelevant. Regardless, I'd oppose the whole mood thing (unless specced by the client) on the grounds that it would lead people to rely on it instead of actually reading the report.
Admin
it seems all of that BS could be shortened to: 1.generate report 2.determine colored dot to use 3.add dot
you know, assuming that they could just reuse already generated dots in one of three colors that were already on the drive.
this kind of reminds me of those star trek voyager episodes when the evil group of aliens [read: people with model parts and foamcore glued to their eyes, foreheads or chests] 'download' something from the ship and suddenly, the ship does not work because, evidently, this team designed the copy/paste integration software for the ship.
Admin
Green circle, Yellw Triangle, Red X.
Admin
Admin
Admin
What the article and code comment seem to infer is that nothing was storing the report state. Basically each time the report ran a final process would generate an icon file specifically for that report. The image file itself was the only thing storing the state for the report, so no matter how many web browsers hit the site, the image for "Report A" would always be called "Report_A_Mood.jpg" and it would have been generated (and overwritten the previous image) the last time "Report A" was executed. The database addition would have allowed them to store a mood and only have 3 images that could be referred to by mood, for instance "Mood_Green.jpg" rather than by the name of one of thousands of reports.
Admin
Ah...But you forgot about the shape blind! Now what?
Admin
Surely "Mood_Green.gif" or "Mood_Green.png". It's only a dot!
Admin
They're not colourblind.
Admin
Clearly, the logic that went into the mood determination was the main problem with implementing it - TRWTF is their excuse was so bad, that anyone with a hair of a technical background would be able to call them on it... which could really backfire.
They should have either said "all reports are green now, since we cleaned everything up so much" or implemented a 'simplified' mood: Green: no missing rows in tables with foreign keys Yellow: maybe a few problems... Red: important table may have been dropped.
What I'd really like to know is what exactly did the mood imply? What do you do if you have a yellow or red report?
Do you tell your boss "I have that report you asked for, but I have to warn you - its pretty moody"
Sounds like a simple "This report generated [x] warnings" tag at the bottom that could be expanded would be far more useful than "unhappy" reports.
Admin
Errr...
Admin
Not so! I assert that Ray Charles was both color and shape blind. Ha! Now what would you do?