Entries in "Cleveland"

Project and apartment updates

Some interesting bits from the past few weeks...

Next Tuesday I'll be having lunch with Mike Cermak, webmaster for the Greater Cleveland Regional Transit Authority. In my previous entry I mentioned my RTA Schedule project which has been gaining popularity. There were only a few routes listed on there when I posted it, and the list has been growing as people have been using the route adder. Mike wants to work together to come up with ideas and improvements that will encourage projects like mine—a very cool response, and beneficial to RTA users as well. I'm looking forward to it!

Remember those wacky import tricks I posted about to get multiple database engines working nicely in Pagoda? After coming up with that, Ian dug around to figure out what changes would be necessary to not have to do that. He narrowed it down to one single line of code in TurboGears! In turbogears.database:

def create_session():
    "Creates a session with the appropriate engine"
    return sqlalchemy.create_session(bind_to=get_engine())

That bind_to argument is totally unnecessary when using DynamicMetaData! Changing that to just use SQLAlchemy's create_session without arguments makes multiple database engines possible without any black magic. Unfortunately, we didn't notice TurboGears 1.0.2 about to be released and didn't start any discussion about changing this in time. For now we use this little monkeypatch:

session_context = turbogears.database.session.context
session_context.registry.createfunc = sqlalchemy.create_session

So I think it works more like Alchemyware now, except we don't have to write models any differently and the engines are cached. The metadata is simply pointed to the appropriate engine in each thread.

Speaking of Pagoda, we're still at least a couple weeks away from a beta release. We're currently writing glue for all the little bits and pieces we've created over the past couple months. We've satisfied many of our original goals and learned more about (and sometimes changed) others. I'll share more about these satisfied and modified goals later.

Pagoda's third contributor, Chris, moved back home to start hunting for jobs in the California area. Good luck, Chris! Chris is a fine electrical engineer and programmer and you should hire him. This was his plan since starting to help with Pagoda, so it doesn't really affect our development schedule.

After receiving practically no feedback from the release of dmath, there has been a small surge of interest recently, with a couple contributions, so there will likely be a new release. I put up a new egg of the old version on the Cheese Shop after learning that the Python 2.5 version was busted.

geopy continues to receive patches; recently the most-requested improvement was contributed by Amos Latteier and that is the removal of print chatter in favor of logging. I'll get 0.94 out this weekend with that and other improvements.

Since Chris moved out, our friend Greg moved in with me and Sara. Greg went to school for art and likes to paint and draw, and might even prove his cooking talents at culinary school next semester. I'll be helping him make a website for his comics, which are very funny, but I can't decide if it's because I know Greg and imagine him coming up with them, which itself makes me laugh. You'll be the judge soon enough...

There are two more new, smaller residents of our apartment as well... one's a 14-inch Oscar cichlid and the other's a 15-inch Plecostomus. They're friendly and big! Now I have fantasies about getting them a bigger aquarium with all manner of luxuries. I picked them up from someone who's graduating and they came with their 45-gallon home and necessities for free! I'll post some pictures of these guys soon.

Quicker Cleveland RTA Schedule with Django

RTA

Since moving to Cleveland Heights, Sara and I have been taking the RTA to and from campus pretty often. The stop outside our apartment can get us there via the 9X or 7X, so we usually check those big tables before catching the bus. I thought it would be a big improvement if we could just have a little desktop widget that would say when the next bus on either route was coming.

But what's the fun in making such a simple widget if the backend powering it isn't generally useful? So I made a simple site that shows the bus schedules in a format more suited to our riding patterns. The plan is to have iCalendar feeds of the routes and stops, which the widget will read, while others can use the feeds however they prefer. For now the Superior & Mayfield and Mayfield & Euclid pages serve my needs.

This is after a couple days of hacking, so there are bugs, particularly in the early morning hours (due to weekday buses running until Saturday morning, for example). A trip planner would be nice too. One annoying limitation is that there isn't a list of all stops for every route that I can find. The 6 stops at Mayfield & Euclid, but it isn't listed in the abbreviated 6 schedule, so it won't show up there. Argh.

If the route you want isn't listed yet, just replace the 7X in http://exogen.case.edu/rta/route/7X with the route number and it'll fetch it from the RTA site.

Happy commuting...

Back in Cleveland (with a Piece of Reddit)

Today I arrived back at home base, Cleveland with the Segelmeister after riding two trains, two buses, and a plane.

