Jeff with Leif and Piano

LED lights

Anyone know if the LED lights are any good yet? I'm tired of CFLs burning out in less than a year for the cost and am switching back to incandescents for now. Replacing these things yearly can't be resulting in a net improvement for the environment.
Jeff with Leif and Piano

Conversation

"Hi! We can schedule your MRI for tomorrow"

"Perfect! It's for a t-spine MRI with contrast covering T1-T6"

"No, no contrast."

"The order was specifically with contrast"

"Our radiologists said that it's not needed for a thoracic spine area, and we don't like injecting people with extra dyes"

"Perhaps the radiologists aren't aware that I have a small pile of titanium in my spine. My surgeon specifically requested these two scans in this configuration."

"Well, surgeons aren't often aware of the differences between the scans."

"My surgeon is the co-director of the spinal research institute at the UCSF. I'm pretty certain he knows what he's asking for."

*sigh*
Jeff with Leif and Piano

Crap error messages

updated

When writing software, *please* don't give error messages that are only meaningful to developers of the software. Microsoft used to be awful for this: "System fault at DEAD:BEEF, please contact your system administrator". Which would've been cool, except that I *was* the system administrator.

My most recent encounter with this was this morning with bzr (On my work laptop, so it's Windows):

C:\Users\jeffbailey\workspaces\webhack\Webhack>bzr push lp:~jbailey/webhack/trunk
Connected (version 2.0, client Twisted)
SSH C:\Users\jeffbailey/.ssh/id_rsa password:
Authentication (publickey) successful!
Secsh channel 1 opened.
bzr: ERROR: RemoteRepository(bzr+ssh://bazaar.launchpad.net/~jbailey/webhack/trunk/.bzr/)
is not compatible with
CHKInventoryRepository('file:///C:/Users/jeffbailey/workspaces/webhack/Webhack/.bzr/repository/')
different rich-root support


Umm. What? Okay. I work for a search engine. So I fired up Yahoo!^WGoogle to figure out what the message could possibly mean. The top result is Bug 172360 in Launchpad:
"branching from rich-root to non-rich-root gives confusing errors"

Sounds perfect, until you see that the bug is marked as invalid.

Something got missed here. If your user says "I don't understand" - they are NEVER wrong. It doesn't matter if you think they should've understood. It doesn't matter that you think you explained it well enough. The user doesn't understand, so you lose. Actually, it's worse. *they* lose.

There are lots of other bugs leading up to how I got to where I was seeing this in the first place. But none of those are as important as the fact that the developers thought a user saying "I don't get it" wasn't worth the 30 seconds of adding the text "The best way to fix this is to run: bzr upgrade --default " + branch.url;

Update: Jelmer pointed out to me in a comment that it wasn't the devs who marked it as invalid, it was the submitter. He's reopened it. This just further supports the notion that users are insane and need hand-holding. =)
Jeff with Leif and Piano

Karmic review

Angie has my old laptop that some might remember from a couple Ubuntu developer summits. Adam Conrad used to refer to it as the surfboard: a lovely 15" widescreen laptop. It's my test machine for Ubuntu updates and so far I'm loving Karmic. This machine has been continually upgraded since either Hoary or Breezy without a reinstall.

Jaunty was miserable. Bugs in the Intel drivers meant that DVD playing stopped working, sounds would occasionally lock up, and things were just painfully slow. Karmic to the rescue. I did the update at beta time like I usually do, and without any further effort:

* Flash just worked.
* DVD playing in totem just worked.
* Boot time was slightly quicker
* nethack-gnome continues to work (despite being removed from the archive a few releases ago)
* Suspend/resume continues to just work.
* Atheros wireless continues to just work with the free kernel drivers.

I then added the dev channel of Google Chrome, which imported all the Firefox bookmarks and started to remove some optional things that Angie doesn't use anymore and don't run well on the now 5 year-old laptop. I took out openoffice, a pile of -dev packages that were leftover from when I used to build glibc on this thing (This laptop had the Hurd running on it at one point... *g*), and then discovered the System->Admin->Package Cleanup (Or at least, it's called something like that, the laptop is in French) where I could start to remove unused packages. I did a few rounds of that, some apt-get autoremove. I took universe and multiverse out of the packages list and did some more removals, making sure to leave in things like deborphan and the gstreamer packages that are in universe and multiverse. Lastly, I did a round of deborphan to take out some pieces that were just hanging out.

As a final step I've updated to grub2. I don't have a separate /boot partition on this machine, so I haven't been brave enough to convert it to ext4 yet.

The boottime at this point still feels a little long for what this laptop does. While at Canonical, I played with some appliance configs and had from kernel load to running firefox in a dozen seconds or some. This laptop doesn't have anything I'd see as unusual for daemons - there's no mysqld, sshd, or anything unneeded like that. But to have everything Just Work(tm) at this stage is amazing.

Nice job. =)

update: Angie's asked me to figure out why the screen saver kicks in after 30 seconds instead of 10 minutes like it's set to. But still, if this is the worst that goes wrong with this release, then it's still a wild success already at Beta.
Jeff with Leif and Piano

Home Media Server

I'm been wrestling with the idea of a home media server for a bit. Our home computing needs are pretty light, they only thing either of us really do outside of a web browser these days is ssh (me) or nethack (Angie). Outside of the laptop we have a pretty standard non-connected house. The only case where I'd really like to change this is music. We don't generally watch TV (and when we do, it's usually DVDs that we've actually purchased), but we do listen to a fair amount of music. The CDs tend to get scattered around the house and then mauled by our velociraptor offspring.

I looked at the Squeezebox, which would be perfect if it wouldn't mean replacing a whole bunch of perfectly good stereos with a whole bunch of nicer-than-we-need stereos.

The solution I've hit onto is this: a NAS with an FM transmitter on the site. The LineX one looks like it would do a nice job since it just acts as a USB speaker. The question then is figuring out if there's software or whatnot to drive such a thing.

What I think I want:

* 802.1n NAS with no moving parts. 2 64GB USB keys in a RAID-1 config would do the job nicely.
* Enough horsepower to play Oggs, MP3s and FLACs.
* Remote song selection through an Android app.

Anyone know if anything comes close to this? The best thing I can think of is perhaps Debian running on a Linksys NAS box. If I could get that far, then the software seems pretty straight forward if it doesn't exist in some form or other in the Debian archive already.
Jeff with Leif and Piano

Google Shadow Government

There's a fabulous sign outside of the Googleplex:



Of course, perhaps I need to look a little more sinister:



But hey, at least citizens of Google, Inc. all have medical...

(Thanks to Oleg for the photos!)
Jeff with Leif and Piano

CSS Spriting Tricks

For a project I'm having fun with, I have a tilemap that I want to use for sprites. Each tile is cleanly 16px by 16px.

Searching on the Interwebs, most people recommend making a background image and then using background-position in CSS to shift which image is being viewed.

There are a couple drawbacks to this:

1) You now have to put *something* in the element in order to make sure that it still exists on the page. So what usually happens here is a 10000px text-indent so that there's no chance that it will appear in the viewport.

