Gradual Software

I have this little project that’s been 95% finished for months, ‘blogbot 2’, a python script which monitors a list of RSS/Atom feeds daily and sends out an email with all the new ones to a mailing list. Blogbot 1 was a ruby script where I rolled my own feed parser using Ruby’s built-in XML parser. Ruby’s parser rocks, but my wielding of it was only 90% good enough, so I wanted to leverage somebody else’s work and rewrite it in Python using the Universal Feed Parser.

I kept stumbling over Unicode issues. The UFP is so correct that it often returns Unicode, and Python’s unicode handling, while very good if you know how to use it, is pretty sucky if you are me. The default handling for unicode-to-string conversion is to use the ‘ascii’ encoding, which can’t handle practically anything, and the default behavior when it hits something it can’t handle is to throw up its arms and scream in mute horror. You cannot globally change these defaults; you have to catch it conversion by conversion and change them.

I finally got it all figured out and it’s working great. But I tore hair out over that last 5%.

Another project I’m working on is “artblog/imageblog” software. I want something which does no more nor less than I want it to, and does it well and easily. I’m hacking this one together in PHP/MySQL, and it’s been fun learning PHP. (Hint to anyone going to use PHP/MySQL: use Pear DB if you possibly can. It will rock your world. MUCH better API than the default mysql stuff.)

Anyway, I’m doing the artblog thing very graduall, and that’s turning out to be a good thing. Cause it means I don’t spend too long going in the wrong direction. The big trick with PHP/MySQL is to decide what ought to be a PHP issue and what ought to be a MySQL issue. Originally I had this concept where I was going to have thumbnail images listed in the same table as fullsize images, and have a many-to-one relation between them via an extra column in that table that related back to itself. (This was actually my second iteration — originally thumb images were in their own table with a many to one relationship to the main table… this was while I was still thinking I would ever actually care to have multiple thumbnails for the same image, which I decided in the end I never would.)

Anyway, I ended up deciding “screw all that — I’m going to have thumbnails be created automagically if they don’t already exist via PHP magic, and the database isn’t going to know or care about them.” I coded it up and it’s awesome.

The thing is, I had all of these ideas in the time I wasn’t working on the project. I’d work on it for a while and then do other things (cause I don’t have that much spare time for it) for a day or three at a time. Then by the time I’d come back I’d have had a lot of time for those “standing there in the shower and suddenly realize how the system ought to be designed” moments.

This project is going to be better than it would have been because it’s gradual. All these people are on about “rapid/agile development” — well, I think development is more agile when it’s less rapid. Because if you move fast, then you get a lot coded the way you first thought of doing it, which is seldom the best way to do it.

This is not a friendly world for gradual activity though, and the programming world is especially unfriendly to gradual development.

Ah well.

Was heisst Christian?

From the Daily Tennesean:

Every day now it’s possible to meet Christians too embarrassed to call themselves Christian.

I encountered some the other day at a local church.

”Call me a follower of Christ — anything — but not ‘Christian,’ ” one Christian woman said. She put air quotes around ”Christian.” Two others nodded grievously.

They are not ashamed of being Christian. They just can’t use the word anymore. To them, ”Christian” is tarnished, radioactive. To them, it’s synonymous with Republican anger, corporate power, and Bible sound bites opposing all challengers to traditional America. […]

As never before, evangelical Protestants own the label Christian, even though they are outnumbered by other churchgoers. Why don’t the others take back ”Christian”? What happened?

What happened is the non-evangelicals lost a Thirty Years War of spiritual marketing, a war over the Christian brand name and the Bible, too.

It happened gradually. In the ’70s, ”Christian music” surfaced as the willing soundtrack for a bold, new, market-oriented evangelical faith. Its message was Bible-based and energetic. People took notice. In the ’80s, the Moral Majority happily stepped into the public square to equate political conservatism with Christianity. In the ’90s, the Christian Coalition deepened the public impression. All the while, ”Christian” came to be associated with theologically conservative Bible colleges too.

This ”Christian” makeover was reinforced every Sunday across America with the rise of nondenominational megachurches. ”Christian” is now the preferred identity of millions who attend these non-aligned (but Protestant) congregations, which reject historic identities such as Methodist or Church of Christ. They’re just ”Christian.” And theologically conservative.

The mainliners, progressives and liberals hardly knew what hit them. They had led the way after World War II — the religion of the establishment in the ’50s, then the religion of progressive political reform in the ’60s. They took risks. They dared to face America’s traumatic social changes. They honored the nation’s emerging diversity. But they lost their unity as a result. Then, sometime in the ’70s, they stopped quoting the Bible in public.

