Tuesday, June 28, 2011

Utha Graduates

About a month ago RuthAnne was awarded her Associate of Arts from Harvard Extension School; I've finally tracked down my SD flash card reader so I can upload the pictures. I expect complaints about this from RuthAnne...

Owen testing out the cap




See, they can smile!
The cap on its rightful dome
The Goods
So - tell me how...
...you really feel.





A final update: the "official" picture.

From RuthAnne 2011-06-29

Saturday, June 25, 2011

Henna, again

Last weekend RuthAnne re-dyed my hair with henna. I've been using henna from hennaforhair.com, which is quite expensive; this time I use henna from a local store in Central Square.


It was $3.00 for a 5 and a half ounce bag (of which I used about half a bag, with a lot of what I mixed left over). It's excellent henna; there was a very strong dye release, and I like the resulting color.

So much for the high-priced spread. But The Henna Page (same people as hennaforhair.com) is still a great information source for henna, both for use as a hair dye and for mehandi.

...and the sins of the father shall be visited upon the sons to the third and fourth generation...

Jose Antonio Vargas is a former reporter for The Washington Post and shared a Pulitzer Prize for coverage of the Virginia Tech shootings. He was sent by his family to the US. from the Philippines when he was 12. Four years later, he discovered that he is an illegal immigrant.

some of Vargas' papers, from the New York Times Sunday Magazine

Vargas went to college and, as noted earlier, became a successful journalist. He has a Social Security number (obtained illegally) and pays state and federal income tax. He did not choose to enter the U.S. illegally. But here he is. What should we do about it?

He has decided he can no longer live this lie and tells his story in this week's New York Times Sunday Magazine (and also at defineamerican.com). If we can't provide a legal, reasonable path to citizenship for someone like Vargas, then what are we?

Update: Vargas is not alone.Recently the government agreed to an unusual deal in the case of an Iraq veteran who was brought to the U.S illegally as a baby. According to the New York Times, the government offered to drop a passport violation charge against the Navy petty officer if he completed a term of probation.

Friday, June 24, 2011

Rant, rant, rant

I can't stand it. I have to vent.

Yesterday the Republicans walked out of negotiations on raising the federal debt limit - because they absolutely refuse to consider any tax increases - not even simply revoking the Bush tax cuts on households earning over $250,000/year.

This is absurd.

I can't bring myself to provide calm, reasoned argument about this. These guys are nuts! The plutocracy owns Washington, and the rest of us are doomed.

Thursday, May 5, 2011

Then and Now

Today is the 50th anniversary of Alan Shepard's 15 minute suborbital Mercury flight, which initiated the U.S. manned space program. According to the NASA press kit for the MR-3 launch, the combined height of the launch vehicle and spacecraft was 83 feet, with a liftoff weight of about 66,000 pounds.




Compare this to the lift-off of the space shuttle Atlantis on the nearly 12 day STS-132 mission. The NASA press kit for STS-132 lists combined weight of the shuttle system at launch as 4,519,769 pounds, with a height of 184 feet.



Mercury Redstone 3 and Atlantis are perhaps the bookends for the NASA manned spaced program; the last flight of Atlantis (STS-135) may well be the last time U.S. astronauts fly aboard spacecraft designed and built by NASA.

Tuesday, April 26, 2011

Alive Enough

On Being has once again come through with a fascinating interview, this one with Sherry Turkle, an MIT professor and current director of the MIT Initiative on Technology and Self. I haven't listened to the produced version of the interview, just the unedited version; after discovering these raw interviews with the Scott Atran episode, I often don't bother with the produced version at all.

I found the show interesting enough that I inflicted a portion of it (from 26:53 to 37:00) on my kids as we ate dinner together a few nights ago (thereby allowing technology to invade the sanctity of the dinner table...) so we could discuss it. There was a description of someone walking the dunes on Cape Code listening to an iPod and texting, a discussion of a child texting in the car (and therefor not engaging with the parent), and a family where the father texted through fantastic family dinners prepared by his gourmet chef spouse, ignoring his family. The segment included a couple of wonderful quotes:

  • An uncredited psychology bromide: "If you don't teach your children to be alone, they'll only always know how to be lonely."
  • From Jill Ker Conway, former president of Smith College: "A child has to live in her generation."
In the ensuing discussion, my kids really took issue with the notion that simply having a soundtrack going in their earbuds inherently cuts them off from their surroundings. Several years ago the kids took a summer-long road trip out west together; they would often stop and walk through the stunning scenery with the iPod going and each with an earbud, so they were sharing the scenery to the same music. They did feel that the dinnertime texting was pretty terrible, and in-the-car texting had to be judged on the basis of the situation. I can't say that we agreed on all points, but their positions were at least comprehensible to me. As noted: they have to live in their generation, and since they've grown up with technology in a way that even their geeky dad did not, we're bound to have differing outlooks. We did get a good solid hour of discussion out of the segment.

Later on in the interview, Turkle worries about the replacement of physical artifacts - books, printed photographs, paper letters - with intangible, potentially ephemeral and less readily accessed digital artifacts. I worry about this, too, and I have a background project cooking away to produce printed picture books from some of my vast digital photo collection.

At the same time, I'm embracing digital media as an alternative approach to preserving my memories. This blog is a case in point. As I noted two years ago, "I want touchstones to help me recall who I am." This blog has become, at least in part, the journal I never seemed to be able to keep on paper. I'm sure not writing for my vast audience; according to Google Analytics, I've had not a single hit in the past month.

I've downloaded samples of some of Turkle's books to my Kindle; if anything really grabs me, I'll update this entry.

Thursday, April 21, 2011

Getting the Subversion server version

I recently needed to know what version of Subversion we are running, and this turned out to be harder to determine than I would have guessed.

Getting the version of the client is easy:

bash-4.1$ svn --version
svn, version 1.6.15 (r1038135)
compiled Nov 29 2010, 14:09:28
[... other stuff ...]
bash-4.1$


But the client doesn't provide an option for getting the server version. Using The Google, I found a Python script at Apache that does the trick:


bash-4.1$ python server-version.py https://svnserver/repos/root_of_repository
1.6.11
bash-4.1$