2) You now have no option of scaling the image at all.

It turns out for option #2, there's some sort of magic scaling going into CSS3 called background-size, but it's not clear to me that it allow arbitrary aspect ratio changes.

I thought about it and came up with the following solution that seems to work well enough for me:

<!DOCTYPE html> <html> <head> <style> .wh-mapelement-image { position: absolute; } .wh-mapelement-container { position: absolute; height: 16px; width: 16px; overflow: hidden; display: block; } </style> </head> <body> <div class="element-container"> <img src="foo.png" class="element-image" width="640" height"432"> </div> </body> </html>
A .wh-mapelement-container:hover can be added here with left:-16px top:-16px to give the rollover effect to the sprite.

But wait! THAT'S NOT ALL!

If I double the width and the height on the image link, I can also double the width and the height in the container. That way, the browser's image size manipulations will work as expected and I can see my 16x16 pixel sprite on this reasonable DPI screen.
Jeff with Leif and Piano

Maybe Obama *is* the messiah...

Apparently there are mobs of people with guns attending town halls to complain about health care in the US. I've often told people that they should ease up on Obama because he's not the messiah, but this is starting to sound quite familiar...
Jeff with Leif and Piano

Overheard in our bathroom...

Leif's in the bath, Angie just took away the foam animals that Leif decided to eat.

Animals, animals.
You want the animals?
Yes
Are you going to eat the animals?
.. eat the animals.

Hmm.. I expected rebellion against veganism at 15. This seems a bit soon... ;)