Thursday, December 28, 2006

Why comments are closed on my blog.

This is belated...anyway, I'm taking a day off work to get ready for our vacation this weekend, and I remembered (after writing some other blog posts) that I meant to chime in on a Planet Debian discussion about closed vs not-closed blogs.

My reason for closing comments was quite simple: blogs are spam-magnets. While I was a student and/or unemployed, I didn't mind spending a few minutes a day purging spam messages from my blog. But when I started working full-time, it became a real chore, especially since the amount of spam I got increased with the number of posts on the blog.

One thing that would change my point of view here would be the option to automatically close comments on posts that are more than (say) 60 days old, or perhaps that haven't got a (non-deleted) post newer than 60 days. This would keep the spam problem down, since my biggest problem was ancient blog posts that no-one had commented on (at least for months or years), but that suddenly got picked up by spammers. This might be available if I ran my own blog, but I don't have the time at the moment to administrate a home server, so I'm stuck using someone else's software.

I'm a top contributor too!

Adrian von Bidder notes that he got a message from a random survey group asking for feedback.



[...] we analysed the debian mailing list archives, especially the debian-devel mailing list, as it is a good representation of the whole network. [...] we identified the 100 main actors and therefor came across your email address.


So, somebody who talks quite a bit on the mailing lists, but really only maintains one package is already one of the top 100 "actors" in Debian? I seriously doubt it.


It gets better. In the last couple years I've barely posted on any public Debian mailing lists at all. And yet I'm apparently also in the top 100 "actors". Say what?

Microsoft: Copyright law is for other people?

Unsurprising, sad, but still amusing: this guy photographed talks given at a computer conference and released them under the Creative Commons Non-Commercial Attribution license. A Microsoft senior program manager copied his work as part of an advertisement, without attribution.

Try violating Microsoft's copyrights and they'll bury you under lawyers and moral outrage. But catch them violating yours and it's laughed off as no big deal (some of the huffy responses from Softies on the blog post I referenced are pretty funny).

Of course, in a real sense, it isn't a big deal: "might makes right" is a dreadful moral principle but a largely accurate summary of how the world actually works. But exposing the hypocrisy of the powerful at least forces them stop pretending that they are anything but overgrown, sanctified, self-righteous bullies. (this doesn't actually make anything better (even if you get rid of one bully, he'll just be replaced by another one), but at least it means you don't have to gag on hypocrisy every time they open their mouth)

Saturday, December 16, 2006

urlscan 0.5

If, like me, you use the mutt mailreader, you may at some point have tried out the urlview program to quickly jump to URLs in emails. urlview is a nice concept, but it has a few limitations, the worst of which is it doesn't decode quoted-printable emails (so, e.g., CGI urls containing equal signs get escaped and become useless).

With the increasing number of dynamic URLs and quoted-printable emails out there, this has rendered urlview more or less useless for me. A couple weekends ago, I got annoyed enough to do something: I wrote a quick-and-dirty Python replacement for urlview, called urlscan. I'm not proud of all the code, but thanks to Python's great standard library, it can decode just about anything you throw at it; it also extracts some context around each URL, so there's less guesswork involved in picking URLs.

I've uploaded urlscan to unstable (it just went in today), in the hopes that someone out there will find it useful. Enjoy. :-)

Saturday, December 09, 2006

DRM: "If there is hope, it lies in the proles^H^H^H^H^Hpols"?

In response to my recent mistaken post about Samsung and DRM, Adrian von Bidder wrote that

I think this battle will have to be fought in politics7. Battling the vendors is fine, but will be endless, the real goal should be to anchor a broad [4]right to tinker in the bill of rights which also extends to non-commercially used information.


On one level, this is probably true. But this amounts to the government passing laws that increase the liberty of its citizens and decrease its own control over them, while at the same time exposing the corporate interests that sponsor the government to increased competition. Governments almost never do this, for obvious reasons -- probably the only example in recent American history that I can think of is the Civil Rights Act of 1964, over forty years old now, which addressed inequalities that the average person could understand easily and was preceded by significant popular unrest (much more than a few guys dressing up like hazardous-waste-disposal crews and walking around outside computer conferences).

