Jeremy Hylton : weblog xml

Jeremy Hylton's Web Log

Old web log entries : Technorati Profile

Blogging at PyCon

permanent link
Friday, March 25, 2005, 12:18 a.m.

I've been having a great time at PyCon! Good talk, catching up with lots of friends, and some renewed enthusiasm for the PSF. Greg Stein setup a blog for the Googlers at PyCon. Greg, Chris, Matthew, Will and I have been busy blogging about PyCon. I have more notes I'd like to post but my wrists can't keep up.

PyCon Lightning Talks

permanent link
Thursday, March 17, 2005, 1:11 a.m.

The lightning talks have always been one of my favorite parts of PyCon. They are an excellent way to start a conversation. It's just enough time to pitch one good idea and get people excited about it. There will be two sessions of lightning talks at PyCon this year -- Thursday after lunch and Friday after lunch. Please sign up for a talk by entering your name in the Wiki.

The first session is Thursday after lunch for 90 minutes. The second session is Friday after lunch for 60 minutes. If we could actually start a new talk every five minutes, that would be 30 talks between the two sessions. We'll have to get the speakers together and work out the logistics at lunch if it's going to work.

It would be nice to get someone to take notes on the session. It would require some lightning blogging. Can you write a sentence or two that captures the key idea of each talk and do it for each of the talks? If you can't, maybe the speaker should have been clearer about the take-home message.

What Do I Want to Learn at PyCon?

permanent link
Thursday, March 17, 2005, 12:47 a.m.

PyCon is coming! The most valuable part of the conference is connecting with people and catching up on their lives and work. As there have been more and more good talks, I've gone to fewer and fewer of them.

Another goal this year is to learn more about how people are using Python. I haven't had much opportunity to use the newer features of Python. I've never used or implemented a decorator. I haven't had much time to experiment with itertools and generator expressions. It's been a while since I've thought about metaclasses and whether there are good design techniques for using them. It looks like Alex Martelli is giving a couple of tutorial talks on these topics.

I think these would make ideal open space discussions. I'd love to see a session where people present some of their best example code and the audience asks questions and reviews it. A moderator could try to capture good design techniques and best practices. A good talk might cover similar ground, but I'm interested to see a diversity of approaches. If I can find some other people interested in these topics, I'll schedule some open space time for them.

There are also several talks I want to see. I've always favored talks about implementation techniques. There's a session with talks by Armin Rigo, Brett Cannon, and Jim Fulton that looks quite good. I'm also quite interesting to see Richard Saunders and Clinton Jeffery's work on profiling and visualization. Evan Jones is going to talk about some low-level work on obmalloc, which might be interesting, too.

I'm somewhat interested in the talk about Durus, an object database inspired by ZODB in the same way that Quixote was inspired by Zope; now that I'm not doing any ZODB development, the interest is primarily academic. I went to a talk about ATOP but didn't find it very satisfying because there was little discussion of the core design decisions for an object database. I should try to catch up with the developers this year and see how it is going.

Strategy vs. Hook

permanent link
Friday, March 11, 2005

A colleague has reminded me a second time that a strategy object is better than a hook method. In principle, I agree, but somehow I fall back to inheritance and hook methods when I actually start to write the code. I must make a more conscious effort to use composition instead of inheritance.

The most recent example was so simple: We need to versions of an object, one with a lock to provide reasonable multi-threaded semantics and one without for applications that want every ounce of performance. I suggested having _lock() and _unlock() methods in the base class and having a subclass that actually provides the lock. The strategy alternative is to call self._lock.acquire() and self._lock.release(), but have _lock be a dummy object in one case.

Lightweight Languages Program

permanent link
Tuesday, November 23, 2004

The program is set for the Lightweight Languages Workshop next month. I highly recommend it if you are in the Boston area. It's a good group of talks, an fun community of people to interact with, and you can't beat the price.

Jeremy Hylton's Other Blog

permanent link
Friday, November 05, 2004

I created my other blog using Blogger. I wanted to keep the political posts to a minimum on python.org.

Political Advocacy Call

permanent link
Wednesday, October 20, 2004

We got a pre-recorded call this afternoon from Patrick Murphy, a veteran endorsing John Kerry.

