RELEASED: Updates of Durus, QP, Qpy, Sancho, and Dulcinea
Michael Watkins
2008-12-04
On Wed, December 3, 2008 3:48 pm, Binger David wrote:
> Today the MEMS Exchange released updates of 5 software packages:
> Durus, QP, Qpy, Sancho, and Dulcinea.
Congratulations David and everyone who worked on this release.
Will there be an updated entry in the Package Index? It will good to see
more packages show up under the 3.0 topic over time. It does seem that
perhaps QP and friends is among the first if not actually the first web
and database development packages available on 3.0.
http://pypi.python.org/pypi?:action=browse&c=214&c=533&c=534
For those curious how Python 3.0 stacks up performance wise for a QP
application, a really crude benchmark:
ab -n 1000 http://127.0.0.1:8002/qwiki/foo/
Req/second
Python 2.5 174.79
Python 2.6 204.29
Python 3.0 173.49
That simple page doesn't work QPY very hard at all; during testing of QP
2.1 I compared QP across different Python versions and noted that QPY
template performance was significantly better in 3.0 than in 2.5; I hadn't
checked 2.6 until this week. I'm still running Python 2.5 on our
production servers but have now mostly completed a migration to code that
will run on either 2.6/3.0 (the latter not without a few workarounds for
packages not yet available on Python 3).
I've not had time to see what changed in Python 2.6 to produce better QPY
template performance:
mw@frog$ python2.5 bigtable.py
ElementTree 736.43 ms
cStringIO 36.46 ms
StringIO 141.10 ms
list concat 22.73 ms
QPY Template 129.35 ms
mw@frog$ python2.6 bigtable.py
ElementTree 656.99 ms
cStringIO 30.85 ms
StringIO 131.95 ms
list concat 16.37 ms
QPY Template 39.54 ms
mw@frog$ python3.0 bigtable.py
ElementTree 449.60 ms
StringIO 138.03 ms
list concat 21.70 ms
QPY Template 36.36 ms
The above benchmark was borrowed from the Genshi package and utilizes the
timeit module, averaging 10 passes creating a large html table using the
following template:
# this is to provide a QPY template for use in comparison
# with the Genshi "bigtable" benchmark.
table = [dict(a=1,b=2,c=3,d=4,e=5,f=6,g=7,h=8,i=9,j=10)
for x in range(1000)]
def qpy_template:xml():
'
'
for row in table:
''
for col in row.values():
'%s | ' % col
'
'
'
'