In fact, the most likely outcome of the government getting involved in the DRM situation, in my opinion, is a bill making DRM mandatory for all hardware devices and requiring software (or at least software that can run on mass-market computers) to go through a process of certification that attests that it respects DRM. This will be the final nail in the coffin for the free software movement, and I don't think we want to hasten its arrival.

I think the best we can hope for in this context is the prayer from "Fiddler on the Roof":


Lord, bless and keep the Congress

... far away from us!

Apologies to Samsung

I need to learn not to write blog posts after 9pm, given that my brain starts fogging up around 8:30pm.

Apparently the only reason I couldn't play DVDs is that I had forgotten to install the DVD decoder library. Doh. And apparently the reason the DVD wouldn't play yesterday is that the video program was trying to get the drive to decode the DVD for it -- which I can understand Samsung not wanting to do, since it would get them in legal hot water. (what ticked me off was that it looked like they were going beyond the minimum and keeping me from even reading the encrypted DVD data)

So, the problem is that Daniel is a doofus. I want to apologize again for being a little trigger-happy last night -- especially since this is syndicated, it sucks to have put incorrect information out there.

Hungarian notation is a human-checked type system, redux

A while ago, I read an article that advocated the use of Hungraian Notation for purposes that can easily be folded into the type system and automatically checked. I wrote a blog post in reply that gave a rough sketch of a solution to the fundamental problem in Haskell. Well, someone else apparently read the same article and had the same idea; the only difference is that the solution he produced is infinitely superior to mine and everyone should go read it instead.

Friday, December 08, 2006

Hardware manufacturers to avoid: Samsung

[UPDATE 2: the problem is of the form "Daniel is an idiot". See this post for details. DRM is still evil, though.]

I recently assembled a little Mini-ITX system, mainly for use as a file server/desktop replacement/music server. However, it has a DVD drive, and it has a hardware MPEG2 decoder. So today, feeling a bit lazy, I decided to try displaying a DVD on the box instead of using the DVD player. This is when I discovered that my computer's new DVD drive is defective.

hdc: command error: status=0x51 { DriveReady SeekComplete Error }
hdc: command error: error=0x54 { AbortedCommand LastFailedSense=0x0
5 }
ide: failed opcode was: unknown
ATAPI device hdc:
Error: Illegal request -- (Sense key=0x05)
Read of scrambled sector without authentication -- (asc=0x6f, asc
q=0x03)
The failed "Read 10" packet command was:
"28 00 00 00 01 c0 00 00 02 00 00 00 00 00 00 00 "


Yes, you read that right.

So, I won't be buying any more Samsung hardware until they figure out that I am their customer, not the MPAA. I realize this is an utterly futile gesture, that Samsung won't even notice my lack of custom, that this will make not even a dent on the juggernaut of DRMed/TPMed/locked-down hardware/software systems that are coming in the future, and that the end result is that I quit using computers entirely and go raise chickens...but you know, right now I think I'm mad enough not to care.

PS: Even worse: based on some discussions I found online, I ran a quick check of the CD reading speed -- and it appears that the drive now refuses to read CDs any faster than 2-3X! This is absolutely the last dollar that Samsung is getting from me, and if the store's return policy allows it, this sucker is getting RMAed tomorrow.

[UPDATE: the store I bought the drive from in October has a 30-day return policy, so I'm stuck with the one I've got. Probably I won't bother with getting DVD functionality on my next optical drive, it's not worth the obnoxiousness.]

Tuesday, December 05, 2006

Things I miss about being an Undergrad.

So, it's been about 4.5 years since I got my ScB, 1.5 years since I got my MSc, and 1 year since I started working at Satori. Seems like an ideal time to look back on the halcyon simplicity of college, right? Here are a few things that I really wish I had appreciated more in 2000.

(1) Getting enough sleep.

