Catholic Voters’ Guide

The Diocese of Manchester passed out a voters’ guide. As previously mentioned, this immediately worried me.

It begins with a disclaimer that they don’t endorse any candidate, party, or PAC, but outlines seven issues. (Bold captions are their headings, the rest of the text is my commentary on it, unless quoted, in which case it’s quoted from the aforementioned publication.)

The Right to Life and the Dignity of the Human Person.

Of course this covers abortion, but they also include “destruction of human embryos for research,” an “intrinsic evil.” (Of course, one’s “dignity” is the exact terminology used by proponents of euthanasia and physician-assisted suicide to promote one’s right to euthanasia when they’re in pain and near death, so it’s an ironic wording choice.)

Curiously, they add “This teaching also compels us as Catholics to oppose genocide, torture, unjust war…”

Of course, I oppose genocide and torture. The “unjust war” bit is interesting: I can think of only one thing that they might be referring to, but I don’t know if they’d be so vague if that’s what they meant.

Call to Family, Community, and Participation

It starts off that family, “based on marriage between a man and a woman” (of course they’d add this), is fundamentally important. While I’m not sure why the families have to be between a man and a woman, I’m also not sure what this one is trying to say. It basically just talks at length about how policies should work on supporting families, their needs, and “the common good.” (Honestly, the first thing that comes to mind is universal health care.)

Rights and Responsibilities

They start off with right to life (anti- abortion and death penalty), but then add “Each of us has a right to religious freedom”–obviously the church isn’t going to oppose this, but I’m a bit proud that they’re eager to support peoples’ rights to not be Catholic, too. And then they add that we all have the right to “those things required for human decency–food and shelter, education and employment, health care and housing.” (Emphasis mine.)

Option [sic] for the Poor and Vulnerable


Dignity of Work and the Rights of Workers

They call for a living wage and “opportunities for legal status for immigrant workers,” which seems to amount to tacit support for affording humane treatment to illegal immigrants.


I’m going to quote this one verbatim because it’s so well-done: “We are one human family, whatever our national, racial, ethnic, economic, and ideological differences. Our Catholic commitment to solidarity requires that we pursue justice, eliminate racism, end human trafficking, protect human rights, seek peace, and avoid the use of force except as a necessary last resort.”

Care for God’s Creation

“God’s Creation” is then implicitly defined as the Earth.

All in all, I’m left with a positive note. One thing that drives me mad is when people try to use the church to justify atrocities. The “moral majority” often seem to be the same ones advocating killing illegal immigrants as they cross the border, torturing suspected terrorists, opposing health care, and fighting living wages. I wish they’d come to their senses about same-sex marriage, but I really can’t fault them on abortion, which is a much trickier issue. I thought I’d be outraged by this guide, but, in actuality, it seems to support many of the things I support, and, for the most part, does so very tactfully in a way that still requires that people think for themselves.

Das Klunker

In the past few days, we’ve spent way more time shoveling snow than is reasonable. We have a relatively long driveway, and it’s a major pain to shovel it. We have a snowblower, but it’s really not all it’s cracked up to be. And last time I was in the garage half of the engine appeared to be removed.