We've enjoyed living in a swing state this election season. I'm originally from Pennsylvania, but lived and voted in Maryland for the last two presidential elections. Maryland is solidly democratic, so there's never been much urgency to voting. Baltimore was so overwhelmingly Democratic that all the action was in the primary. I recall one Republican candidate for mayor who explained that he was helping the local economy by forcing his opponent to spend money on advertising -- not much of a stump speech.

In early September, we want to a Kerry rally at the Allentown Fairgrounds. It was exciting to see so many people turn out for a rally. The Morning Call reported that more than 13,000 people attended. It was the biggest rally in the Lehigh Valley since Nixon campaigned here.

The phone call today was relatively uninteresting. Murphy identified himself as a veteran and former West Point instructor and said some generic things about the importance of the election before endorsing Kerry. I've already decided to vote for Kerry and I'm not going to be swayed by phone calls. I'm just hoping I get some slanderous calls from the Bush campaign -- maybe something like the smear campaign he ran against McCain in South Carolina in 2000.

Lightweight Languages 2004 (LL4)

permanent link
Sunday, October 10, 2004, 6:51 p.m.

The 4th annual Lightweight Languages Workshop will be held at MIT on Saturday, Dec. 4 -- in the shiny new Stata Center. Presentation proposals are due on Nov. 12.