Perhaps liberals lost confidence in the old authority of Scripture — or at least forgot how to use the Bible to challenge fundamentalism itself.

This abdication was costly. Scripture is full of passages that embarrass political conservatism. Page after page, it says God cares about the underdog and the weak. It warns against national arrogance and folly. Jesus blesses the peacemakers, the poor in spirit, the poor in society. Pray in secret, he said. Today, judging from the media, the Bible is largely associated with a theology of suburban isolation, spiritual warfare and tax cuts.

The Christians I meet who forsake ”Christian” are caught in a cruel irony: Their Christian faith explains the way they are. It’s not their style to get in your face. They don’t have a taste for smack downs. They’re ambivalent about power. They’d rather do neighborhood good works than talk about culture war. They’d rather read the Sermon on the Mount than the Book of Revelation. Sociologist Nancy Ammerman calls them ”Golden Rule” Christians, believers who prefer action over doctrinal purity. They stand for values they associate with Jesus — kindness, fairness, care giving, trust in providence — traditional values that are fading fast in a culture of celebrity capitalism, casinos and cutthroat profiteering.

In the 24/7 media world, a permanent culture war grinds on, a noisy scrimmage of symbols. ”Prayer in schools” and ”God Bless America” are powerful symbols. So is ”Christian.” The Christians who reject ”Christian” ought to rejoin the national conversation and bring their Bibles. They’ll be cheered by what they find there in the Prophets, the Psalms, the words of the Galilean. They’ll discover something else: The word ”Christian” doesn’t appear in the Gospels at all.

Things are more complicated in West Michigan. Traditional Reformed Calvinism isn’t precisely “mainline” (the Reformed Churches of America probably are; the Christian Reformed Church, no) but they don’t really have anything historically in common with American Fundamentalism & Evangelicalism except the CRC & company’s theological conservatism (of a particularly Reformed stripe). However, the evangelical “we are Christianity, everyone else is The World” movement has long creeping tentacles and infiltrates everywhere. You’d think the last thing that Calvin College needed was a Campus Crusade for Christ, but there it is. I wonder how long it will be possible for the Reformed Christians of West Michigan really maintain their distinct identity from the expanding marketing monstrosity which defines itself as “Christianity” itself?

As for witch hunts, the Reformed groups tend not to so much expel individuals for deviation as to constantly fragment. Interestingly, the smaller the fragments the more angrily conservative they tend to be — the mellow RCA is much bigger than the intense CRC, which is itself much bigger than the freakitudinous Protestant Reformed Church, and so on. That’s kind of a cheering thought.

I have no point here, just wanted to link the interesting article I got from Blogopotamus! and add a few random personal musings.

Mounting evidence of a hacked election

I remember hearing about this when Janet Reno took a dive in the primaries. This story has been building for years.

Common Dreams

via Dan Gillmor.

The scary thing is that this was not happening in the touchscreen voting booths, but the optical scan ones, which are far more widespread (we have them here in our part of MI)

Florida Secretary of State Presidential Results by County 11/02/2004 (.pdf)
Florida Secretary of State County Registration by Party 2/9/2004 (.pdf)

While the heavily scrutinized touch-screen voting machines seemed to produce results in which the registered Democrat/Republican ratios largely matched the Kerry/Bush vote, in Florida’s counties using results from optically scanned paper ballots – fed into a central tabulator PC and thus vulnerable to hacking – the results seem to contain substantial anomalies.

In Baker County, for example, with 12,887 registered voters, 69.3% of them Democrats and 24.3% of them Republicans, the vote was only 2,180 for Kerry and 7,738 for Bush, the opposite of what is seen everywhere else in the country where registered Democrats largely voted for Kerry.

In Dixie County, with 4,988 registered voters, 77.5% of them Democrats and a mere 15% registered as Republicans, only 1,959 people voted for Kerry, but 4,433 voted for Bush.

The pattern repeats over and over again – but only in the counties where optical scanners were used. Franklin County, 77.3% registered Democrats, went 58.5% for Bush. Holmes County, 72.7% registered Democrats, went 77.25% for Bush.

Yet in the touch-screen counties, where investigators may have been more vigorously looking for such anomalies, high percentages of registered Democrats generally equaled high percentages of votes for Kerry. (I had earlier reported that county size was a variable – this turns out not to be the case. Just the use of touch-screens versus optical scanners.)

More visual analysis of the results can be seen at http://us together.org/election04/FloridaDataStats.htm, and www.rubberbug.com/temp/Florida2004chart.htm. Note the trend line – the only variable that determines a swing toward Bush was the use of optical scan machines.

