All Talks

2. How Import Does Its Thing

Mr. Brett Cannon
30min Intermediate
core, py3k
Any piece of complex Python code must eventually reach outside of itself and import some external code. But how does Python do it? What are the steps an import follows in order to turn some external file into a module object for you to use? And is there a way to customize how the thing works?
 
This talk will pull back the covers and show how going from ``import this`` leads to a module object being created and inserted into your module's namespace. The focus will be on the algorithm that handles importation, not low-level details like how Python source is compiled into bytecode during importation. All discussions will focus around the planned semantics for imports in Python 3.0 (i.e., PEPs 302, 328, and 3100).

3. Python in your Browser with IronPython & Silverlight

Mr. Michael J Foord (Resolver Systems) bio
30min Intermediate
implementations, ironpython, tutorial, web
Silverlight is a new browser plugin from Microsoft. It is intended for media streaming, games and rich internet applications. It is cross-platform and cross-browser and comes with a rich programmers API.
 
Through the Dynamic Language Runtime, Silverlight is fully programmable with IronPython - meaning that at last client side web applications can be written fully in Python. This talk will explore some of the things that you can do with IronPython in the browser.
 
This includes making web apps run faster, writing 'rich' applications (or games), and embedding a Python interpreter into web pages for tutorials and documentation.

4. Using Optparse, Subprocess, and Doctest To Make Agile Unix Utilities

Noah Gift bio
30min Intermediate
agile, animation, cli, command line tools, engineering, shell, technique
Most developers use Unix derived command line tools, written in C, everyday. This talk will discuss using the Python Standard Library modules, Optparse, Subprocess, and Doctest, to create equally robust tools in pure Python. There has been a lot of talk recently about Web 2.0 mashups, but the same concepts can be applied to creating command line tools in Python.
 
I will be discussing how easy it is to combine the power of the Optparse module, with the flexibility of the Subprocess module, to create standalone, and "mashup" tools from existing, and widely available Unix utilities. Finally, Doctests can be embedded to serve as an important documentation and testing tool for your newly created Unix mashup tool.

5. Getting started with test-driven development.

Mr. Jonathan Hartley (Resolver Systems) bio
45min Beginner
agile, testing
Test-driven development (TDD) is the single best way to boost your productivity, improve code quality, disambiguate specifications and provably adhere to them, and best of all, make coding fun again.
  
Getting started is demystified by creating a small test-driven project from scratch, using Python's built-in unittest module, demonstrated in a *live debugging session*. Unexpected high-level benefits of TDD are highlighted, such as refactoring, improved design, and letting testing *drive* your process, as opposed to merely writing tests.
  
Aimed at experienced Python developers who are new to automated testing. Previously presented at PyCon UK, September 2007 in Birmingham, England.

9. Using PyGame and PySight to Create an Interactive Halloween Activity

Mr. John Harrison (Insight Industries) bio
30min Beginner
animation, games, laser, python newbie, web cam
Discussion of using PyGame and PySight together with a projector and a laser pointer to create video games controlled entirely through shining a laser on the projection surface. Presentation will include a look at performance concerns, calibration, and implementation issues. As this was a first time Python project some attention will be paid to difficulties in getting started and the material will be relevant to those new to Python as well as those interested in the specific technologies involved. Audience members will be allowed to play the game at the end of the presentation and source code to the game will be provided.

13. Crunchy: Crunching on Python Documentation

Mr. Johannes Woolard (Oxford University) bio
30min Beginner
documentation, education, security, web
A look at creating interactive, web-based Python tutorials.
 
Over the last year and a half André Roberge and I have been working on an applet to bring Python to a web browser near you. We are proud to present Crunchy. Crunchy is a small program, written in Python and Javascript that serves up webpages over HTTP - it is essentially a quirky web app. There is a mechanism for executing arbitrary Python code and displaying the results in the webpage and a minimalist templating language for creating custom tutorials.
 
I will be giving a very quick demo of Crunchy's capabilities and talking about some of our more esoteric features: A custom COMET (AJAX push) stack, a versatile plugin system written in 20 lines of Python, some of our security problems and of course the flashy graphics.

14. Developing With repoze.zope2

Mr. Chris P McDonough (Agendaless Consulting) bio
30min Intermediate
eggs, web, zope
Repoze attempts to make it easier to reuse Zope technologies in a WSGI context by reimplementing select pieces of Zope as WSGI middleware. repoze.zope2 enables deployment of Zope 2 as a WSGI application, which allows Zope 2 developers to take advantage of existing WSGI servers and middleware while preserving full backwards compatibility.

21. Sights and sounds with pyglet

Richard Jones
30min Intermediate
games, library
pyglet is a new framework for developing games and other visually-rich
applications. It is written completely in Python and has no external
dependencies, using ctypes to communicate directly with the Windows, Mac OS X
and Linux standard libraries.
 
