Announcing TurboGears web megaframework (Python)

TurboGears brings together four major pieces to create an easy to install, easy to use web megaframework. It covers everything from front end (MochiKit JavaScript for the browser, Kid for templates in Python) to the controllers (CherryPy) to
the back end (SQLObject).

The TurboGears project is focused on providing documentation and integration with these tools without losing touch with the communities that already exist around those tools.

TurboGears is easy to use for a wide range of web applications.

To get a quick idea of what TurboGears is like, take a look at the 20 Minute Wiki tutorial and screencast. The total screencast with brief intro and conclusion did take a little over 23 minutes, but it’s close to 20 minutes ๐Ÿ™‚

A big thanks to Remi Delon, Ian Bicking, Bob Ippolito, Ryan Tomayko, Phillip Eby and the many other contributors who have provided all of these great tools.

9 thoughts on “Announcing TurboGears web megaframework (Python)”

  1. Excellent! I’ve been playing arount with that *exact* combination (Mochikit, CherryPy, Kid and SQLObject). I am very happy to see that you want to focus on integration between these projects and on documentation!
    Off to watching the screencast …

  2. VERY nice 20 minute tutorial video, Kevin. I was pleased to see you using HTTPRedirect in particular (my baby ;). But, how could you write the title “All your pages” and not add “…are belong to us”? ๐Ÿ˜‰

    One thing I noticed in particular is the use of: input type=’hidden’. If you switch the URL scheme to use /pname/edit instead of /edit?pagename=pname, you can completely do away with the hidden input elements. Now, that does mean using a default method in your controller, which is probably too advanced to explain in a short tutorial. But if TG provided a base class which used the virtual path (pname), looked up the item (Page object) for you based on that ID (pname), and then dispatched based on the rest of the path (/edit -> self.edit), that would be VERY cool. That’s essentially what I do, but with CP plus Dejavu, my own ORM.

  3. Thanks, Robert. And thanks for all of your great work on CP! raise HTTPRedirect is a nice way to signal “hey, I’m done here!” Very pleasant.

    Amusingly enough, the written tutorial says that you can “add are belong to us” if you feel you must ๐Ÿ™‚

    The written “20 Minute Wiki” includes a trivial default method so that you can go to /PageName as you would in a normal wiki. I chopped that bit out and a minor validation usage in order to avoid the 20 Minute Wiki ballooning into the 25 Minute Wiki.

    Glad you enjoyed the screencast!

  4. I think I saw a ‘if bool == “True”:’ in there I think it should be ‘if bool:’ or ‘if bool == True:’

  5. The written version of the tutorial actually talks about that. It’s something I dropped from the screencast to save time.

    What happens is the “new” variable starts out as a boolean. When Kid gets ahold of it to send it out on the web, it turns into a string (eg “True”). So, it comes in to CherryPy as the string “True”, which is what I check for in the screencast. (It wouldn’t work properly otherwise…)

    In the written version of the “20 Minute Wiki”, I use a validator to convert the value to a real boolean.

  6. Since I didn’t need them myself, right now it’s roll-your-own. There’s nothing in TurboGears’ choice of tools that will make them harder than in other tools, and I think (if we know how people *want* it to work), there are things we can do that will make them easier.

Comments are closed.