While I think it’s more of a pipe dream than anything, my dad and I have been kicking around the idea of picking up an old junker of a truck. It should run and pass inspection (or be reasonably easy and cheap to fix), but some rust and crappiness is okay. Something like this. And then we’d throw a plow on the front. It’d be useful for our weekly runs to the dump, and, of course, for plowing. (Plus, there’s a lot of “cleanup” we’d like to do–there’s probably about two feet of snow on the side of the road that could be pushed back, and the town did a terrible job plowing the entrance to our street. And there are huge snowbanks, something we’d love to push down a bit.

It turns out that plows are expensive, and good, running trucks are also way more than I thought. From having seen junkers on the side of the road in the past, I was fairly convinced we could do this for under $500. It’s now looking like $2,000 is a better price range.

Or we could just get a just-broken-in Lincoln (Presidential Series!!) for a mere $500. (Step one: remove garbage from floor. Step two: try to clean up the leather a bit. Step three: resell.) Actually, I’d love to try to take my ‘radio arbitrage’ skills and apply them to autos, except that having an extra radio is well and good, but having four broken-down cars in my parents’ driveway might not be as well received. And, you know, the fact that they’re a lot more expensive and thus a lot more risky.


So I’m a huge fan of Ask Metafilter. The basic premise is simple: you ask a question and lots of people answer. But Ask MeFi rocks because they maintain high standards. So you actually get really good answers. It costs $5 to join, which is done to pay for the servers but, frankly, seems like a good way for keeping crap out, too.  You’re allowed one question a week, so I try to make it good. But oftentimes, I put it off for several weeks for want of something worthy of using up my question.

So I started a list. And I figured I’d allowed voting and comments. And before I knew it, I had this monstrosity. It was actually extraordinarily simple to code, too. I hope to add better questions over time: these are the ones that were on my mind at the time. You can vote (the + and – buttons), and leave comments. Feel free to do so. (I’m not taking question ideas: get your own account if that’s what you want!)

Coding Malpractice

I just wrote the following line of code. And it’s no mistake: it functions perfectly and does exactly what I wanted it to do:

$count += 0;

This is surely poor programming practice, essentially implicitly recasting a variable as an integer. But it’s simple and it works flawlessly. (The context: I run an SQL query saying SELECT SUM(votes)..., which makes the tabulation of all the entries MySQL’s problem, not mine. The one ‘flaw’ is that the sum of no votes isn’t 0, but NULL. This becomes a very important distinction when you’re trying to display a number: “0 votes” isn’t the same as ” votes.”)

Since we all know that NULL + 0 = 0 (and, of course, integer + 0 = integer), adding 0 works flawlessly. Could I just convert it to an integer? Probably. But I haven’t done that stuff in a while, and I was far too lazy to pull up the documentation. And incrementing a variable by 0 is way more fun.

Saving the Auto Industry

My whole family drives Toyotas. We love America and all, but we want good, solid cars. The U.S. is, understandably, concerned about how much oil we’re using. So we’re trying for a requirement that, by 2020, all cars sold get 35mpg at a minimum. Of course, the car companies are complaining that this is going to be incredibly difficult to do.

Two comments:

  • This is utter BS. My mom gets 50 mpg with her Prius. Honda did it in 1987.
  • Why does the government need to get involved? The way I think it should be working is that we say, “$3 a gallon for gas is ridiculous! I want a car that gets better gas mileage!” We stop buying cars that get horrible gas mileage, and, consequentially, Detroit stops making cars that get horrible gas mileage because no one is buying them. It costs me $40 every time I fill up. I wince every single time.

I found this video online. I’m not going to lie: it’s dry, and 20 minutes long. I was kind of proud to follow him most of the time as he talks about internal rates of returns and demand pull and the like. He makes some extremely obscure references, and even now, I’m not sure what he was talking about with oil at $12 a barrel.

And yet, despite it being presented in a technical, academic manner to an audience that’s definitely not normal people, he makes some points that are really, really, really worth hearing. One of the simplest ones: efficient cars are going to be made, the question is who’s going to make them. And, at least right now, it’s not us. (And it really boggles my mind, frankly. Ford makes one hybrid: the Ford Escape Hybrid. 34mpg on an SUV is impressive (I get 20-22). But what the heck market are they appealing to? They manage to completely dilute the effects of a hybrid engine by putting it in an SUV.)

GM developed a “concept car” 16 years ago that, as I recall, got close to 100 miles a gallon. Where is it?

Besides oil, another huge problem we’re facing is a ridiculously huge trade deficit. If we could make cars good enough that we wouldn’t have to keep importing cars, we could certainly help.

He presents some amazing statistics, too. 87% of the energy from fuel used in cars is utterly wasted. Only 6% of the total energy actually moves the car. (And when you figure in that the car weights significantly more than the passengers and luggage, he says that less than 1% actually moves the passengers.)

He says the solution is to lighten the car. I cringed for a minute. Lighter cars, especially on today’s roads, are asking for disaster. You can go drive your 500 pound car, and I’m sorry if I kill you when you crash into my SUV.

But it turns out that this is somewhat wrong. He showed a picture of a McLaren SLR (a $400,000+ car) that was made out of carbon fiber. It’s very light. Some idiot T-boned the car. Their car was totaled. The McLaren driver had to buff out a scratch in the paint. He suggested that, if you were to smash the car head-first into a brick wall, about 25 pounds of carbon fiber is all it would take to absorb the impact and let you walk away unharmed.

He goes on to call heavy cars “hostile cars,” and really, he’s got an excellent point. We’re making heavy cars solely for safety with other cars. But we can increase fuel efficiency, maintain (or increase!) driver safety, and decrease risk to other motorists by simply changing materials.

Oh, and one final point he makes that I thought was interesting: we think of OPEC as a cartel that has tons of power. In actuality, our power of demand far outweighs their supplier power, and we have the power in the equation. Except that we can’t stop buying oil. Years ago we saw a lull in demand, and basically gave OPEC the bird. He suggests doing it again.

I didn’t expect to watch the whole video, which is 20 minutes long. But before I knew it I was done. And it’s pretty thought-provoking.


I’ve been itching to start up a Boston-based dedicated server company. There’s surprisingly few options. As I dig around I’ve found a few that exist, but they’re practically unheard of. I want to start one up and do some good marketing. Name recognition is pretty big when it comes to dedicated servers. However, none of the people I’ve talked to so far (my mom) has been willing to give me the ~$100,000 start up capital I’d need.

I have slightly different plans for furnishing the racks I’d want in a colocation center, but there are plenty of good deals to be had on eBay, in case anyone’s in the server market.

  • 1U Dell, dual 3 GHz Xeons, 1 GB RAM, 73 GB SCSI (10K RPM). $485 + $25 shipping.
  • If you’d prefer disk space over disk speed, there are also 1U SuperMicro machines, a 2.8 GHz Xeon (dual-capable, but not so equipped), 2 GB RAM, and a pair of 250 GB disks. About $400 shipped.
  • Comparatively expensive, but $1500 buys dual 3.2 GHz Xeons, 4 GB RAM, and 3x 146 GB SCSI disks.
  • Not cheap at all, but dual quad-core processor, 16 GB of RAM, and 6x 146 GB disks is my type of machine! $5375 if you’ve got the cash burning a hole in your pocket… (It looks like these processors support VT virtualization, so you can run something like Xen on it and host multiple virtual machines, Windows or Linux, without problems.
  • Dual 3.2 GHz Xeons, 4GB RAM, and a pair of 750 GB disks? $1277+58 seems like a pretty good deal!

Subtly Bad Code

Alright, let’s have a little fun… I just added a new blog and went to include it on the main page, but my code failed citing the database throwing errors. It took me forever to find. I’m curious if others can find it.

I was further confused because the code worked fine until I added the new blog to the list of ones for it to use, and it was specifically built so that it wouldn’t matter how many blogs there were. It has a separate file that just lists blogs to include, and reads that file at runtime and builds a query to retrieve posts from all of them.

You need some background, first… All the posts are stored in a database, so each has its own table. I built this monster query, basically looking something like (Get most recent posts from blog 1) UNION (Get more recent posts from blog 2) UNION (…3…), and then tack an “ORDER BY…” onto the end. Credit for this idea goes to Andrew; I’d have never thought of it myself.

What the list includes is blog IDs in the database. They ranged from 2 to 9, skipping 8 (which isn’t used). After a bout of spam registrations, the numbers got run up, so when I included the new one, it was numbered 51.

The below code (in PHP) calls some custom-rolled functions, but I’ll just say up front that the error does not depend on understanding how they work. Similarly, the answer does not have to do with caching in any way, so don’t get too hung up on the amount of code devoted to working with the cache. (And finally, I’m building one huge variable called $query the whole time, and then return that variable… This isn’t a crucial thing to understand either, I just wanted to explain it since it’s somewhat of a bizarre practice. .= is the PHP variable concatenation method.)

// $count is the number of blogs to pull out
function genRPQuery($count) {
  // Retrieve it from Memcache
  $query = getCachedObject("bigquery-$count");
  // It'll return NULL if it doesn't exist, so we check for that...
  if($query) return $query;

    // Since we're here, we didn't return, and
    // thus didn't get it out of the cache

    // Next two lines read in the files. blogList()
    // returns a list of the blogs -- it's little more than a
    // file read with caching enabled.
    $blogs = explode(',', rtrim(blogList(),"n"));
    $fields = rtrim(cachedFile('./',30), "n");

    foreach ($blogs as $i) {
      // We have a loop for each blog
      // For unfamiliar eyes, .= is PHP's means of variable concatenation
      // We're building a ridiculously-long query, each one a SELECT, encased in
      // parens, and we UNION them all together...
      $query .= "(SELECT $fields FROM wp_" . $i . "_posts WHERE post_status='publish' AND post_type='post' AND post_password='' ORDER BY post_date DESC LIMIT $count)n";
      // If we're not on the last one, insert a "UNION" in (see above)
      if($i<sizeof($blogs)) $query .= "UNIONn";
    // Done, so now we order them, getting just the most recent $count ones
    $query .= "ORDER BY post_date DESC LIMIT $count;";

    // Insert it into the cache for 15 seconds for next time!
    cacheObject("bigquery-$count", $query, 15);
    return $query;

Remember, it worked fine when the list was blogs number “2,3,4,5,6,7,9” but the simple change to “2,3,4,5,6,7,9,51” causes it to blow up and try run a query with invalid syntax. This made no sense to me, since the code was built to not care about things like that. I eventually found it, and feel like an idiot.

I’ve posted a hint in the comments… It’s in the interest of fairness because I turned on some debugging and got the information I share. But it also really narrows your attention to a couple of lines, so I don’t want to include it in the main post.


My e-mail setup right now for and consists of just forwarding all e-mail to GMail. It works fine, and the spam filters there have been pretty much 100% effective. However, it bothers me that I’m forwarding dozens, if not hundreds, of e-mails just to have them ignored. Some basic spam filtering should really take place on my server.

I made a few basic configuration changes to Postfix, the MTA I run. In a nutshell, I tell it to require stricter compliance with e-mail RFCs: e-mails with HELO addresses that don’t exist (or just don’t make sense), and people sending multiple commands before the server replies to acknowledge them, for example, now results in mail delivery failing. The default configuration errs very much on the side of ‘safety’ in accepting mail, but the trick is to tighten it down enough that you’ll reject mail that’s egregious spam, but not reject anything that could be from a mailserver. And that’s where I’m at.

I also installed SpamAssassin. I’m currently using it in conjunction with procmail, and therefore wasn’t quite sure if it works. I set it up to make some changes to the headers, so that I can verify whether it’s working. But I ran into a problem I never thought I’d have: I’m not getting enough spam. I’m sitting here eagerly awaiting some to see what happens. And it’s just not coming.