pyglet can open multiple top-level or fullscreen windows, render graphics using
the latest OpenGL API, display anti-aliased text, and play audio and video
files from a large number of compressed formats.
 
This talk introduces the use of pyglet for common graphics and audio tasks,
discusses how pyglet works with the intent of encouraging more pure-Python
library development, and will demonstrate some existing applications making
use of pyglet.
 
(Alex Holkner is unable to attend PyCon; Richard Jones is presenting in his place.)

24. nose: testing for the lazy coder

Jason Pellerin (Leapfrog Online) bio
30min Intermediate
library, testing
nose is a testing framework that extends unittest to make testing easier for the lazy coder. This talk introduces nose and demonstrates how it can work with your laziness to help you produce better and better-tested code more quickly and easily.

25. Rich UI Webapps with TurboGears 2 and Dojo

Mr. Kevin Dangoor (SitePen) bio
30min Intermediate
ajax, javascript, turbogears, web, web services
Web user interfaces can do a whole lot more today than they could a year or two ago. Some of these changes require rethinking how things are done on the server. In this talk, I'll focus on using TurboGears 2 and other Python-based tools to make a server side web API that works with a "smart" browser-based client (built with Dojo), vs. the more traditional "dumb" client model. I'll also explore how you can use TurboGears 2 to create Comet applications which allow the server to communicate back to the browser as needed.

28. Python in System Administration: How, When, and Why one SysAdmin uses Python

Mr. Sean Reifschneider (tummy.com, ltd.) bio
30min Intermediate
case study, network, shell, system administration, technique
Python is available on most Unix-like systems that are deployed today, and particularly Linux systems. In fact, Python is even available on many "mini" distributions and even rescue discs (for example, Fedora and Red Hat Enterprise rescue modes). This can provide a powerful option for when the shell seems too constrained but lower-level languages just take too much effort. A number of cases will be presented where Python was selected over other alternatives, and discussions will include cases where other choices may be preferred over Python. Audience feedback will be solicited to help guide the presentation.

30. PyTriton: building a petabyte storage system

Jonathan Ellis (Feature50)
30min Advanced
concurrency, network, performance
Backup provider Mozy handles petabytes of data and gigabits per second of bandwidth. I'll describe how I built a high-performance, distributed system in Python comparable to Amazon's S3 to scale up to these requirements, including both how Python performed well and how it fell short.

32. Decorated State Machines

Mr. Rodney Drenth (Emerson Process Management) bio
30min Intermediate
core, engineering, technique
Implementing an event based state machine can be a challanging task. This talk will show a means to straightforwardly implement and document them with an approach that uses python decorators. Python's decorators and introspection are combined to extend the language to facilitate implementing a useful design pattern.

33. SQLAlchemy 0.4 and Beyond

Mike Bayer
30min Intermediate
databases
At last year's Pycon, we introduced SQLAlchemy, the Database Toolkit for Python. This year, SQLAlchemy has gained new developers, a lot more users, and has now produced SQLAlchemy 0.4. The latest series of SQLAlchemy is significantly improved from the previous, in that APIs have been greatly pared down and refined, performance has been stepped up 30-40%, and ongoing architectural and developmental improvements have made room for lots of great new features with more to come. This talk intends to describe what's new in the 0.4 series, both for current users as well as for folks who may have only had experience with our earlier versions.

36. Case Study: Embedding Python into Counter-Strike: Source

Mr. Mattie Casper bio
30min Intermediate
case study, embedding, games
The EventScripts plugin is the most popular scripting engine addon for Valve's Source games, running on ~10,000 game servers globally. Its most recent version, EventScripts 2.0, has added support for Python 2.5 scripts. ( http://python.eventscripts.com )
 
In this presentation, the creator of EventScripts will provide a behind-the-scenes look at the process, hurdles and considerations of embedding the Python engine into games like Counter-Strike: Source and Half-Life 2: Deathmatch.

37. Developing reusable Django applications

James Bennett
30min Intermediate
best-practices, django, technique, web
Developers of Django-based applications, particularly those new to the
framework, can end up facing two separate learning curves: one for the
framework itself (learning the components and how they work together)
and one for the process of applying the general best practices of
programming to the specific case of developing Django
applications. This talk aims to soften that curve somewhat by
providing an overview of general techniques for developing reusable,
distributable applications, through both general tips and specific
"whirlwind case studies" looking at specific aspects of three real-
world applications.