Here's a copy of that script (as of 7/9/2013) in case the link dies:

#!/usr/bin/env python
#
#
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements.  See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership.  The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not use this file except in compliance
# with the License.  You may obtain a copy of the License at
#
#   http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing,
# software distributed under the License is distributed on an
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
# KIND, either express or implied.  See the License for the
# specific language governing permissions and limitations
# under the License.
#
#
#
# server-version.py: print a Subversion server's version number
#
# USAGE: server-version.py URL
#
# The URL can contain any path on the server, as we are simply looking
# for Apache's response to OPTIONS, and its Server: header.
#
# EXAMPLE:
#
#   $ ./server-version.py http://svn.collab.net/
#                   or
#   $ ./server-version.py https://svn.collab.net/
#

import sys
try:
  # Python >=3.0
  from http.client import HTTPConnection as http_client_HTTPConnection
  from http.client import HTTPSConnection as http_client_HTTPSConnection
  from urllib.parse import urlparse as urllib_parse_urlparse
except ImportError:
  # Python <3.0
  from httplib import HTTPConnection as http_client_HTTPConnection
  from httplib import HTTPSConnection as http_client_HTTPSConnection
  from urlparse import urlparse as urllib_parse_urlparse


def print_version(url):
  scheme, netloc, path, params, query, fragment = urllib_parse_urlparse(url)
  if scheme == 'http':
    conn = http_client_HTTPConnection(netloc)
  elif scheme == 'https':
    conn = http_client_HTTPSConnection(netloc)
  else:
    print('ERROR: this script only supports "http" and "https" URLs')
    sys.exit(1)
  conn.putrequest('OPTIONS', path)
  conn.putheader('Host', netloc)
  conn.endheaders()
  resp = conn.getresponse()
  status, msg, server = (resp.status, resp.msg, resp.getheader('Server'))
  conn.close()

  # 1) Handle "OK" (200)
  # 2) Handle redirect requests (302), if requested resource
  #    resides temporarily under a different URL
  # 3) Handle authorization (401), if server requests for authorization
  #    ignore it, since we are interested in server version only
  if status != 200 and status != 302 and status != 401:
    print('ERROR: bad status response: %s %s' % (status, msg))
    sys.exit(1)
  if not server:
    # a missing Server: header. Bad, bad server! Go sit in the corner!
    print('WARNING: missing header')
  else:
    for part in server.split(' '):
      if part[:4] == 'SVN/':
        print(part[4:])
        break
    else:
      # the server might be configured to hide this information, or it
      # might not have mod_dav_svn loaded into it.
      print('NOTICE: version unknown')


if __name__ == '__main__':
  if len(sys.argv) != 2:
    print('USAGE: %s URL' % sys.argv[0])
    sys.exit(1)
  print_version(sys.argv[1])

Saturday, March 19, 2011

Gmail account hijacking

I've just spent the morning helping a friend recover from having her Gmail account hijacked. I still haven't discovered a root cause, but the initial symptom was when I received this email from her:

My apologies for any troubles this might cause you. This is quite strange and funny.Actually I came down here to England in the UK for a brief Trip and unfortunately I was mugged at the park on my way to the hotel where I lodged, with all my cash, credit card and cell phone stolen from me but luckily for me I still have my passports.

I've been to the embassy and the Police here haven't been quite helpful enough. My flight leaves shortly from now but I'm having problems paying the hotel bills and the hotel manager here won't let me leave until I pay up the bills. I was hoping if you could loan me some quick cash that I can pay back as soon as I get back.I really need your help from here on out.



Since I knew my friend wasn't in England, there was clearly a problem. Looking at the mail headers, I noticed that the  reply-to address was friendsID@ymail.com. Clearly a phishing attempt. 


Shortly thereafter I was contacted by said friend for help regaining access to her gmail account.


This turned out to be a bit tricky. The first think I needed was an email account to be used for recovery purposes. Setting one up at gmail is possible, but non-obvious, since the normal account creation links at gmail all require an existing email address. Eventually I discovered this link to create a gmail account without an existing email account.


Once this was set up, we could then work through the gmail procedure for regaining access to your account if you think its been compromised. 


A crucial piece of this involved email forwarding - something it would not have occurred to me to check if it hadn't been on Google's list of issues. Gmail allows you to forward mail to other addresses; my friend's account had been configured to forward mail to a yahoo account and had POP access enabled. As soon as she regained access to the account we immediately disabled both.


The account was also configured with a reply-to address of friendsID@ymail.com. Pretty sneaky.


Unfortunately, it appears that her inbox is GONE; I don't know if gmail has any sort of recovery option. Luckily her contacts survived, but this highlights the value of periodically exporting your contact information out of gmail.


Update: I notified Yahoo (via their abuse reporting page) that an account is being used to conduct fraud. I got back a canned response, and it was obvious that my detailed description hadn't been read. Thanks, Yahoo.

Sunday, February 20, 2011

How People Work

I just finished listening to the February 10th broadcast of Speaking of Faith Krista Tippett on Being, an interview with anthropologist Scott Atran. It's a phenomenal show! Here's the blurb:

We make deeper sense of the human dynamics unfolding in the Middle East and North Africa. Anthropologist Scott Atran offers bracing context on the promise of this moment and the response it asks from the watching world.



Atran's understanding of the Middle East, and human nature in general, is just astounding. I urge you to give it a listen. It's worth listening to the unedited version of the show; there's a lot of very interesting background on how Atran became an anthropologist that didn't make it into the edited, broadcast version.

Saturday, February 19, 2011

Chapters from a Broken Novel

Last night RuthAnne and I went to see Doug Varone and Dancers at the nifty performance space at the Institute of Contemporary Art. The performance of Chapters from a Broken Novel was so moving that I asked Katy to go see it with me tonight, so I got to experience it twice. What a show!

Excerpts from the show, with commentary, such as this one, are available on the company's web site. Enjoy!


The Evolution of "Tile Riot" from Doug Varone on Vimeo.

Stop the self-check-out madness!

This morning I walked into my local CVS to buy tissues. As I approached the check-out area, my heart sank; there was one register open (with 4 people already in line), and a nice young woman was directing customers to use the shiny new self-service check-out machines instead.