One possible explanation for this is the “Dixiecrat” theory, that in Florida white voters (particularly the rural ones) have been registered as Democrats for years, but voting Republican since Reagan. Looking at the 2000 statistics, also available on Dopp’s site, there are similar anomalies, although the trends are not as strong as in 2004. But some suggest the 2000 election may have been questionable in Florida, too.

One of the people involved in Dopp’s analysis noted that it may be possible to determine the validity of the “rural Democrat” theory by comparing Florida’s white rural counties to those of Pennsylvania, another swing state but one that went for Kerry, as the exit polls there predicted. Interestingly, the Pennsylvania analysis, available at http://ustogether.org/election04/PAvotepatt.htm, doesn’t show the same kind of swings as does Florida, lending credence to the possibility of problems in Florida.

Even more significantly, Dopp had first run the analysis while filtering out smaller (rural) counties, and still found that the only variable that accounted for a swing toward Republican voting was the use of optical-scan machines, whereas counties with touch-screen machines generally didn’t swing – regardless of size.

Others offer similar insights, based on other data. A professor at the University of Massachusetts, Amherst, noted that in Florida the vote to raise the minimum wage was approved by 72%, although Kerry got 48%. “The correlation between voting for the minimum wage increase and voting for Kerry isn’t likely to be perfect,” he noted, “but one would normally expect that the gap – of 1.5 million votes – to be far smaller than it was.”

While all of this may or may not be evidence of vote tampering, it again brings the nation back to the question of why several states using electronic voting machines or scanners programmed by private, for-profit corporations and often connected to modems produced votes inconsistent with exit poll numbers.

Those exit poll results have been a problem for reporters ever since Election Day.

Election night, I’d been doing live election coverage for WDEV, one of the radio stations that carries my syndicated show, and, just after midnight, during the 12:20 a.m. Associated Press Radio News feed, I was startled to hear the reporter detail how Karen Hughes had earlier sat George W. Bush down to inform him that he’d lost the election. The exit polls were clear: Kerry was winning in a landslide. “Bush took the news stoically,” noted the AP report.

But then the computers reported something different. In several pivotal states.

Conservatives see a conspiracy here: They think the exit polls were rigged.

Dick Morris, the infamous political consultant to the first Clinton campaign who became a Republican consultant and Fox News regular, wrote an article for The Hill, the publication read by every political junkie in Washington, DC, in which he made a couple of brilliant points.

“Exit Polls are almost never wrong,” Morris wrote. “They eliminate the two major potential fallacies in survey research by correctly separating actual voters from those who pretend they will cast ballots but never do and by substituting actual observation for guesswork in judging the relative turnout of different parts of the state.”

He added: “So, according to ABC-TVs exit polls, for example, Kerry was slated to carry Florida, Ohio, New Mexico, Colorado, Nevada, and Iowa, all of which Bush carried. The only swing state the network had going to Bush was West Virginia, which the president won by 10 points.”

Yet a few hours after the exit polls were showing a clear Kerry sweep, as the computerized vote numbers began to come in from the various states the election was called for Bush.

How could this happen?

On the CNBC TV show “Topic A With Tina Brown,” several months ago, Howard Dean had filled in for Tina Brown as guest host. His guest was Bev Harris, the Seattle grandmother who started www.blackboxvoting.org from her living room. Bev pointed out that regardless of how votes were tabulated (other than hand counts, only done in odd places like small towns in Vermont), the real “counting” is done by computers. Be they Diebold Opti-Scan machines, which read paper ballots filled in by pencil or ink in the voter’s hand, or the scanners that read punch cards, or the machines that simply record a touch of the screen, in all cases the final tally is sent to a “central tabulator” machine.

That central tabulator computer is a Windows-based PC.

“In a voting system,” Harris explained to Dean on national television, “you have all the different voting machines at all the different polling places, sometimes, as in a county like mine, there’s a thousand polling places in a single county. All those machines feed into the one machine so it can add up all the votes. So, of course, if you were going to do something you shouldn’t to a voting machine, would it be more convenient to do it to each of the 4000 machines, or just come in here and deal with all of them at once?”

Dean nodded in rhetorical agreement, and Harris continued. “What surprises people is that the central tabulator is just a PC, like what you and I use. It’s just a regular computer.”

“So,” Dean said, “anybody who can hack into a PC can hack into a central tabulator?”

Harris nodded affirmation, and pointed out how Diebold uses a program called GEMS, which fills the screen of the PC and effectively turns it into the central tabulator system. “This is the official program that the County Supervisor sees,” she said, pointing to a PC that was sitting between them loaded with Diebold’s software.