39. What Zope did wrong (and how it's being fixed)

Lennart Regebro bio
30min Advanced
best-practices, web, web framework
Zope 2 did many things right, but also many things wrong. Zope 3 fixed the wrongness, but introduced other problems of it's own. This talk is about those mistakes, and what the Zope community is now doing to rectify those mistakes.
This talk aimed at all developers of web frameworks, content management systems and similar, to learn from Zopes mistakes.

41. Supervisor as a Platform

Mr. Chris P McDonough (Agendaless Consulting) bio; Mr. Mike Naberezny (Maintainable Software)
30min Advanced
system administration
Supervisor is a tool for managing UNIX processes. Supervisor starts arbitrary processes at its own startup and allows otherwise unprivileged users to start, stop and restart its subprocesses and view its subprocess' logs using a command line or web interface. Other programs exist which do this, but what sets Supervisor apart is that it is written in Python and built with extension points that can be leveraged by Python developers. In this talk, we'll look at Supervisor as a platform, and how Python programs written to run under Supervisor can use its unique capabilities.
 

43. Applying expert system technology to code reuse with Pyke

Bruce Frederiksen bio
30min Advanced
project, technique, tutorial
Pyke uses expert system technology to automatically assemble python
programs (call graphs) from a set of python functions.
 
The advantage of this approach over run-time dynamic binding approaches
(like Zope adapters or generic functions) is that the mechanism that
chooses which function to run has not executed the chosen function yet,
and so is not committed to that choice. If it discovers that a particular
function won't work because subordinate functions can't be found to fit
the situation, it can back up and try alternative functions. This can be
done at all levels of the call graph. Only when the entire call graph
has been successfully enumerated are any of the functions then executed.
 
See pyke.sourceforge.net for project documentation.

48. IronPython: The Road Ahead

Mr. Jim Hugunin (Microsoft) bio
45min Beginner
dotnet, implementations, ironpython
I’ll talk about some of the most interesting things going on with IronPython now and in the near future. This will range from cool new platforms like Silverlight that let you safely run client-side Python apps in the web browser to interesting new user-driven projects like the efforts to add support for existing C-based Python extensions to IronPython. I’ll also talk about some of the harder problems our team continues to face in being true to both Python and .NET. These range from compatibility with Python 2.6 and 3k as well as figuring out how to support .NET features which seem to require language changes such as LINQ. There will also be new demos again this year showing some of the fun things you can do with Python and .NET together.

51. Jython on the Joint Strike Fighter

Mr. George F Rice (Lockheed Martin) bio
30min Beginner
case study, jython
In 2004, Lockheed Martin selected Jython as the embedded scripting language for Java-based tools supporting the F-35 Lightning II (formerly the Joint Strike Fighter) program. Jython’s first use, to augment the primary client for a multi-national database application with over 1400 users, deployed successfully in mid-2005. Its second use, to automate data changes in a small but “click-heavy” data manipulation utility, deployed in late 2007. This paper examines the benefits and challenges of incorporating Jython into both enterprise and personal utility class applications, and examines lessons learned in supporting embedded Python scripting for end-users.

52. Use Google Spreadsheets API to create a database in the cloud

Mr. Jeffrey W Scudder (Google)
30min Intermediate
case study, cloud computing, google spreadsheets, online databse, web, web services
I'll show you how to create a Python module which wraps the Google Spreadsheets Data API web service in an interface so that it looks like a local database. Using this tool, your application can run anywhere with Internet connectivity and users will be able to take their data with them. The benefit of using Google Spreadsheets for a back-end is that it provides a simple UI which is easy for non programmers to interact with. The cost of provisioning and running a Spreadsheets based database is zero from the perspective of an application developer. This example module provides a toolkit which simplifies interactions with the Google Spreadsheets API for a specific use case: using a spreadsheet like a remote database.

53. Your Pythonic Math Class of the Future

Kirby T Urner (4D Solutions) bio
30min Intermediate
advocacy, case study, education, k-12
Currently most K-12 mathematics curricula eschew programming, but with the advent of One Laptop Per Child, other trends, there's evidence a new status quo is emerging. This talk focuses on how some prototypical classes are already putting Python to good use.

60. Introducting Agile Testing Techniques to the OLPC Project

Dr. Titus Brown (Caltech / Michigan State U.) bio
30min Intermediate
agile, best-practices, case study, gui, testing
The One Laptop Per Child project has assembled, integrated, modified,
and built on a large array of open source software. Making sure that
their software works in the first place and then *stays* functioning is
a gargantuan task. I will describe our efforts to introduce automated
testing into the OLPC project, including GUI testing and especially
*integrative* GUI testing to test the novel mesh networking and
collaborative features of the OLPC softaware. I will also discuss some
of the interesting and possibly novel software testing techniques we
used such as collaborative code code coverage recording and networked
test driver/management software. This will be an in-depth technical
talk.

61. Dogtail: Taking your applications for a walk

Mr. Ramakrishna Reddy Yekulla (Senior Software Engineer at Redhat ) bio
30min Beginner
best-practices, gui automation, project, testing
Dogtail is an open source GUI testing tool and automation framework written in Python. It uses accessibility technologies to communicate with desktop applications. Dogtail scripts are written in Python and are executed like any other Python program. It makes use of the accessibility-related meta data to create an in-memory model of the application's GUI elements.
 
The goals of this talk is to give you a better understanding of Dogtails python modules , to modify and extend them to fulfill your GUI test automation needs. Dogtail is free software released under the GPL.
 
  

63. Roll Your Own Data Persistence in Python

Mr. Sean J Taylor
30min Intermediate
best-practices, databases, performance, web
In this talk, we will explore a design pattern for constructing
full-featured data persistence in Python without using a RDBMS. We
will cover both the motivation for utilizing such an approach as well
as practical aspects such as choice of serialization (pickle, XML,
YAML, JSON) and data storage. We will discuss the implementation of
features such as indexing, replication, distribution, compression and
encryption. A provided example application will allow us to examine
the trade-offs we have made in terms of flexibility, performance, and
reliability.

64. Django: Under the Hood

Marty Alchin
30min Advanced
django
Just when you think Django can only do so much, this talk will present a variety of ways to hook into (or replace!) its internal functionality, to extend it beyond its official documentation. While the stock functionality is good enough for most sites, many advanced projects, particularly in the corporate world, will require much more.
 
In this talk, you'll learn what tools and extension points are available, how to access them, and what types of things they could be used for. Be prepared to keep an open mind; there's far more to do with these than the talk will be able cover, so combining this information with a little imagination will go a long way.

65. End-user computing without tears using Resolver, an IronPython spreadsheet

Mr. Giles Thomas (Resolver Systems Ltd) bio
30min Beginner
advocacy, business, finance, ironpython, spreadsheets
Spreadsheets, as they are currently implemented, rapidly become appallingly complex and impossible to maintain. At Resolver Systems, we've developed a spreadsheet called Resolver One that uses IronPython in a way we think can stop the madness. This talk explains why we produced Resolver One, what it can do, and most importantly, why the Python community should care.

66. Using Python To Teach Object-Oriented Programming in CS1

Dr. Michael H Goldwasser (Saint Louis University) bio; Dr. David Letscher
30min Beginner
advocacy, education, object orientation
In recent years, Python has made great inroads as an introductory language in computer science education, but few emphasize its object-oriented nature; it is most often introduced with a procedural paradigm. For those teaching object orientation in CS1, Java remains the predominant language.
 
We suggest that Python is an excellent choice for teaching an object-oriented CS1. Based on our experiences teaching such a course for three years and authoring a textbook ``Object-Oriented Programming in Python'' (http://prenhall.com/goldwasser), we discuss the issues involved in adopting Python for an object-oriented CS1, and the downstream effects on the remaining curriculum.

68. The State of Django

Adrian Holovaty
30min Intermediate
django, web framework
Cocreator and lead developer Adrian Holovaty discusses what's new and what's on the horizon of the Django Web framework.

70. Database development with Jython, SQLAlchemy, and Hibernate

Mr. Frank J Wierzbicki bio
30min Intermediate
jython
Jython is an implementation of the language Python written in Java to run on the JVM. Jython was designed to integrate seamlessly with existing Java code and as such can be used to bring dynamic language features to existing Java code bases without requiring extensive rewriting to realize the benefits of using Python. Jython has a very mature codebase, its first release occurring over ten years ago. The latest stable version of Jython (2.2) was released in August and the next version of Jython (version 2.5) is progressing well. The purpose of this talk is to demonstrate current and upcoming features of Jython language that can be used to accelerate day to day development.
 
Reading and manipulating data from relational databases is the bread and butter of many professional developers. Relational databases provide excellent examples with which to demonstrate the utililty of Jython. This talk will illustrate many of the powerful features of Jython by detailing several strategies for database access.
 
This presentation is targeted at Python developers who want to learn more about Jython and about using Jython to manipulate relational databases. Some experience with relational databases is assumed. Familiarity with SQLAlchemy or other ORM framework is helpful.
 
Throughout this talk, I will demonstrate code using Jython's interative console. I will also demonstrate how to access the built-in implementation of db-api which is built on JDBC (Java's low level db api).
 
SQLAlchemy is a popular Python ORM framework which allows access to the database to occur through objects and object relationships without necessarily resorting to detailed work in SQL. SQLAlchemy's use of the Data Mapper pattern to create a mapping between relational data and objects will be explained. Techniques for the use of SQLAlchemy through Jython will be demonstrated.
 
Hibernate is a popular Jave framework which is analogous to SQLAlchemy. Hibernate also uses a Data Mapper strategy to create its mapping between relational data and objects. I will compare and contrast Hibernate's approach with that of SQLAlchemy with plenty of example code.
 
I will also demo some new language features of Jython. In particular I will cover the relationship between Java Annotations and Python decorators in Jython. Annotations in Java look like this:
 
  //Java Annotation
  @MyDecorator(param1 = 1, param2 = "hello")
  public static void hello() { ... }
 
And python decorators look like this:
 
  #Python decorator
  @my_decorator(param1=1, param2="hello")
    def hello():
      ...
 
When Jython is compiled to a .class file the decorator is exposed as a Java annotation, also Jython can see Java annotations mapped as decorators. At the time of this writing the details of this process are still being worked out, but will be ready to demo at the time of this talk.

71. Pylons and TurboGears: Working together on the web

Mark Ramm bio
30min Beginner
pylons, turbogears, web, web framework, wsgi
During 2007, a small group of developers did an experiment in merging two popular python web frameworks. Merging might be an overstatement, but less than a year later they are sharing huge swaths of code and are working together everyday. Features have been ported in both directions, and both sides are stronger for it. This is the story of why and how that happened, and what we can learn from it all.

74. Adventures in Stackless Python/Twisted Integration

Mr. Andrew A Francis bio
30min Advanced
business, concurrency, coroutines, ecommerce, twisted, web services
Adventures in Stackless/Twisted Integration
 
WS-BPEL (Web Service Business Process Execution Language) processors tackle many issues: concurrency, network programming, persistence. Currently, Java is the language of choice for WS-BPEL processors.
 
Stagehand is a WS-BPEL processor implemented with Stackless Python and Twisted Network Framework. To those in the know, Stackless Python's threading model and Twisted's asynchronous I/O model seem incompatible.
 
Wrong.
 
This talk will show how an integrated Stackless Python and Twisted solution
circumvents problems associated with threaded and asynchronous I/O based applications. In the process, key Stackless Python and Twisted concepts and pitfalls will be discussed.

75. Tahoe: A Robust Distributed Secure Filesystem

Brian Warner bio
30min Intermediate
distributed, storage, twisted
Tahoe is a distributed application providing secure and robust storage of
files and directories. Data remains available despite massive failures of
individual servers. Tahoe is free software (see http://allmydata.org), and is
scalable from a few nodes (backing up data on your friend's machines) to a
thousand (running a large commercial backup service).
 
Tahoe runs on top of Twisted and Python, using the Foolscap library for
secure communications. It provides a RESTful web API to GET, PUT, and DELETE
your files. User-friendly front-ends are in development for Mac, Unix, and
Windows.
 
 

76. The REST is Easy

Paul Winkler (The Open Planning Project) bio
30min Intermediate
advocacy, web, web services, wsgi
REST (Representational State Transfer) is the paradigm that allows the
web to scale massively. Yet REST is also the hot new architectural
style for web services. So what is REST? This talk aims to answer that
question, head off a few common misunderstandings, and demonstrate the
REST style with simple walk-throughs of client/server interactions.
 
The talk is aimed at anyone interested in web services in general and
REST in particular. It does not presuppose knowledge of REST, nor
of the HTTP specification. Moderate familiarity with Python is assumed
for the second half (the simple example server will use WSGI, but it's
OK if you don't know WSGI). Some familiarity with HTML is desired.

77. Using Grok to Walk Like a Duck

Mr. Brandon C Rhodes (Georgia Tech) bio
30min Intermediate
advocacy, best-practices, object orientation, technique, web framework, zope
Grok provides tools for general-purpose application design. Reuse in Python often involves teaching an old class new tricks: adding attributes or methods to allow the class to function in a new environment that its author had not anticipated. A simple coding example is enough to illustrate that the three traditional Python approaches to this problem are burdened by significant limitations. The talk will examine the concept of an “adapter”, an industrial-strength design pattern which solves every problem burdening the other three approaches — but which makes it necessary to call the adapter constantly from your code! The talk therefore concludes by introducing Grok, whose ability to register and dynamically invoke your adapters will remove all mention of them from your code while leaving you in full control of how classes are adapted.

78. Consuming HTML

Ian Bicking (The Open Planning Project)
30min Beginner
html, web
HTML or XML? One is for humans, the other for computers. But with new libraries HTML can be processed nearly as reliably and quickly as XML, and developers don't always have to choose machine or humans. Consuming HTML also opens up all the content on the web. If you've been using regular expressions or the HTMLParser module to process HTML, this will also show you more robust and easier techniques.
 
This talk will demonstrate ways to manipulate HTML in Python, particularly using lxml.html but also showing examples using BeautifulSoup and html5lib.

79. Python references and practical solutions to reference-related problems

Dr. Tim Couper bio
30min Intermediate
best-practices, core, technique
The talk gives a clear presentation of:
 
* Reference counting (sys.getrefcount and how it works)
* Circular references (gc.collect as a means of finding them)
* Weak references (weakref.ref as a means of resolution)
* Pickling classes with weak references (cPickle/pickle module, __getstate__, __setstate__)
 
Along the way, we'll introduce a couple of interesting patterns which can be used to solve common classes of circular reference problems. As a side-benefit, the patterns demonstrate the clean and practical uses of properties and mixin classes (how to make a pickleable, circular-reference-free subclass of a pickleable, circular-reference-strapped class), and, of course, use the unittest framework to check that our classes always stays circular-reference-free.
 

81. The State of PyPy

Maciej Fijalkowski (merlinux GmbH) bio; Ms. Laura A Creighton (Open End AB) bio
30min Advanced
implementations, pypy
In this talk we will outline some of PyPy's unique features, namely
sandboxing, transparent proxying, our distribution prototype and our security
prototype (also known as the taint prototype). We would also like to
present and summarise the design
decisions which makes it so easy to implement such features.
 
One additional benefit of our design decisions is that low-level
decisions do not permeate the codebase. Thus, these features are not
platform-dependent. They work out of the box on different PyPy target
platforms (C/POSIX, .NET, JVM) from a single interpreter source.

84. More Iterators in Action

Jim Baker
30min Intermediate
best-practices, concurrency, coroutines, technique
Using iterators well can make your code lean and your programming fun. We will once again distill current best practice by investigating yet more useful (mostly) examples of iterators in action.

87. Stackless Python 101

Mr. Andrew A Francis bio
30min Intermediate
concurrency, coroutines, implementations
Stackless Python is a modification of
CPython which adds the concept of
lightweight concurrency. This talk focuses
on examples how to use the Stackless
features and shows sample code and
interactive sessions.
 
(Christian Tismer is unable to attend PyCon; Andrew Francis is presenting in his place.)

89. Don't call us, we'll call you: callback patterns and idioms in Python

Alex Martelli (Google, Inc) bio
45min Intermediate
best-practices, concurrency, library, technique
Callbacks (the general "Don't call us, we'll call you" pattern) are a crucial technique for concurrency, event-driven programming (in a disparate variety of fields, from GUIs to parsing), and advanced customization of library and system behavior. This talk covers callback patterns and idioms, their use in the Standard Python library, and best practices in designing and using callback-based interfaces.

91. To RE or not to RE - parsing text in Python

Anna M Ravenscroft (Stanford University)
30min Beginner
parsing, python newbie
Text parsing - breaking up text into smaller parts for processing - is a common task for programmers. Whether you're tokenizing a sentence for Part of Speech tagging in computational linguistics, automatically checking logs for specific errors, or doing Hidden Markov Models to output Emily Dickinson-style poems, chances are, at some point in your programming, you'll need to do text parsing.
 
One of the most common methods of doing text parsing uses a specialized pattern-recognition language called regular expressions. Regular expressions (REs) can be intimidating to a new programmer; they may try to avoid REs at all costs. Others will turn to REs out of unfamiliarity with the wonders of Python native string manipulation. This talk will focus on the basics:
 
 * when and how can you use Python's native string methods,
 * when to consider REs, and
 * how to do simple text parsing.
 
 

94. Python - all a scientist needs.

Dr. Julius B. Lucks (University of California, Berkeley) bio
30min Intermediate
best-practices, biology, case study, science
Any cutting-edge scientific research project requires a myriad of computational tools for data generation, analysis and visualization. Python is a flexible and extensible scientific programming platform that offered the perfect solution in our recent comparative genomics investigation (http://arxiv.org/abs/0708.2038). In this talk, I discuss the challenges of this project, and how the combined power of Biopython (http://biopython.org), SWIG (http://www.swig.org) and Matplotlib (http://matplotlib.sourceforge.net) were a perfect solution. I finish by discussing how python promotes good scientific practice, and how its use should be encouraged within the scientific community.

95. Like Switching on the Light: Managing an Elastic Compute Cluster with Python

George Belotsky (CinematX Digital) bio; Heath Johns (CinematX Digital) bio
30min Beginner
business, cloud computing, distributed, tutorial
The power and cooling costs of large data centres is increasingly becoming a problem for the bottom line -- as well as the environment. Efficient utilization of computing resources is key to controlling this problem. Elastic computing (such as Amazon's EC2 service) provides the solution, but at the risk of much higher complexity. Will the resources be there when needed? Will the system support existing applications? How different will future application development become?
 
To answer these questions, elastic computing implementations require a heterogeneous mix of components, algorithms and system administration techniques -- old as well as new. Python is the ideal language to compose all of these disparate parts into a single coherent resource, which provides computing power as simply as switching on the light.

98. Running a Successful Usergroup

Jeff Rush (Tau Productions Inc.) bio
30min Beginner
advocacy, best-practices, community
Starting a local usergroup can be fun and practical, given the resources of the Python community. I'll cover how to announce your startup, find a meeting place, and spread the word. And then get into online resources like mailing lists, wiki and IM facilities, and how to find a speakers and topics for your first meetings. And also the do's and don'ts of successful usergroups and what to do at meetings until you reach critical mass.

99. Programming Microsoft Office using Python

wesley j chun (CyberWeb Consulting) bio
30min Intermediate
business, dotnet, embedding, extensions, finance, library, software, spreadsheets, technique, tutorial
In this session, we will be introduced to Win32 COM Client programming using Python to control and communicate with Microsoft Office applications such as Word and Excel. We will then cover a pair demonstrations with source walk-through for attendees to see both what happens as well as understanding the code. All of the examples used in lecture can be found in "Core Python Programming" and its companion website http://corepython.com.

100. Buffer interface in Py3K

Travis E Oliphant (Enthought, Inc.) bio
30min Intermediate
engineering, extensions, multimedia, performance, science
Python 3.0 will include a new buffer interface that allows extension objects to share memory regions. This allows extension objects to communicate in standard ways with each other to share multi-dimensional memory of particular data-types (including structured data types). This talk will explain the buffer interface on both the C-extension and Python level along with some of its potential uses.

103. Using .NET Libraries in CPython

Mr. Feihong Hsu bio
30min Beginner
dotnet, integration, ironpython
In the past several years, .NET has really taken off in the software industry. The .NET platform includes an efficient VM and a comprehensive standard library, as well as numerous third-party libraries and tools. OK, nothing new, we've seen all this before in Java. However, unlike Java, .NET is fairly easy to integrate with your Python programs. I will show just how easy it is by giving a detailed introduction to Python.NET, a bridge between CPython and .NET.
 
Topics in this talk will include:
 
* Comparison of Python.NET and IronPython
* A basic grounding in .NET terminology, concepts, and language features
* How to read .NET documentation
* Troubleshooting tips
* Threading issues

106. py.test: towards interactive, distributed and rapid testing

Brian Dorsey (Noonhat) bio; Maciej Fijalkowski (merlinux GmbH) bio; holger krekel (merlinux GmbH)
30min Intermediate
command line tools, distributed, documentation, testing
The py.test library (http://codespeak.net/py/dist/test.html) is a mature
testing tool which uses a simple 'assert' based syntax for unit tests, and also
supports generative tests, doctests and restructured-text based tests.
 
This will be a fast-paced overview of the library with a focus on the features
beyond basic unit testing. The talk will begin with a short overview of the
main features of the py.test library. The majority of the talk will focus on
additional features including: distributed testing across multiple machines,
cross-platform testing, automatic API documentation generation, doctest
integration, and extending/custominzing py.test. The talk finishes with a brief
comparison to a few other testing tools and plans for the future of py.test.

116. Core Python Containers -- Under the Hood

Mr. Raymond D Hettinger bio
30min Beginner
core, technique, tutorial
Look under-the-hood at the implementation of Python's container classes. Understand their performance implications. And walk away with a sound basic understanding of how they work and when to use them.

117. The Power of Django Admin (Even For Non-Django Projects)

Mr. Steven C Wilcox bio
30min Intermediate
databases, django, web, web framework
The Admin interface for Django is powerful and can be useful for building stand-alone applications or as the official web-admin interface for non-Django projects. We'll review the capabilities and limitations of the Django Admin interface as well as the database introspection utility that can be used to quickly get a Django application setup.

121. Managing Complexity (and testing)

Matt Harrison (Insight Industries) bio
30min Intermediate
agile, complexity, coverage, technique, testing
Controlling complexity is the essence of computer programming - Brian Kernighan. What is complexity? How do you measure it? How does this affect your testing and code coverage?

123. 2to3: translating Python 2 to Python 3

Mr. Collin Winter (Google) bio
45min Beginner
parsing, py3k
This talk will present the 2to3 translation tool, an integral part of the Python 2.x -> Python 3.x migration strategy. 2to3's lead developer will walk through the motivation behind the tools, how it fits into the overall porting strategy, the general workflow for using 2to3, and ways anyone interested in improving the process can get involved.

125. Programming for the One Laptop Per Child laptop

Mr. Charles Merriam bio
30min Intermediate
easy to develop, education, project, tutorial
The One Laptop Per Child (OLPC) is shipping around the world and includes a core Python development environment. This provides enough introduction to the operating environment, development tools, simulator, and style issues for you to decide if you want to develop for the OLPC. We walk through a couple programs, including a taste of multimedia and mesh networking services.

126. Building Trac Plugins

Mr. Noah Kantrowitz (Rensselaer Polytechnic Institute) bio
30min Intermediate
eggs, web
An overview of the Trac plugin framework and a walk-though of an example
plugin.
 
The project management webapp Trac is becoming increasingly popular, however
the base system is purposefully simplistic. A modular plugin framework exists
to extend Trac in many ways, offering unparalleled flexibility without adding
excessive bloat. Writing custom plugins is often an integral part of crafting
Trac to match your team's workflow and habits.
 
I will go over how to build Trac plugins from scratch, as well as look through
examples of some of the more complex patterns.

127. Unicode In Python, Completely Demystified

Mr. Kumar McMillan (Leapfrog Online) bio
30min Intermediate
text, unicode
This talks aims to make every single last person in the audience understand exactly how to write unicode-aware applications in Python 2. If necessary, we will move to a Birds of Feather gathering, to the bar, to your hotel room, I'll start hanging around your cube at work -- whatever it takes -- until you completely "get it." But it's really simple so bring an open mind, a notepad, and get ready to create bullet proof Python software that can read and write text in Arabic, Russian, Chinese, Klingon, et cetera. As a citizen of the Python community you have the responsibility of creating unicode-aware applications!

128. A New Compiler for Jython

Jim Baker; Mr. Tobias Ivarsson bio
30min Advanced
ast, concurrency, coroutines, jython, performance
As part of the Google Summer of Code, we created a prototype of a fully-functional Jython 2.5 compiler. We will discuss this and our subsequent work to turn this into a production-ready compiler.

131. MPI Cluster Programming with Python and Amazon EC2

Peter Skomoroch (Juice Analytics) bio
30min Beginner
case study, cloud computing, distributed, performance, tutorial
Amazon EC2 may offer the possibility of high performance computing to programmers on a budget. Instead of building and maintaining a permanent Beowulf cluster, we can launch a cluster on-demand using Python and EC2. This talk will cover the basics involved in getting your own cluster running using Python, demonstrate how to run some large parallel computations using Python MPI wrappers, and show some initial results on cluster performance.

132. Developing, Testing, and Debugging Python Applications with Wing IDE

Mr. Stephan R.A. Deibel (Wingware) bio
30min Intermediate
best-practices, gui, ide
Wing IDE is a commercial integrated development environment for the Python programming language. Wing runs on Windows, Linux, and OS X, supports Python 1.5.2 through 2.5, and provides many editing, testing, and debugging features for the Python programmer. It is written in Python, uses the PyGTK GUI library, and is developed and debugged with itself.
 
This presentation will start with a brief description of how Wing IDE is developed, what technologies are used, and some lessons learned from our experience developing this complex cross-platform GUI application in Python.
 
This will be followed by a tour of Wing IDE's features, which will cover Wing's code intelligence capabilities, the new unit testing tool, the debugger, and selected other features that make the most difference in day to day Python programming.

134. Python-powered Multitouch

Peter Z Wang (Enthought, Inc.) bio; Mr. David Kammeyer (Enthought, Inc.); Robert Kern
30min Beginner
finance, geospatial, graphics, multimedia, science, user interfaces
We present a homemade multitouch table whose operating principles are similar to the Microsoft Surface and the device Jeff Han showed at TED 2006. In this talk, we describe the Python-based software we've developed to turn a simple infrared camera into a multi-pointer input device. We will also demonstrate some of our sample applications, from games and amusements to more "serious" applications of the multi-pointer user interface paradigm.

139. High performance Network IO with Python + Libevent

Michael M Carter (Orbited) bio
30min Intermediate
concurrency, distributed, fast web presence, network, performance, tutorial, twisted, web
Python comes with a full suite of network apis that are robust, complete, and easy to develop with. For high concurrency demands there is asyncore and Twisted. But even with these alternatives to synchronous network IO, many applications require higher performance. Additionally, some developers have trouble learning Twisted's substantial api. This talk presents the technique of integrating python and libevent, a c-based high performance network IO library, to develop fast and highly-concurrent network services. In particular, this talk focuses on the pyevent library, explaining basic usage of the library and providing step-by-step analysis of example code as well as benchmarks.

140. Case Study of Python Application Development -- Humanized Enso

Jono DiCarlo (Humanized, Inc) bio
30min Intermediate
case study, command line tools, extensions, packaging, project, software, technique, testing, user interfaces
Think that Python is just for web frameworks and scripting? Come hear the case study of how we developed Enso, a client-side, end-user Windows application, almost entirely in Python (with a little C) and how doing so sped up our development cycle enormously.
 
Talk will focus on how to write Python extension modules in C using SWIG and ctypes, how to automate your build process with Python using scons, and how to package Python code into an easily distributable Windows application using py2exe. It will also explain why supposed pitfalls like dynamic typing and slow performance did not turn out to be significant problems at all.