An older woman in front of me was convinced to try the machines, and then got more and more frustrated as the machine clearly had trouble dealing with her cash purchase. She eventually asked the attendant, "Isn't there something you can do about this?" When the response came -- "No, I'm sorry, ma'am, there isn't." -- I loudly observed, "Yes there is. You can hire more cashiers."

It was like lancing a boil -- the whole check-out area erupted in cheers! I continued, stating that these machines take away entry-level jobs and essentially outsource the company's labor costs to its customers. The people around me were nodding and muttering support, and eventually the store supervisor opened another register, to another round of cheers.

Note to retailers making customers take over cashier positions: We don't like it!


If you don't like it, take action:

  • Refuse to use self-service check-out machines.
  • If you have to wait in line because there aren't enough cashiers, complain! Doing it loudly, in the store as I did, is good (because it lets other people vent along with you), but you should also complain to the highest management person on-site (typically a shift supervisor) and lodge a complaint at the company's web site. Be specific: be prepared to provide the time of day, a rough idea of line length (a number, not just "long"), and the store location.
Here are links to customer feedback pages for some of the stores aggressively pushing self-checkout:
  • Shaws
  • CVS - This astonished me, but CVS doesn't seem to have any sort of web-based feedback page. You have to call or write a letter:

    CVS Corporation
    One CVS Drive
    Woonsocket, RI 02895
    1-800-746-7287
  • Publix
  • Kroger
I'm not the only person unhappy about this:

Wednesday, February 16, 2011

Another time waster from Microsoft

I'm trying to get a new laptop at work up and running, using Windows 7 (gulp). After the initial system install, Windows Update downloaded over 60 updates; I told it to go ahead and install them. Everything seemed to be cooking along fine; the updates installed, the system rebooted - and then I got a screen saying "Step 3 of 3 - Preparing To Configure Windows. Please Do Not Turn Off Your Computer". And waited. And waited.

Over an hour later, with no evident disk activity or anything else, I decided something was actually wrong, and started Googling. I found this thread at Microsoft with many users complaining of the same thing. Microsoft never provided a useful response.

Luckily, though, some valiant soul tried Ye Olde three finger salute - Ctrl-Alt-Del - and, voile! The system put up a login prompt and everything was fine. This worked for me,too.

Wake up, Microsoft! Things like this really upset people! Would it be so hard to at least put a sticky comment at the top of the forum providing the workaround, so we don't have to wade through thousands of lines of rants to get to the solution?

Saturday, January 8, 2011

Is this the best the New York Times can do?

The lead in this week's Sunday New York Times travel section is The 41 Places to Go in 2011, and my beloved Hyderabad made the list (number 19). Sadly, the meager two paragraphs (about 200 words) by travel writer Gisela Williams focus only on modern and commercial interests, and say almost nothing about the real reasons to visit Hyderabad. It's next to impossible to excerpt passages from such a short piece, so I'll risk the wrath of the copyright gods and include it verbatim:

Even in the 16th century, Hyderabad, in southern India, famous for its diamond trade and sultans’ palaces, was a city with serious bling. In the last decade, a new sort of wealth has arrived — the outsourcing of international companies, which has inspired a boom of sleek cafes and restaurants such as Fusion 9.

The latest buzz is the debut of two five-star hotels, both connected to the Nizam family, rulers of Hyderabad for the two centuries before India’s independence. The first, Park Hyderabad, is a futuristic structure designed by Skidmore, Owings & Merrill, with an aluminum and glass facade inspired by the settings and metalwork found in the Nizams’ jewelry collection. The new Taj Falaknuma Palace, on the other hand, is a window into the past. It’s a wedding cake of a building that still belongs to the Nizam family, and it took the Taj Hotels group 10 years to renovate the European-style castle. “The Falaknuma Palace will complete the Indian palace tour for the south,” said Shanti Kohli, of New Delhi-based Amber Tours. “It makes a trip to Hyderabad worthwhile just on its own.”

Diamond trade, not pearls? Nothing about Golkonda, the Qutb Shahi and Paigah tombs, Charminar, Mecca Masjid, Birla Mandir, or the Salar Jung Museum? A little more research might be in order - such as reading this 1990 article from, er, the New York times travel section.

Here, let me take a stab at this:

Nowhere are India's contrasts more vivid than in the southern city of Hyderabad, where high-tech modernity meets a thousand years of history. Brightly painted Hindu temples share its narrow streets with the minarets of Muslim mosques, the arches and domes of Sikh gurudwaras and the more recent spires of Christian churches. From the marble decks of the beautiful Birla Mandir temple you can see a 55 foot statue of Buddha on an island in Hussain Sagar, Hyderabad's central lake.

Just a few miles from the gleaming new towers of India's software outsourcing giants you'll find the 16th century walls of Golkonda Fort and the Qutb Shahi tombs. Visit the old city center at Charminar (literally "four towers") and shop in the ever-busy Laad Bazaar. Splurge and stay in the newly renovated Falaknuma Palace, build by one of the last ruling Nizams and now a magnificent Taj hotel. Ramoji Film City, a sprawling 2000 acre studio complex and home to India's Telegu-language film industry (aka "Tollywood") lies nearby. Excellent restaurants abound, from the eclectic fare of Ohri's in Banjara Hills to the homey vegetarian delights of Chutneys at Nagarjuna Circle. What you won't find is a lot of western tourists; Hyderabad is one of India's best-kept secrets.

But, since this is a blog, I can do even better and provide some pictures and links.

Golkonda Fort, the Qutb Shahi tombs







Charminar, Mecca Masjid, the bangle merchants of Laad Bazaar









The Buddha Statue, Temples and Idols









Chutneys

Tuesday, December 28, 2010

Untangled

Katy and I decided to go out and see a movie this evening, and settled on the 7PM showing of Tangled at Fresh Pond Entertainment Cinemas. This movie theater is never my first choice; the theaters are small, the sound insulation between them is poor, and they're expensive. Usually I try to go to one of these:

But Fresh Pond was the closest place we could find with Tangled, so off we went - only to return home without seeing the movie. The sound level was extremely low (as opposed to the usual ear-splitting over volume...) and the image jittery. As soon as the previews started and the problem became apparent I went out the lobby and notified a theater employee; nothing happened. Eventually the actual movies started, and we walked out.

The manager was very polite, and refunded our money without any hassle, but it just seemed so pathetic. Evidently there is so much automation that the one "projectionist" they have was unable to actually do any troubleshooting.

The price of two adult tickets is $18.50; that's about the price of most Blu-Ray movies on Amazon (plain old DVDs are even cheaper). With this kind of experience, how long do the movie theaters think they can stay in business?

Wednesday, December 22, 2010

Now it can be told...

Today we released expressor Studio 3.0. We've worked really hard over the past year for this moment.

(This is from a more recent release...)


We also had a great Yankee swap and Chinese take-out lunch. I got a cool Lava Lamp out of the deal!

Monday, December 20, 2010

Lord of the Dance

I'm a member of of the Pinewoods Morris Men; we dance every year in the Christmas Revels at Sanders Theatre in Cambridge. The traditional ending of the first act is always a performance of the Lord of the Dance, which ends with the Morris dancers leading the audience into the lobby for intermission. Here's a video clip of my teammates Steve and Joe (along with cast member David Coffin) at a recent Revels (not this year):




Well, last night Owen and I had the privilege of performing the dance together, one of the few father/son pairs to do so.

Merry Christmas!

Wednesday, December 8, 2010

More about Torrent

I found a brochure from 1997. 


Pretty cool/scary looking, eh?

Wednesday, November 24, 2010

symbolic links on Windows

Windows "shortcuts" are not the same thing as Unix symbolic links. In fact, Windows (at least, pre-Vista Windows) doesn't have symbolic links. Bummer.

BUT - it turns out that Windows 2000 and later do have a feature called junction points.These can be used to produce the moral equivalent of a symbolic link for directories only, not individual files. Since I mostly use directory symlinks anyway, this is useful for me. Thank you, Mike Nordell, for your little makelink command line tool!

Monday, November 22, 2010

Hey - it worked!

Nearly 16 years ago, I got call more-or-less out of the blue from a fellow named Rob Utzschneider, who wanted to interview me for a parallel processing start-up named Applied Parallel Technologies. Rob and his co-founder, Ed Zyszkowski, had just received funding under the Advanced Technology Program, a program run by NIST, an agency of the U.S. Commerce Department. The intent of ATP was, "...to spur the development of path-breaking new technologies by providing cost-shared funding for potentially valuable but high-risk R&D projects." Over a two year period, ATP put about $1.1million into Applied Parallel Technologies (APT - confusingly similar to ATP...), which paid our salaries, bought us workstations, gave us an Internet connection and who knows what else.


Over time, APT morphed into Torrent Systems, acquired VC funding, and was eventually acquired by Ascential Software and, ultimately, IBM. The system we developed - Orchestrate - is still at the heart of IBM's Information Server software. Given its continued survival, we must have done something right.

Evidently NIST thought so, too. I just stumbled over an ATP report describing the performance of the first 50 completed ATP projects. Our work earned 4 stars - the highest possible rating - and was among the 8 top-ranked projects. The project summary brought back a lot of memories.

So - I guess that, at least in our case, a government program actually did just what it was supposed to do. The ATP grant got Torrent off the ground, and we were successful enough that venture capital followed. We built a working system that helped bring parallel processing into the mainstream. The MapReduce software used by Google is a variation on the flow-based, data parallel concepts embodied in Orchestrate.

Cool.

Saturday, November 20, 2010

Doesn't anyone care?

This morning I was out in the lawn raking leaves at about 10:30 when I spotted delivery truck preparing to turn the wrong way up our one-way street (from Miller to Orchard). I yelled to him that it was a one way street, but he kept coming - and in the process tore down the phone lines that cross the street at that corner. He stopped the truck, and I yelled to him that he had taken down wires, but he ignored me, backed his truck down Orchard, paused, and then turned down Blake and left.

I went inside, discovered that among the lines he took out were our phone lines, and called the Cambridge police to report the incident. The Cambridge Fire Department promptly sent a truck out to inspect the downed lines and get them off the street.

I then called Verizon to report the downed lines, a real exercise in frustration. They force you to listen to ads for FIOS before giving you a chance to enter any options, and you're then forced through a voice response system that never offers you a chance to talk to a human. I tried contacting them on the web; that was just as fruitless. I wonder if Verizon has any clue how infuriating their customer support is.

Finally, I called back the Cambridge police department to see if they wanted any of the information I had, so they could follow up with the driver and/or trucking company. There was no interest at all.

SO - since it seems there will be no official action, I can at least publish what I have. First, the raw information:

  • License plate: MA 248 0924
  • DOT 949278
  • MC 640842
  • The truck was labeled DB Schenker and QTX, Salem, NH, and was a white box truck.
The U.S. Department of Transportation provides a lookup page for DOT/MC numbers, which provided these details on the trucking company:

Legal NameQUATIERI TRUCKING INC
DBA NameQTX TRANSPORTATION
Physical and
Mailing Address
ONE LISETTE DR
SALEM, NH 03079
Phone(617) 201-0897
USDOT Number949278
MC NumberMC-640842

I got a good look at the driver, since he got out of the truck before driving off and asked me, "Is there a problem here?" in a threatening tone. He's a bit shorter than me (maybe 5'6"), mid 20's to mid 30's, black mustache, a little heavy. This was one time I regret not having a cell phone camera.

I'm still trying to figure out who, if anyone, I can report this incident to. It doesn't seem right that a guy can deliberately turn the wrong way on a one-way street, tear down phone lines, and just drive off.

Update: I filed a complaint (ID 100045255) with the Federal Motor Carrier Safety Admnistration.

Update, early January 2011: I got a response from the DOT, stating that they have opened an investigation.


Update, March 2011: I got another letter from the DOT; they are preparing an "enforcement action." Who knows what that means, but it should at least get the attention of the trucking company. Sometimes the system does work!

Thursday, November 11, 2010

C++ exceptions and dynamic loading