The workshop attracts a good variety of people and languages, which probably reflects the diverse and engaging mix of programmers in the Boston area. (Well, there are a lot of Lisp and Scheme programmers, but it's a diverse group nonetheless.)

It seems to me that there has been a lot of interesting work on lightweight languages lately, even if I don't know what exactly lightweight means. Groovy sure seems lightweight. JavaScript is powering excellent web-apps like GMail. In the Python world, there's IronPython, Prothon/Spry, Boo, and PyPy. I think it's a great sign of the health and vitality of the Python community that people are experimenting with new languages and features.

Python Standard Library

permanent link
Sunday, October 10, 2004, 6:51 p.m.

Andrew Kuchling argues that we should stop hacking on the Python interpreter and starting improving the standard library. It's exactly the opposite of the argument that Mitch Kapor made in his PyCon keynote: security, performance, developer tools.

I'm sympathetic to Andrew's line of reasoning. In the spirit of worse is better, I've often said that Python isn't faster because it's users are better served by other things, like better libraries or fewer interpreter crashes or better language features. The resources available for developing Python are quite limited and security and performance take a lot of effort.

There is little question that parts of the standard library need improvement; cgi comes to mind first as a module that should be rewritten from scratch. I had hoped that the Web SIG would improve web programming in Python , but it is making headway in only a narrowly focused area.

What else needs work? We need better XML tools that what we find in the standard library. There are good ideas and interfaces in ElementTree and xmltramp -- and even more interesting work in languages like Comega.

I don't agree that we need to retarget Python development, though. There has always been a healthy mix of work on libraries and work on the core language. Python 2.4 has library improvements: new decimal arithmetic, improved doctest, new email package. Python 2.3 had even more: sets, itertools, logging, new pickle protocol, csv files, and BerkeleyDB support.

Morever, Python developers choose what they want to do. There are certainly bugs to fix and patches to review, but new libraries and substantial revisions are usually the result of one or a few people who want to do it.

Andrew posted a list of six issues that ought to be resolved.

  1. Organization: I don't find this issue very interesting. I'm not sure who benefits from renaming or hierarchy. Is it a question of discovery -- putting like things together in a hierarchy to make them easier to find -- or of name clashes or something else?
  2. Process for adding new modules or packages: They need to be useful to many users, and they need to be maintainable. They two conditions imply that the code is well-designed, correct, tested, and documented. My strawman is that we accept everything in this category. What would go wrong?
  3. PyPI: I think I'd like PyPI to do things it doesn't do, but I don't feel like I've suffered for its lack of features. I think a release that contains core plus libraries is still the best model.
  4. Nomination process: Maybe a popularity contest is sufficient. Put up a Wiki page and let people add their names.
  5. Modules that need improvement: If you pick almost any module, you could find ways to improve it. A Wiki page with users' library gripes might be a good start.
  6. Look to applications for ideas about what libraries are needed. Ok. I'll bet you'll find applications where language features or better implementation would make a difference, too.

Python Bug Day

permanent link
Saturday, August 07, 2004

I made some Pythhttp://www.python.org/cgi-bin/moinmoin/PythonBugDayStatuson checkins today. The first in months. Today was the third Python bug day, organized by Andrew Kuchling. I fixed a couple of outstanding httplib problems -- only one is really a bug -- and a urllib2 problem that Andrew Sawyers discovered several months ago.

I haven't made much of a contribution to Python in the last few months. It's been quite busy getting up to speed at work and getting using to the long commute into New York City. I've been meaning to install Visual Studio on my laptop so that I can do some Python hacking on the bus, but haven't found the time. (And I spend too much time sleeping on thus bus.)

At any rate, it's nice to be doing Python development again, and it's nice to be posting to my weblog.

ZODB 3.3 alpha 3

permanent link
Friday, April 16, 2004, 4:13 p.m.

Tim Peters and I spent the better part of this week getting ZODB into shape for another alpha release. It's the last release of ZODB that I'll be actively involved in. I wish we had been able to get a beta release done, but there's too much new development for that; we need a release for people to try it out before the APIs can be finalized.

There is a long list of changes and new features in the NEWS file. My biggest project has been the revised transaction API -- a little more like the one we were working on in ZODB 4. I think the new APIs will be easier to use and provide more flexibility for people that don't like ZODB's default policy of giving each thread an independent transaction.

The revised transaction API has a completely new implementation. Most of the implementation was straightforward, but subtransaction support was not. ZODB 4 had savepoints that were created independently of committing a transaction. An application could rollback to an arbitrary savepoint, while ZODB 3's subtransaction only allow you to rollback changes since the last sub-commit. The API is cleaner for savepoints, but there's a major implementation benefit I hadn't realized before: The abort and commit logic becomes much clearer, because it isn't tangled up with the subtransaction support; they're two mostly independent features.

There are some nice changes to Persistent that were backported from ZODB 4 by Fred Drake, including improved support for getattr and setattr hooks. Fred also realized that we should distinguish between deactivating objects and invalidating objects; the former occurs because of cache eviction, the latter because of updates by another client.

The new release also reflects a new approach to writing tests. There are several tests that are based on doctest. Jim Fulton and Tim had a paper at PyCon that described some of our experience mixing doctest and unittest. Most of the new tests I've written have been constructed as module-level docstrings, e.g. testmvcc.py. A key idea is that tests require the same care and attention that the rest of your code requires; they require the same evolution and maintenance that the rest of the code requires.

We've come a long way since the StandaloneZODB release in early 2002. The current version of ZODB has support for new-style classes and multi-version concurrency control to eliminate read conflicts. We fixed a ton of bugs in concurrency control, prevented deadlock in multi-database commits, and overhauled ZEO so it was stable under heavy load. It's been a lot of fun.

Starting at Google next month

permanent link
Friday, April 16, 2004, 3:50 p.m.

I'll be starting a new job at Google in the New York City office next month. I can't wait.

Greg Stein, another long-time Python developer, just started at Google as an engineering manager. I found via an email sent to Greg's Orkut friends list. It was probably the first useful connection I've made via Orkut.

I think Orkut could be useful if it was better connected with my other communications -- email, IM, etc. -- instead of having its own closed world of messages. My friends list would be more useful if it could help me discover connections. When an email arrives from someone I don't know, it could show me friends we have in common or interest groups we both belong to. That way, it would be augmenting my existing communications and provide some incentive for participating.

PyCon attendance

permanent link
Tuesday, March 23, 2004

There's going to be a crowd at PyCon -- 320 confirmed registrations! And some of the PyCon papers are online.

It's going to be a challenge to accommodate that many people. The rooms we are planning to use for talks only hold around 100 people. Apparently, it's not possible to use the main ballroom for regular talks, because it would interfere with catering plans. The ballroom will even be at capacity for the keynote talks each morning.

It's wonderful that so many people will be coming. I think it will be a little larger than any of the earlier Python conferences -- certainly a lot bigger than PyCon 2003.