It Fits Your Brain: the Ninth Annual International Python Conference
2001 is also the year of Zope Alternatives. My favorite discovery was Webware. Chuck Esterbrook developed this modular web application server out of frustration with the monolithic nature of Zope (see Chuck's presentation for an overview). The main component is WebKit, which allows Python packages to be servlets. Here's a minimum servlet:
from WebKit.Page import Page
class index(Page):
def title(self): # This will go into the HTML <TITLE> tag.
return "Important Message"
def writeBody(self):
self.writeln(" This web site is not here yet.")
You can call this "index.py" and invoke it in the browser as index.py, index or even as the directory. The file must contain a class with the same name as the file, and this class is normally a subclass of Page. CGI parameters and cookies are as simple as:
req = self.request()
fname = req.field('fname')
bgcolor = req.cookie('bgcolor', '#FFFFFF') # With default.
You even get a session object for free:
sess = self.session()
name = sess.value('name')
sess.setValue('x', 5)
The application caches servlet instances for later reuse. It interacts with Apache or AOLserver via a CGI interface or a web server module (e.g., mod_python). Two other plug-ins deserve mention. Python Server Pages is for those who prefer embedding Python commands in HTML files à la ASP or PHP. MiddleKit is an object-oriented intermediary for database access.
I wish I had space to discuss some of the other talks. Eric Raymond presented CML2, his Linux kernel configuration system. Others talked about internationalizing Mailman using GNU gettext, weak references, writing Microsoft .NET programs in Python, etc. One notable module mentioned is pyperl), which allows your script to call Perl functions.
In the hallway were vendor exhibits, including ActiveState's Python Cookbook (a free interactive FAQ), and the Toilet Paper display.
Toilet Paper is an automated water closet. No, there wasn't a loo in the hallway, just a diagram of the privy. A 486 computer running Slackware sits alongside the porcelain bowl. It detects visitors outside via a motion detector and has sensors for toilet seat position, light switch position, etc., and then plays appropriate music for each state. It fetches selected web pages, extracts the headlines and displays them on an LCD screen. Toilet also has an external web interface to request songs, report on its usage history (scary) and send messages to the LCD screen.
Bruce Eckel is the person who invented the "Python Fits Your Brain" slogan as well as last year's "Life is Better Without Braces". He's also a well-known C++ and Java design consultant. In his closing keynote, Bruce presented the top ten reasons why he loves Python:(See the Powerpoint slides from Bruce's presentation.)
10. Reduced clutter.
9. It's not backward-compatible with other languages. (This came with some hilarious one-liners: "C++'s backward compatibility with C is both its strength and its bane"; "Java causes repetitive-strain syndrome"; "Perl is compatible with every hacky syntax of every UNIX tool ever invented"; "C# and Microsoft .NET are backward-compatible with Microsoft's previous marketing campaigns"; and "Javascript is not even compatible with itself".)
8. It doesn't value performance over my productivity.
7. It doesn't treat me like I'm stupid. Java insists operator overloading is bad because you can make ugly code with it. Bruce observes, "And we all know there's no ugly Java code out there."
6. I don't have to wait forever for a full implementation of the language.
5. It doesn't make assumptions about how we discover errors.
4. Marketing people are not involved in it (yet).
3. I don't have to type so much. But what I do type is the right typing.
2. My guesses are usually right.
1. Python helps me focus on my concepts rather than on fighting with the language.
His idea for the next Python slogan? "No warranty, not fit for any particular purpose." We'll see about that next year.
Conference proceedings and slides have been posted to the Python9 web site.
Mike Orr writes web applications at SSC, edits Linux Gazette and does other sysadmin stuff. He doesn't usually write articles, but he makes an exception for Python because it's so cool.
email: mso@ssc.com
Realizing the promise of Apache® Hadoop® requires the effective deployment of compute, memory, storage and networking to achieve optimal results. With its flexibility and multitude of options, it is easy to over or under provision the server infrastructure, resulting in poor performance and high TCO. Join us for an in depth, technical discussion with industry experts from leading Hadoop and server companies who will provide insights into the key considerations for designing and deploying an optimal Hadoop cluster.
Sponsored by AMD
Built-in forensics, incident response, and security with Red Hat Enterprise Linux 6
Every security policy provides guidance and requirements for ensuring adequate protection of information and data, as well as high-level technical and administrative security requirements for a system in a given environment. Traditionally, providing security for a system focuses on the confidentiality of the information on it. However, protecting the data integrity and system and data availability is just as important. For example, when processing United States intelligence information, there are three attributes that require protection: confidentiality, integrity, and availability.
Learn more about catching the bad guy in this free white paper.
Sponsored by DLT Solutions
| Designing Electronics with Linux | May 22, 2013 |
| Dynamic DNS—an Object Lesson in Problem Solving | May 21, 2013 |
| Using Salt Stack and Vagrant for Drupal Development | May 20, 2013 |
| Making Linux and Android Get Along (It's Not as Hard as It Sounds) | May 16, 2013 |
| Drupal Is a Framework: Why Everyone Needs to Understand This | May 15, 2013 |
| Home, My Backup Data Center | May 13, 2013 |
- New Products
- Linux Systems Administrator
- Senior Perl Developer
- Technical Support Rep
- UX Designer
- Web & UI Developer (JavaScript & j Query)
- Designing Electronics with Linux
- Dynamic DNS—an Object Lesson in Problem Solving
- Making Linux and Android Get Along (It's Not as Hard as It Sounds)
- Using Salt Stack and Vagrant for Drupal Development
Enter to Win an Adafruit Pi Cobbler Breakout Kit for Raspberry Pi

It's Raspberry Pi month at Linux Journal. Each week in May, Adafruit will be giving away a Pi-related prize to a lucky, randomly drawn LJ reader. Winners will be announced weekly.
Fill out the fields below to enter to win this week's prize-- a Pi Cobbler Breakout Kit for Raspberry Pi.
Congratulations to our winners so far:
- 5-8-13, Pi Starter Pack: Jack Davis
- 5-15-13, Pi Model B 512MB RAM: Patrick Dunn
- 5-21-13, Prototyping Pi Plate Kit: Philip Kirby
- Next winner announced on 5-27-13!
Featured Jobs
| Linux Systems Administrator | Houston and Austin, Texas | Host Gator |
| Senior Perl Developer | Austin, Texas | Host Gator |
| Technical Support Rep | Houston and Austin, Texas | Host Gator |
| UX Designer | Austin, Texas | Host Gator |
| Web & UI Developer (JavaScript & j Query) | Austin, Texas | Host Gator |
Free Webinar: Hadoop
How to Build an Optimal Hadoop Cluster to Store and Maintain Unlimited Amounts of Data Using Microservers
Realizing the promise of Apache® Hadoop® requires the effective deployment of compute, memory, storage and networking to achieve optimal results. With its flexibility and multitude of options, it is easy to over or under provision the server infrastructure, resulting in poor performance and high TCO. Join us for an in depth, technical discussion with industry experts from leading Hadoop and server companies who will provide insights into the key considerations for designing and deploying an optimal Hadoop cluster.
Some of key questions to be discussed are:
- What is the “typical” Hadoop cluster and what should be installed on the different machine types?
- Why should you consider the typical workload patterns when making your hardware decisions?
- Are all microservers created equal for Hadoop deployments?
- How do I plan for expansion if I require more compute, memory, storage or networking?



1 hour 32 min ago
12 hours 13 min ago
17 hours 59 min ago
18 hours 16 min ago
20 hours 9 min ago
22 hours 2 min ago
1 day 4 hours ago
1 day 5 hours ago
1 day 7 hours ago
1 day 12 hours ago