[Note: non-geeks can click away right now...]

I just spent a chunk of my afternoon trying to figure out why my C++ exception handlers were not being invoked on Linux, using g++. I could see the exception being thrown in the debugger, but the catch block that caught the exception was the "catch(...)" block, rather than my type-specific block.

It looks like it's a problem with the g++ exception mechanism. What appears to be happening is that the selection of the catch block uses the addresses of type_info blocks, rather than string comparisons on the exception names (which, I've been led to believe, is what Visual Studio C++ does - where my code works fine). If you are using a dynamically loaded module, and there are multiple copies of the RTTI information (easy to do if you are statically linking some libraries, which I am...), and you throw across the loaded module boundary, SPLAT!

This mailing list thread helped me figure this out. I learned a few other useful factoids in the process:

  • gdb's catch command makes it easy to break on exceptions being thrown and caught:
    • catch throw
    • catch catch
  • It's possible to dig around in the g++ runtime system within the body of a catch(...) block and get to the type_info for the exception, which will give you a (platform-dependent) type name - handy for a debug message.
Thank you, web denizens...

Tuesday, November 9, 2010

Algorithm 199

I'm blogging this just so I don't lose this useful reference to CACM Algorithm 199, a magic set of routines for converting between Gregorian (calendar) and Julian dates. Someday I'd love to read the original article and find out where all the magic numbers come from.

Sunday, October 17, 2010

Decisions, Decisions

On Tuesday, November 2 (about 2 weeks away as I write), Massachusetts voters will deciding the fate of three statewide initiatives. Questions 1 and 3 would roll back various state taxes, and are no-brainers as far as I'm concerned; we simply can't afford to cut the sales tax right now (Question 3), and I fail to see why alcoholic beverages deserve an exemption from the sales tax (Question 1). Question 2, though, is less straightforward; it's a bid to overturn the so-called "anti-snob zoning statute", Chapter 40B. The statute basically enables developers to override local zoning and environmental protection laws in return for making 20% of the units in the project "affordable".

The definition of "affordable" means, roughly, "can be afforded by someone earning 70% of the median town income." Hence, the level varies from town to town. The units are not affordable in perpetuity; rather, they revert to market rate units once the initial unit financing is paid off.

I've read the arguments for and against the initiative, and I'm pretty sure now that I'll be voting yes (to overturn 40B). The statute seems to be a very blunt instrument for creating affordable housing, and it's not at all clear to me that it really works.

While doing my research on this topic, I had a hard time finding out which communities are subject to 40B (towns with less than 10% affordable housing). I finally found the Subsidized Housing Inventory, but it's a PDF, which makes it difficult to pull into a spreadsheet and sort. Well, I ground my way through the exercise (thank you, emacs!), and here's the information in a more digestible form. Have fun!

Chapter 40B Subsidized Housing Inventory (SHI)
Department of Housing and Community Development
as of September 28, 2010*

