43 files changed, 5671 deletions(-)
Today was a good day. I love deleting XML parsers more than anything in the whole world.
43 files changed, 5671 deletions(-)
Today was a good day. I love deleting XML parsers more than anything in the whole world.
I unintentionally created quite a ruckus on the kernel mailing list this weekend. Evgeniy’s take. It’s funny, I feel a lot less invested than practically anyone in the whole thread.
More evidence that javac is one of the dumbest compilers ever:
public class Foo extends java.lang.Object{ public Foo(); Code: 0: aload_0 1: invokespecial #1; //Method java/lang/Object."":()V 4: return public static void main(java.lang.String[]); Code: 0: aconst_null 1: instanceof #2; //class Foo 4: ifeq 15 7: getstatic #3; //Field java/lang/System.out:Ljava/io/PrintStream; 10: ldc #4; //String never! 12: invokevirtual #5; //Method java/io/PrintStream.println:(Ljava/lang/String;)V 15: return }
Ok, I’ll give them a break — this probably never comes up in a real application.
Don’t believe anything you read on the internet today, especially this post.
If there was any doubt (who am I kidding) that election machine manufacturers are pure evil, check out the nastygram Ed Felten got from Sequoia. Incidentally, my home county election officials are batshit insane on this issue. Notice “[printable]” doesn’t mean “voter verifiable.” Just because they can print from it doesn’t mean they do.
I write dumb scripts with git! Here’s how to (slowly / automatically) remove any @SuppressWarnings annotations that don’t do anything:
for i in `grep -rl @SuppressWarnings src` ; do echo $i cp $i $i.tmp grep -v "@SuppressWarnings" $i.tmp > $i rm $i.tmp git-commit -a -m "Disable warning suppressions for $i" ant compile > build.txt res=`grep "[javac].*error" build.txt || grep "[javac].*warning" build.txt` if [[ ! -z $res ]]; then echo error! git-reset --hard HEAD~1 fi done
$ strace -f ant > out.txt 2>&1
$ grep "stat.*java" out.txt | wc -l
32933
WTF? No wonder our build times suck. I still have yet to hear a rationale for the existence of ant that had any more substance than “but make uses tabs!”
Ed Felton et al. announced today an attack on disk encryption using the bits left in RAM. Oh noes, my poor dm-crypt partition!
Angeline and I went to the KC to see the ballet last night. They are having this celebration of Japan’s “hyperculture,” whatever that means. But one thing it means is there are robots there!
Actually, the robot display is somewhat disappointing. Asimo and the trumpet player thing are there for occasional demonstrations, but they weren’t out on the floor when we were there. So, the only robots we got to see were this little yellow thing that supposedly can talk (only in Japanese, however), a small menagerie of Aibo-like toys, and the creepy “Actroid” DER2, pictured. DER2 does look somewhat realistic, actually, but you wouldn’t mistake it for a real person. You can ask it canned questions, then it will do the speech recognition stuff and say a canned response. Eye-rolling stuff such as, “I’m looking for a guy with a heart of gold and brain circuits to match!”
Still, robots!
A month or two ago I was thinking about test-driven development and what a pain it is to write test cases. Or, well, test at all for that matter. Who needs testing when you have users to do that for you?
At work we have this fairly complicated UI that eventually interacts with stateless session beans in the whole wizbang J2EE world. Usually, I spend most of my debugging time tickling the backend rather than fooling with the UI so all tasks of logging in, navigating windows, setting up data and so forth are just overhead.
One previous company I worked at had an excellent solution to automating all of that without winrunner or other similar crap: everything in the GUI created a command string that was then fed to a command parser to perform the task. You could use these command strings exactly as a script to control the app. Had a crash? Just replay the customer’s log to see the segfault.
So I had the rather obvious idea: use an EJB 3 interceptor with XStream to record method calls, their parameters and return values to the server logs. Later, we can execute these logs to replay all the SLSB calls and check the return values. Ta-da, we have some automated tests without even trying. Not full coverage of course, but better than nothing at all.
Another developer got the lucky task of implementing it, but I’ve just started using it today. Very slick. Now we just need a Lisp interpreter and an email client.