March 14, 2008

Getting Started with Pylons/TurboGears 2: Modern Python Web Development

This presentation was as frustrating for me as it probably was for the presenters, Mark Ramm and Ben Bangert. Unfortunately the examples for the first part of the tutorial relied on having up to date copies of lots of packages, and the audience were unable to download them from the Internet as the hotel staff appeared to be having some difficulty connecting 500 geeks to the fat Internet pipe through their wireless infrastructure, and connectivity was extremely intermittent.

Things went from bad to worse when I finally managed to download the required software from the Internet and found that my examples failed: it turned out that only the presenters' machines had the necessary combination of packages. Consequently a lot of the first hour was wasted in trying to organize a thumb-drive bucket-brigade to ensure that all present had the needed stuff loaded. I can understand Mark's anxiousness to present the latest and greatest TurboGears to the audience, but I was there primarily because I wanted to get back into the technology so as to be able to make fair comparisons with Django.

While we were trying to get the load problems sorted out, mark talked about the WSGI interface and its role as a standard in the Python web world. He then talked us through a couple of practical applications, and I ended up with a simple server working based on the reference implementation, wsgiref. We then implemented the same functionality using cherrypy.wsgiserver, observing that the fundamental techniques weren't particularly different. The third exercise didn't actually add much for me, since we just had to get the existing servers to replace the initial output with a listing of the environment dictionary.

Then we moved on to TurboGears. Alas, I ended up typing in code from the handout while Mark was explaining the supporting functionality, and when all was said and done I didn't notice a lot that was new in terms of how you put a TurboGears application together. In one way this is very good, because it means that the TG re-implementation has retained the same API that its developers have become familiar with; in another it's bad, because I didn't feel I actually learned all that much as someone who had already put TG applications together, albeit small ones. Much of what was said was narrative about the state of the software rather than directed towards learning the technology. I didn't have the sample web finished, with nine pages remaining of the handout by the time Mark's part of the session was over.

Ben Bangert then proceeded to explain the differences in philosophy between TurboGears and Pylons. I'm sorry to say that my experience on the first rather-more-than-half of the tutorial left me unable to concentrate sufficiently, and I didn't absorb as much as I would have liked. I don't remember any practical work at all, and I didn't end up with a handout, but I don't know whether I missed it or what.

This was the first of a matched pair of tutorials, the second discussing advanced use of TG and Pylons. I didn't attend it because I was booked on something else in the evening session, so I hope that those who did found that this tutorial had provided them with the necessary background.

2 comments:

Anonymous said...

Thanks for the very useful feedback. I know that this tutorial was a very valuable learning experince for me.

I wish things had gone more smoothly with the afternoon tutorial, as we definitely had a lot of material we didn't get to cover because of the technical difficulties.

We'd planned to have a TurboGears 2 release out in febuary, but there were several unanticipated problems, and in spite of our best efforts it didn't happen. This put us in a rough place because the tutorial was billed as a TG2 tutorial, so it seemed like we'd make people mad if we didn't cover TG2. ;) Ben and I were up until 4 AM moving things forward to the place where we could cut a release the morning of the tutorial.

And given the network connectivity that put us in a very bad position.

Beyond that, I think doing a joint Pylons+TG tutorial was probably not the most productive thing to do for our users.-- because our audience was split between people who were primarily interested in one framework or the other.

Anyway, circumstances, technical difficulties, and a couple of unfortunate choices made this tutorial very hard to do, and made it a less than ideal experience for the students. So, I'm going to do everything I can to make that right for people. So, here's my ofer, if you were at the tutorials and there's anything I can do to help you learn TG or Pylons, let me know and I'll try my best to make that happen. (Mark dot Ramm @ gmail dot com)

Steve said...

Mark:

Thanks for the response. Partly the disappointment was because I have enjoyed previous presentations, and knew this was not a typical performance. I know from my own training work that sometimes circumstances conspire against us, and that the problems weren't all down to the presenters. I also know that your integrity would have been insulted by a dishonest review.

As you say, it was a learning experience, and I know you and Ben will be back with fabulous presentations next year—hopefully one each!

PS: next year I know the networking will be better. It's been a learning experience for the organizers too ...