Community|2000 Census Year Round Housing Units|Total Development Units|SHI Units|% 
Abington|5,332|504|471|8.8
Acton|7,645|897|519|6.8
Acushnet|3,879|127|97|2.5
Adams|4,352|324|324|7.4
Agawam|11,588|504|472|4.1
Alford|173|0|0|0.0
Amesbury|6,570|859|495|7.5
Amherst|9,020|1,125|1,023|11.3
Andover|11,513|1,326|1,043|9.1
Aquinnah|155|41|41|26.5
Arlington|19,358|1,307|1,102|5.7
Ashburnham|1,997|147|32|1.6
Ashby|1,000|0|0|0.0
Ashfield|770|2|2|0.3
Ashland|5,781|348|243|4.2
Athol|4,775|255|255|5.3
Attleboro|16,519|1,198|1,198|7.3
Auburn|6,551|212|212|3.2
Avon|1,737|74|74|4.3
Ayer|3,141|463|293|9.3
Barnstable|20,266|1,858|1,369|6.8
Barre|1,981|82|82|4.1
Becket|739|0|0|0.0
Bedford|4,692|979|857|18.3
Belchertown|5,002|396|370|7.4
Bellingham|5,632|582|532|9.4
Belmont|9,936|328|328|3.3
Berkley|1,870|130|15|0.8
Berlin|891|182|60|6.7
Bernardston|862|24|24|2.8
Beverly|16,150|1,935|1,859|11.5
Billerica|13,055|1,432|1,186|9.1
Blackstone|3,321|165|123|3.7
Blandford|472|2|2|0.4
Bolton|1,472|192|63|4.3
Boston|250,367|50,116|48,503|19.4
Bourne|7,787|1,189|568|7.3
Boxborough|1,900|324|24|1.3
Boxford|2,602|64|23|0.9
Boylston|1,602|26|26|1.6
Braintree|12,924|1,646|1,125|8.7
Brewster|4,379|299|252|5.8
Bridgewater|7,639|222|214|2.8
Brimfield|1,287|89|89|6.9
Brockton|34,794|4,486|4,486|12.9
Brookfield|1,259|46|40|3.2
Brookline|26,224|2,554|2,122|8.1
Buckland|812|5|5|0.6
Burlington|8,395|1,383|981|11.7
Cambridge|44,138|7,207|7,117|16.1
Canton|8,129|965|860|10.6
Carlisle|1,647|26|20|1.2
Carver|4,063|126|126|3.1
Charlemont|576|6|6|1.0
Charlton|3,868|52|52|1.3
Chatham|3,596|174|174|4.8
Chelmsford|12,981|1,293|966|7.4
Chelsea|12,317|2,192|2,187|17.8
Cheshire|1,458|0|0|0.0
Chester|528|50|50|9.5
Chesterfield|462|27|27|5.8
Chicopee|24,337|2,598|2,561|10.5
Chilmark|406|3|3|0.7
Clarksburg|683|8|8|1.2
Clinton|5,817|560|560|9.6
Cohasset|2,752|89|89|3.2
Colrain|749|4|4|0.5
Concord|6,095|738|363|6.0
Conway|716|0|0|0.0
Cummington|401|16|16|4.0
Dalton|2,831|160|160|5.7
Danvers|9,712|1,362|999|10.3
Dartmouth|10,839|975|934|8.6
Dedham|8,893|1,142|1,097|12.3
Deerfield|2,045|32|32|1.6
Dennis|8,079|351|337|4.2
Dighton|2,261|408|150|6.6
Douglas|2,510|183|140|5.6
Dover|1,874|69|18|1.0
Dracut|10,597|928|588|5.5
Dudley|3,877|99|99|2.6
Dunstable|933|30|0|0.0
Duxbury|5,103|224|189|3.7
East Bridgewater|4,423|229|167|3.8
East Brookfield|797|0|0|0.0
East Longmeadow|5,350|499|431|8.1
Eastham|2,642|58|49|1.9
Easthampton|7,058|531|475|6.7
Easton|7,596|351|248|3.3
Edgartown|1,718|84|84|4.9
Egremont|624|0|0|0.0
Erving|625|2|2|0.3
Essex|1,357|40|40|2.9
Everett|15,886|1,304|1,304|8.2
Fairhaven|6,853|495|495|7.2
Fall River|41,757|4,858|4,762|11.4
Falmouth|14,440|1,224|960|6.6
Fitchburg|15,963|1,667|1,666|10.4
Florida|279|0|0|0.0
Foxborough|6,260|595|555|8.9
Framingham|26,588|2,901|2,901|10.9
Franklin|10,296|1,567|1,069|10.4
Freetown|2,991|106|88|2.9
Gardner|8,804|1,243|1,243|14.1
Georgetown|2,601|374|362|13.9
Gill|550|25|25|4.5
Gloucester|12,997|907|899|6.9
Goshen|380|8|8|2.1
Gosnold|49|0|0|0.0
Grafton|5,820|531|318|5.5
Granby|2,288|68|68|3.0
Granville|578|10|10|1.7
Great Barrington|3,116|291|219|7.0
Greenfield|8,274|1,175|1,165|14.1
Groton|3,339|269|197|5.9
Groveland|2,090|132|75|3.6
Hadley|1,943|259|259|13.3
Halifax|2,804|28|28|1.0
Hamilton|2,717|124|84|3.1
Hampden|1,843|60|60|3.3
Hancock|341|0|0|0.0
Hanover|4,440|438|438|9.9
Hanson|3,167|265|143|4.5
Hardwick|1,054|33|33|3.1
Harvard|2,156|237|62|2.9
Harwich|5,862|292|292|5.0
Hatfield|1,420|47|47|3.3
Haverhill|23,675|2,306|2,084|8.8
Hawley|165|0|0|0.0
Heath|416|2|2|0.5
Hingham|7,307|2,283|522|7.1
Hinsdale|775|0|0|0.0
Holbrook|4,145|439|439|10.6
Holden|5,806|541|193|3.3
Holland|947|29|29|3.1
Holliston|4,861|316|200|4.1
Holyoke|16,180|3,570|3,515|21.7
Hopedale|2,284|111|111|4.9
Hopkinton|4,521|299|150|3.3
Hubbardston|1,348|53|53|3.9
Hudson|7,144|904|733|10.3
Hull|4,679|100|100|2.1
Huntington|847|62|62|7.3
Ipswich|5,414|517|445|8.2
Kingston|4,370|347|170|3.9
Lakeville|3,385|701|150|4.4
Lancaster|2,103|192|104|4.9
Lanesborough|1,299|20|20|1.5
Lawrence|25,540|3,807|3,788|14.8
Lee|2,542|173|176|6.9
Leicester|3,790|148|148|3.9
Lenox|2,354|179|179|7.6
Leominster|16,937|1,455|1,418|8.4
Leverett|642|0|0|0.0
Lexington|11,274|1,441|1,326|11.8
Leyden|288|2|2|0.7
Lincoln|2,076|299|227|10.9
Littleton|3,018|396|245|8.1
Longmeadow|5,832|267|267|4.6
Lowell|39,381|5,247|5,212|13.2
Ludlow|7,815|182|182|2.3
Lunenburg|3,605|132|132|3.7
Lynn|34,569|4,424|4,423|12.8
Lynnfield|4,249|626|313|7.4
Malden|23,561|2,706|2,638|11.2
Manchester|2,219|122|110|5.0
Mansfield|8,083|980|934|11.6
Marblehead|8,746|399|332|3.8
Marion|2,095|101|90|4.3
Marlborough|14,846|1,656|1,592|10.7
Marshfield|9,117|743|536|5.9
Mashpee|5,578|240|224|4.0
Mattapoisett|2,634|70|70|2.7
Maynard|4,398|365|365|8.3
Medfield|4,038|203|185|4.6
Medford|22,631|1,666|1,640|7.2
Medway|4,243|279|227|5.3
Melrose|11,200|969|894|8.0
Mendon|1,870|106|49|2.6
Merrimac|2,281|402|146|6.4
Methuen|16,848|1,925|1,636|9.7
Middleborough|7,195|768|413|5.7
Middlefield|229|18|18|7.9
Middleton|2,337|94|94|4.0
Milford|10,682|997|724|6.8
Millbury|5,086|244|221|4.3
Millis|3,060|164|113|3.7
Millville|956|20|20|2.1
Milton|9,142|567|435|4.8
Monroe|66|0|0|0.0
Monson|3,184|169|169|5.3
Montague|3,826|427|395|10.3
Monterey|417|0|0|0.0
Montgomery|254|0|0|0.0
Mount Washington|69|0|0|0.0
Nahant|1,676|48|48|2.9
Nantucket|4,040|180|122|3.0
Natick|13,337|1,620|1,361|10.2
Needham|10,793|850|834|7.7
New Ashford|107|0|0|0.0
New Bedford|41,403|5,195|5,164|12.5
New Braintree|325|0|0|0.0
New Marlborough|630|0|0|0.0
New Salem|399|1|1|0.3
Newbury|2,614|94|94|3.6
Newburyport|7,717|722|629|8.2
Newton|31,857|2,537|2,444|7.7
Norfolk|2,851|144|111|3.9
North Adams|7,061|885|873|12.4
North Andover|9,896|1,193|694|7.0
North Attleborough|10,600|293|293|2.8
North Brookfield|1,889|142|142|7.5
North Reading|4,839|607|536|11.1
Northampton|12,282|1,515|1,452|11.8
Northborough|4,983|711|598|12.0
Northbridge|4,930|393|378|7.7
Northfield|1,194|30|30|2.5
Norton|5,942|723|413|7.0
Norwell|3,299|294|139|4.2
Norwood|11,911|731|719|6.0
Oak Bluffs|1,677|155|146|8.7
Oakham|583|0|0|0.0
Orange|3,236|441|377|11.7
Orleans|3,317|324|294|8.9
Otis|600|0|0|0.0
Oxford|5,209|402|402|7.7
Palmer|5,371|436|378|7.0
Paxton|1,455|12|12|0.8
Peabody|18,838|2,111|1,996|10.6
Pelham|551|3|3|0.5
Pembroke|5,834|778|630|10.8
Pepperell|3,905|137|122|3.1
Peru|334|0|0|0.0
Petersham|453|0|0|0.0
Phillipston|598|6|6|1.0
Pittsfield|21,000|2,076|2,022|9.6
Plainfield|262|15|15|5.7
Plainville|3,088|223|189|6.1
Plymouth|19,008|901|861|4.5
Plympton|865|43|43|5.0
Princeton|1,185|20|20|1.7
Provincetown|2,062|168|127|6.2
Quincy|39,912|4,093|4,093|10.3
Randolph|11,497|1,265|1,265|11.0
Raynham|4,197|602|487|11.6
Reading|8,811|883|684|7.8
Rehoboth|3,588|108|36|1.0
Revere|20,102|2,121|2,121|10.6
Richmond|718|0|0|0.0
Rochester|1,619|8|8|0.5
Rockland|6,632|454|408|6.2
Rockport|3,652|136|136|3.7
Rowe|183|0|0|0.0
Rowley|1,985|118|88|4.4
Royalston|470|3|3|0.6
Russell|634|18|18|2.8
Rutland|2,316|93|93|4.0
Salem|18,103|2,549|2,350|13.0
Salisbury|3,456|514|298|8.6
Sandisfield|351|0|0|0.0
Sandwich|7,574|545|309|4.1
Saugus|10,111|831|742|7.3
Savoy|313|14|14|4.5
Scituate|6,869|359|314|4.6
Seekonk|4,927|86|83|1.7
Sharon|6,006|386|386|6.4
Sheffield|1,422|30|30|2.1
Shelburne|873|51|51|5.8
Sherborn|1,449|41|34|2.3
Shirley|2,140|60|60|2.8
Shrewsbury|12,606|856|856|6.8
Shutesbury|680|2|2|0.3
Somerset|7,124|277|258|3.6
Somerville|32,389|3,226|3,118|9.6
South Hadley|6,757|379|379|5.6
Southampton|2,003|44|44|2.2
Southborough|2,988|441|117|3.9
Southbridge|7,486|496|496|6.6
Southwick|3,488|221|195|5.6
Spencer|4,816|276|240|5.0
Springfield|61,001|10,375|10,098|16.6
Sterling|2,611|270|163|6.2
Stockbridge|1,066|117|117|11.0
Stoneham|9,231|508|502|5.4
Stoughton|10,429|1,746|1,249|12.0
Stow|2,108|301|143|6.8
Sturbridge|3,141|262|211|6.7
Sudbury|5,582|419|280|5.0
Sunderland|1,658|6|6|0.4
Sutton|2,869|127|45|1.6
Swampscott|5,804|217|211|3.6
Swansea|6,032|256|245|4.1
Taunton|22,874|1,883|1,771|7.7
Templeton|2,492|483|205|8.2
Tewksbury|10,125|1,264|666|6.6
Tisbury|1,755|122|110|6.3
Tolland|183|0|0|0.0
Topsfield|2,126|142|124|5.8
Townsend|3,162|166|126|4.0
Truro|999|10|10|1.0
Tyngsborough|3,784|521|194|5.1
Tyringham|146|0|0|0.0
Upton|2,083|223|178|8.5
Uxbridge|4,080|372|245|6.0
Wakefield|9,914|936|602|6.1
Wales|690|61|61|8.8
Walpole|8,202|475|475|5.8
Waltham|23,749|1,773|1,764|7.4
Ware|4,285|446|446|10.4
Wareham|8,650|884|754|8.7
Warren|2,004|112|112|5.6
Warwick|314|0|0|0.0
Washington|210|0|0|0.0
Watertown|14,959|1,161|998|6.7
Wayland|4,703|280|216|4.6
Webster|7,343|733|692|9.4
Wellesley|8,789|514|482|5.5
Wellfleet|1,430|37|37|2.6
Wendell|405|2|2|0.5
Wenham|1,310|169|116|8.9
West Boylston|2,454|288|189|7.7
West Bridgewater|2,507|125|63|2.5
West Brookfield|1,436|62|62|4.3
West Newbury|1,414|82|28|2.0
West Springfield|12,196|442|442|3.6
West Stockbridge|632|0|0|0.0
West Tisbury|1,081|38|23|2.1
Westborough|6,729|721|671|10.0
Westfield|15,362|1,095|1,095|7.1
Westford|6,877|643|347|5.0
Westhampton|557|0|0|0.0
Westminster|2,609|273|86|3.3
Weston|3,796|250|138|3.6
Westport|5,545|458|224|4.0
Westwood|5,218|615|497|9.5
Weymouth|22,471|1,857|1,833|8.2
Whately|647|2|2|0.3
Whitman|5,100|218|218|4.3
Wilbraham|5,021|256|255|5.1
Williamsburg|1,057|76|76|7.2
Williamstown|2,926|147|147|5.0
Wilmington|7,141|939|711|10.0
Winchendon|3,563|345|345|9.7
Winchester|7,860|150|148|1.9
Windsor|378|0|0|0.0
Winthrop|8,009|642|642|8.0
Woburn|15,312|1,305|1,137|7.4
Worcester|70,408|9,603|9,591|13.6
Worthington|522|22|22|4.2
Wrentham|3,477|268|164|4.7
Yarmouth|12,056|514|407|3.4

