Skip to main content

Posts

Showing posts from March, 2005

Python: PyCon 2005 random thoughts

Some people have asked me to provide some comments on PyCon 2005. Here is an informal collection of impressions and opinions. I won't cover the Web topics because I've already done that.

Alex Martelli's talks are a joy. I especially liked his talk on 'Descriptors, Decorators, Metaclasses: Python's "Black Magic"'. I just wish he had more time. 25 minutes is simply not enough time to understand the subjects he is trying to convey unless you already understand them.

PyPy is definitely not what I thought it was. Apparently, it's about type inference. I thought it was an attempt to rewrite the front-end of the Python interpreter in Python so that the front-end could be shared among all the versions of Python. If this were the cases, the front-end could be distributed as .pyc's, and all the versions of Python would only need to write VM's to interpret the .pyc's. :-/

wxPython is a pain to use. PythonCard is a wrapper around wxPython that make…

Web: The Brian Problem

Thinking back to the early days of Aquarium, Chuck Esterbrook and I thought about merging Aquarium and Webware. Unfortunately, I'm a bit of a code nazi, and Webware isn't the most minimal, style-conforming code around (which multiple people have confirmed, so it's not just me). This dissuaded me from joining forces. The fact that I was out of the Web world for about two years gave Webware a big leg up :-/

Moving forward, I'd like:
To work hard on newbie documentation for the PyWebOff's concept of "Brian" (i.e. a Python newbie who knows PHP and is now trying to write Web applications in Python).
To revive Piranha for all the "Ruby on Rails" folk. SQLObject and the Subway project may make some or all of this work unnecessary.
To better integrate with SQLObject and FormEncode.
To write a WebServerAdaptor for Twisted. At IronPort, we use coroutines. I work with Sam Rushing, the author of Medusa. Since coroutines are strictly better than Twisted (same ben…

Web: PyCon 2005

I just finished attending PyCon. Specifically concerning the Web, I'd like to direct your attention to:

http://pyre.third-bit.com/pyweb/index.html
Basically, there are too damned many Web application frameworks, and they all assume you know what you're doing. The PyWebOff is an attempt to figure out which is best from a newbie's perspective. Hopefully the talk will be available in video format later. I just finished reading the blog. She said, "Please, whatever you do, don't try to solve the problem by writing another Web application framework!!!"

http://www.python.org/peps/pep-0333.html
Ian Bicking gave a talk on this. It's an attempt at consolidating some underlying Web application API's. Basically, it's an attempt at making up for lack of a servlet API. It's great in that Web application framework authors may be able to share some code, but it still doesn't address the fact that there are too many choices for the user. Furthermore, it does…

Python: Create a new class on the fly

At PyCon, Alex Martelli mentioned that you could create a class on the fly using the type function. Previously, I probably would have used the exec function. I feel like such a dork:
>>> class Template(object): # Must be a new-style class.
... def bark(self):
... print "woof"
...
>>> Page = type("Page", (Template,), {})
>>> Page().bark()
woof
>>>
>>> def meow(self):
... print `self`
... print "meow"
...
>>> Page.meow = meow
>>>
>>> Page().meow()
<__main__.page>
meow

Welcome to JJinuxLand

Karl Guertin told me, "He who blogs gets his opinion heard." Hence, inspired by the blogs of Anthony Eden, Leon Atkinson, and Ian Bicking, I have created my own. This is a purely technical blog concerning topics such as Python, Linux, FreeBSD, open source software, the Web, and lesser-known programming languages. In the interest of everyone's time, including my own, I hope to keep the volume low, and the technical content high.

Please excuse the fact that I did not write my own blog software. It isn't that I am unable to. It's simply that I hate reinventing the wheel when exceedingly round ones already exist. I chose blogger.com specifically on the recommendation of Krishna Srinivasan, Tung Wai Yip, Anthony Eden, and Google.

I look forward to your comments.