- Feature Articles
- CodeSOD
-
Error'd
- Most Recent Articles
- Stop Poking Me!
- Operation Erred Successfully
- A Dark Turn
- Nothing Doing
- Home By Another Way
- Coast Star
- Forsooth
- Epic
- 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
Well, at least they didn't try checking if the file existed before opening it...
Admin
BTDT, in Perl. Except it didn't do it for every line, it did it for every field in every line. :facepalm:
Admin
At least they are checking that the monthly backup restores....
Admin
They were... now it seems they will use live-data... race for anyone ?
Admin
TRWTF are Bruno and Ivan.
Admin
Funny, I found and fixed some code in my team's code base not too long ago that made the same "writting" misspelling. :trolleybus:
Admin
I once fixed a program that was writing output to 7 files, but for raisins could only have 5 open at a time, so each write to each file was wrapped with an open/close like that. I rewrote it to make a log of all the records it was reporting on to a set of temp tables, then when it was finished processing, it would open each temp table and write out the data for that table. IIRC it went from 30 minutes to 10--the rest of the time was processing, and overhead due to writing to a not-terribly-fast network share or something.
Admin
comment.open() comment.writeline("Something witty") comment.flush() comment.dispose() comment.open() comment.writeline("Another witty thing") comment.flush() comment.dispose() comment.open() comment.writeline("Let's bring Discourse to its knees") comment.flush() comment.dispose()
Admin
Me, I'd go right ahead and schedule the sucker, then sit back and play Pinball Arcade while my PC happily crunched away all by itself. And post my Outlook Calendar time as "Busy Do Not Disturb" .
Admin
Error on line 5: Object reference not set to an instance of an object (Did you construct it with New()?)
Admin
I have run into this anti-pattern in the Enterprise world shockingly often. There are apparently a LOT of people out there who have no understanding of the costs of buffering, spinning objects up, disposing of them, etc. And my solution has always been the same as in the story, nuke the offending code and replace it with a single write to file once the content is done being assembled. :sigh:
Admin
I don't know a lot about Java, but is FromHtml("#ff3c3c") really the best way to get a color?
Admin
It's unlikely to be Java (as Java's house style is to have methods start with a lower case letter), so that part is pretty unlikely to start with. That said, no, not a good way to get a color anyway.
Admin
TRWTF: a 40 MB CSV file as a report. I can count the number of humans who have ever actually read over that whole thing on the fingers of one foot. That's not a report, it's a big chunk of wasted storage on the file server.
Now if they followed up by printing it out, it would at least serve the purpose of killing a few dozen trees, one of which might have grown up to be Hitler.
Admin
TIL that 40MB is “big”.
Admin
Well it depends on context. For a webpage, 40MB is an insanity that we are slowly approaching at a rapid pace. I'd rather be rapidly approaching at a slow pace, though.
Admin
40mb is massive for what amounts to a text only filetype. The silly thing is, a 40mb file is tiny for a desktop to process nowadays. My low-end laptop from almost 10 years ago can process that in a minute or two tops. So it's a large file (40 million characters, or ~3-8 million words), but not difficult to read quickly with modern technology.