Totals|2,526,963|271,397|243,630|9.6

Thursday, October 14, 2010

Falling Leaves

It's mid-October and the leaves around Boston are finally turning - a little late this year, it seems to me. Each day my drive into work gives me more glorious, multi-colored trees. I'll need to start the raking this weekend.

With autumn as background, today I received the sad news that Deborah Goessling, the wife of my former colleague and friend Dan Goesssling, died unexpectedly this past Monday night. I didn't know Deb well, but I was close to Dan during my 5 year stint at IBM, and we've stayed in touch.

I only just discovered that Deb has been blogging for the past two years, with the focus of her blog being her lived experience with ALS. Her most recent entry was two weeks ago. I wish I'd known about her blog earlier; it offered a vivid and upbeat window into her life.

Tuesday, August 31, 2010

The New (3rd gen) Kindle

Yesterday I received my new 3rd generation, Wifi-only Kindle in the mail. So far it's been a bit of a mixed bag, relative to my 2-year-old original Kindle.

Good things:

  • it is, of course, smaller and lighter .
  • The contrast is noticeably better, and the quality of images is dramatically better.
  • Page turns are a lot faster.
  • The software offers some nice new features (notably, collections).
  • The wifi connectivity was easy to set up, including multiple networks.
  • The wifi-only version is finally reasonably priced (call it $140).