We stayed at my house (in Newport) and did all sorts of non-Cleveland things...

  • Moved our bodies all over Boston with the amazing and enjoyable public transit system (saying loudly so Cleveland RTA can hear).
  • Found the office building of the reddit / notabug guys, decided to hold their door sticker hostage:
    reddit_sticker_1.jpg reddit_sticker_2.jpg
  • Swam in the North Atlantic.
  • Spent some time relaxing (reading & coding) in the back yard, where Sara almost met her demise at the jaws of a vicious skunk.
  • Talked with Spiros (ECMAScript Working Group and Adobe employee) about deploying the Crime Mapper at Brown (he's on the case—Providence geocoders, get in touch!).
  • Met a security consultant from Ashland, Ohio who chatted about hackers and cyberpunk authors with us when he saw that Sara was reading Snow Crash.

In five days I will be done with the Summer of Code and be able to move into the Village...

I'll end with something positive about Cleveland. While in Cambridge, Sara and I were walking around with empty stomachs and very little money. After circling Harvard Square a couple times, we couldn't find a single fast food place. Not believing that it could be too upscale for a Wendy's or McDonald's, we asked a T driver where we could find such a place...

Me: Hi, is there a fast food place nearby?
Driver: Well, what are you in the mood for?
Me: Oh, just anything super cheap and unhealthy.
Driver: Now, why would you want that?
Me: Well, we don't have a lot of money.
Driver: How much do you want to spend?
Me: Like, five dollars each.
Driver: There's a Greek place around the corner, tell them Z sent you!
Me: Okay, thanks.

We took his advice and went to the Greek place, where I reluctantly paid about $1.50 more than I had hoped for a meal... from the kid's menu. Yes, even the T drivers in Cambridge are too upscale for us.

Mapping Crimes on Campus

So a couple entries ago I mentioned that someone should make something like chicagocrime.org for Case. This is possible since we have a daily crime log which lists the location of each incident, and an excellent wiki with many geocoded locations.

I was bored a few nights ago and decided to try it out. In the interest of releasing early and often, I've made my first test available online at exogen.case.edu/crime/recent.

As you can see, it's nothing too fancy yet. This is my first non-trivial Django application, and I plan on using it as a testbed for Merquery.

So here's my to-do list (when I'm not working on Merquery, of course):

  • Draw new markers.
  • What should happen when two markers are placed on the same location, which is likely? Show both in the info window? Change the color of the marker? Try to put them next to each other?
  • Offer views by type of violation.
  • Activate the better location parsing (right now only the wiki data is checked, but the Google geocoding API helps with addresses). Already written, just needs to be put into production...
  • Geocode all the locations that couldn't be found.
  • Offer an RSS feed of recent crimes.
  • Import all incidents back to 2000 (for fun).
  • Use all the imported data for crime statistics per area.
  • Put code on opensource.case.edu.

Now to watch for that bicycle thief...


Update: Problem seems to be fixed, let me know if it's broken for you.

Update: Put the new location parser into production, and it now has a 66% success rate for geocoding locations. More wiki entries would help that number... anything to avoid doing them manually.

Clepy

On Monday night Steve, Gary and I went to a Clepy meeting. Clepy is the Cleveland Area Python Interest Group. It was the third or fourth meeting of the group, and the first time we had the chance to attend.

In short, it was pretty awesome and a lot of fun — well, as much fun as sitting in a conference room with a bunch of twenty to forty year old programmers can get, I guess. There were two talks, but the majority of time was spent on open discussion. About fifteen people were there, all very nice. There was free pizza, salad, and soda. The roundtable format made it easy to jump in and out of discussion.

At the next meeting, I'll be giving a talk about how to interact with eBay using Python. eBay recently opened up their Developer APIs so that registration is now free. They have code snippets for a bunch of languages, but unfortunately most of them suck, including the Python code. So I'll be showing how to do it right using a little library I made, or how easy it is to write your own little library to talk to eBay.

I met a KDE developer & maintainer there, Jaison Lee. We chatted about my experience doing a KDE project for Summer of Code. Hopefully I'll be getting back into KDE development very soon!

The latest news in the AIM bot saga is that the Case Phonebook account has been suspended, with the mysterious message that it "violates the Terms of Service agreement." Well, I've read the Terms of Service and I don't see anything wrong. I wonder what the problem is? I read something about AOL offering a bot API for lots of money, so I wonder if they're cracking down on rogue bots? That's too bad — the phonebook bot got about a dozen messages a day and got some good feedback, so at least someone found it useful. I hope AIM dies a slow death in light of Google Talk.

I swear our MovableType interface used to have a Log Out button. Blogging on the same computer as Patty is a real pain because we have to clear cookies to log out of Blog@Case!

Making the Best of It

This is for Patty, who is on vacation.