Bev then had Dean open the GEMS program to see the results of a test election. They went to the screen titled “Election Summary Report” and waited a moment while the PC “adds up all the votes from all the various precincts,” and then saw that in this faux election Howard Dean had 1000 votes, Lex Luthor had 500, and Tiger Woods had none. Dean was winning.

“Of course, you can’t tamper with this software,” Harris noted. Diebold wrote a pretty good program.

But, it’s running on a Windows PC.

So Harris had Dean close the Diebold GEMS software, go back to the normal Windows PC desktop, click on the “My Computer” icon, choose “Local Disk C:,” open the folder titled GEMS, and open the sub-folder “LocalDB” which, Harris noted, “stands for local database, that’s where they keep the votes.” Harris then had Dean double-click on a file in that folder titled “Central Tabulator Votes,” which caused the PC to open the vote count in a database program like Excel.

In the “Sum of the Candidates” row of numbers, she found that in one precinct Dean had received 800 votes and Lex Luthor had gotten 400.

“Let’s just flip those,” Harris said, as Dean cut and pasted the numbers from one cell into the other. “And,” she added magnanimously, “let’s give 100 votes to Tiger.”

They closed the database, went back into the official GEMS software “the legitimate way, you’re the county supervisor and you’re checking on the progress of your election.”

As the screen displayed the official voter tabulation, Harris said, “And you can see now that Howard Dean has only 500 votes, Lex Luthor has 900, and Tiger Woods has 100.” Dean, the winner, was now the loser.

Harris sat up a bit straighter, smiled, and said, “We just edited an election, and it took us 90 seconds.”

On live national television. (You can see the clip on www.votergate.tv.) And they had left no tracks whatsoever, Harris said, noting that it would be nearly impossible for the election software – or a County election official – to know that the vote database had been altered.

Which brings us back to Morris and those pesky exit polls that had Karen Hughes telling George W. Bush that he’d lost the election in a landslide.

Morris’s conspiracy theory is that the exit polls “were sabotage” to cause people in the western states to not bother voting for Bush, since the networks would call the election based on the exit polls for Kerry. But the networks didn’t do that, and had never intended to.

According to congressional candidate Fisher, it makes far more sense that the exit polls were right – they weren’t done on Diebold PCs – and that the vote itself was hacked.

And not only for the presidential candidate – Jeff Fisher thinks this hit him and pretty much every other Democratic candidate for national office in the most-hacked swing states.

So far, the only national “mainstream” media to come close to this story was Keith Olbermann on his show Friday night, November 5th, when he noted that it was curious that all the voting machine irregularities so far uncovered seem to favor Bush. In the meantime, the Washington Post and other media are now going through single-bullet-theory-like contortions to explain how the exit polls had failed.

But I agree with Fox’s Dick Morris on this one, at least in large part. Wrapping up his story for The Hill, Morris wrote in his final paragraph, “This was no mere mistake. Exit polls cannot be as wrong across the board as they were on election night. I suspect foul play.”

Two Americas.

Via MeFi.

fascinating map-fu:

The results show an interesting effect. There is a large “bump” of counties centered a little above 50%, where people voted roughly half-and-half for the two candidates, although with a slight bias in favor of the Republican candidate. And then there is a big “spike” on the left of the plot, representing counties where, to an excellent approximation, no one voted Republican. It appears that there are, as the pundits have been telling us, “two Americas,” but they are not the ones people usually talk about. They are “divided America,” where people split roughly evenly between Republican and Democrat, and “decided America,” where everyone is a Democrat. The Democrats of “decided America” number about 5.9 million, or 11% of all Democratic voters. These people are unlikely ever even to encounter a Republican voter in their home town.

If one were to summarize simply, it appears that the election’s winner won by a slim majority of people in counties that — as counties — were rather ambivalent about their decision. He was opposed by a nearly (but not quite) equal number of people a considerable fraction of whom live in counties that were very certain of their support for his opponent.

Something to think about before you write off the “red states” — they were full of Kerry voters, just not enough of them.
(At least, if the election results are correct.)

The Power of the Protest Film

OK, so protest films weren’t able to prevent America from “re” electing a lying, torturing, murderous dynastic warlord to be the president of the nation.

But they were able to successfully change the world in one important way — I am no longer able to order a 42 oz. Diet Coke from McDonald’s.

We’ll still have a President with the blood of thousands of soldiers and a hundred thousand civilians on his hands, but hey, at least I won’t be drinking too much Diet Coke without having to go back for a refill.

Thanks, protest films.