Bad things:
  • I can't find a way to set the sleep timeout; it seems like it's pretty short, and since I have a password set, that means I have to retype the password too often.
  • The first time I tried to download new (as opposed to previously purchased content from my old Kindle), the items got stuck in a "pending - 0%" state. I called CS, and they had me restart the Kindle (which takes about a minute; it's shockingly slow, for a dedicated device...). That unclogged it, but I won't be happy if I have to do this very often. I got the distinct impression from the CS guy that "pending first downloads" is a common problem.
  • To my surprise, I don't like the "arrow quad" for navigation as well as I did the old "roller strip". The roller was very fast, and since it used a display other than the main display (with a different technology), it was very responsive. Feedback from the new arrow quad is on the main (e-ink) display, which means it can't be very fast; and it feels glitchy; the quad is small enough that I find myself pressing the center "select" button inadvertently.
  • Related to the quad vs. roller - the dictionary lookup is different, too. On the old Kindle, you scrolled to the line containing the word to be looked up, depressed the roller, and selected "lookup" on the menu that appeared. All the words on that line were searched for. On the new Kindle, you actually have to select a specific word, which requires more careful navigation with the arrow quad.
It may be that some of the negatives (like the use of the quad) go away as I become more adept with the device - but it distinctly feels like a more complicated gadget. I fear that Amazon has fallen prey to feeping creaturism. The real beauty of the first generation device was that it was dead-up simple to use as a book. This new Kindle has more features, but may not be as good a book reader - and if it tries to go head-to-head with the iPad, it's sure to lose.

The main reason I got a new Kindle was for sharing; I've been really annoyed that, unlike a book, I've had no way to lend out books on the Kindle to friends. Now that I have a second gadget, I can loan out the old one. 

Given that up to six Kindles can share an account, I can imagine a group of friends, or even a book group, getting together to share books. I bet Amazon - and the publishing cabal - would hate that.

Sunday, August 1, 2010

Looking at Wheels

Yesterday I looked at wheels of various sorts. Last weekend RuthAnne and I took the Basic Rider Course from Training Wheels in Plympton and passed the exam to get our motorcycle licenses. I've wanted to know how to ride - and be able to do so legally - since my long trip to India in 2007, when it became clear that a 2-wheeler would have been the ideal way for me to get around. More recently, my daily commute to Burlington by bus has been getting me down; it takes an extra hour out of my day to go by bus than by car, yet I don't want to do all that driving, so I've been thinking a high-MPG 2-wheeler would be a good choice.

So - I stopped first at Boston Motor Sports in Arlington and looked at scooters. They carry scooters from (among others) Kymco and Suzuki. I was especially interested in the new Kymco Downtown 300i, but it's unfortunately not going to be available until the fall. It looks like a sweet vehicle; 60MPG, top speed of about 80MPH, large wheels (for a scooter), lightweight, FUN. While there, I looked at the Kymco People S 250, a similar scooter; it looked pretty good. I also checked out a used 2008 Aprilia 250 with 3000 miles, for $3200, including rear box.

I unfortunately couldn't ride anything; Boston Motor Sports (not unreasonably) requires a full license for test drives, not just a permit, and I'm still waiting for mine to come in the mail. After leering at metal for a while, I wandered upstairs to their gear department and checked out, helmets, gloves, jackets and such. One of the sales guys was particularly helpful, and I tried on a lot of stuff.

A helmet is a completely indispensible piece of safety gear, and I tried on helmets from Shoei and Arai. The Arai Vector medium fit me particularly well; it's about $450. I checked on the Internet (of course), and that's a very reasonably price for that helmet. I did price checks on everything I looked at at Boston Motor Sports, and they alway came in just a little over the best Internet prices. So I'll be buying locally!

For gloves, the Power Trip Grand National medium fit well and felt comfortable; $45/pair. For jackets, there were several that seemed pretty reasonable, costing between $250 and $450 for a complete system (outer shell with protective inserts, removable inner insulation layers). Chaps or other overpants seem like a wise idea, and boots wouldn't hurt, either. So I could be looking at about $1000 worth of protective gear before I even get a machine...

I left Arlington and went out to Framingham to look at a Sym Citycom 300 at Metrowest Scooters. They were a bit more laid back about the license requirement, and I got to take the citycom out for a spin. I was a bit disappointed with the acceleration; there's clearly a big performance difference between motorcycles and scooters with similar engine sizes. But the scoot handled bumps smoothly and was, of course, insanely easy to operate.

Finally, for something completely different, I stopped at Ace Wheelworks ( a few blocks from home) and took out a Trek Allant for a test ride. It was really fun being back on a bicycle, and this one is even pretty affordable. The 20" frame was right for me, and I had no trouble (aside from my terrible out-of-shapedness) gtting it up hills and stopped on the way down.

I'm sure I won't be making any purchase real soon, but it was fun to look.