I was just about the only well-rested student I knew in college. When other people (who stayed up past midnight regularly) would complain that they seemed to spend lots of time working withotu getting anything done, I occasionally suggested that they try getting more sleep. Hah.

So, in grad school I developed some bad, bad habits -- staying up past midnight, sleeping in erratically, etc. (I like to blame my girlfriend, who refused to get up before 9-10am when she was a student ;-) ) I started to sort of get a handle on that, and then I got a full-time job.

The problem here is this: you know how they say that to figure out how much sleep you need, you should sleep until you wake up naturally and feel rested? If I go to bed at 9PM, I wake up naturally at 7-8AM or so. That's -- count it -- 10-11 HOURS OF SLEEP. As a student, I had the luxury of sleeping 11 hours straight (since I had no social life). As a working drone with an hour-plus commute, that would leave me with 3-4 hours to fit in all my non-work activities (like, say, eating; personal hygeine; etc). The fact that I tend to get heartburn if I lie down within 2-3 hours of a meal, and that I usually have to cook my meal before I can eat it ... well, this just isn't gonna work.

So, to get enough time to actually live a bit outside work, I end up curtailing my sleep schedule to "only" about 7-8 hours. I know that's enough for some people. I wish I was one of them. The result for me, though, is that I go through most days feeling dazed, tired, sleepy, and with an on-and-off headache. I can generally hold it together well enough to get through the work day (although yesterday I collapsed on the couch halfway through), but once I get home I lack the energy to do anything but feed myself and idly browse the Web. Trying to do anything intellectually challenging (hence interesting), like say learn Cantonese or category theory, is right out. (I can just about say I want to eat, and I got as far as power categories before getting horribly tired and confused)


(2) Breaks.

One great feature of college is that you get time off of it. In addition to some random vacations during the semester, you usually break for several whole weeks between semesters, and then break again in the summer. Even if you have a summer job, this is a great way to recharge the batteries.

In the working world, I get exactly 1 day off per month -- if I want a decent-sized break, I have to go several months with no days off at all (except the paid holiday day every other month or so that the company gives us in its beneficience).


(3) The cafeteria.

College students like to make fun of cafeteria food. They don't know how good they have it. You get three hot meals a day, plus you don't have to do ANY cooking or cleaning up? Sign me up!

When I get home at 6:30 PM and I'm starving, the first thing I have to do is get out the raw ingredients for my dinner and toss them in a pot, then gnaw on some cheese or something to take away the hunger pains until they're done. By 7:30, I might have some food in me, hopefully. I'm thinking about switching to a frozen-food diet (ew), although that doesn't help clean the dishes.


(4) There's no commute in college.

To get to work, I have to walk 10 minutes, ride the bus for about 30-40 minutes, then walk another 20 minutes or so. In the evening I have to do the reverse. That's 2-3 hours of my life sucked up by just getting to work and back. If my brain wasn't too fried to study any of the interesting books I've optimistically purchased (see (1) and (2)), it might be bearable...but when I just want to get some food and rest, it really sucks. And it sucks especially when I have no good alternative (living in Seattle is EXPENSIVE, and it would give Kate an even worse commute in the other direction).

(5) Having the time and energy to study topics or write software just for the heck of it.

This really incorporates all of the above. It seems like all these factors conspire to suck my time up, then suck up the energy I have in the little time left to me. Meh. For instance, right now (at 9PM) I am getting very sleepy and should get to bed, yet I've done nothing since I finished eating (at 7:30PM) but skim Lambda the Ultimate and a few linked articles sites (slowly) and write this blog post. Blah.




Lest I give the impression that I completely hate work, let me add that there is one very, very important thing that I enjoy about it relative to my student, free-software-hacking days.

(1) NOT BEING FLAT BROKE.

I believe this one is self-explanatory; and so far it still makes up for the rest (I wonder how long this will continue). It's too bad I can't get paid to just sit around doing whatever I feel like and then giving it away, but then it's also too bad I can't wave a magic wand to get a pony and a few dozen acres to keep it on.