Compatibility of 1.0b1 (and earlier?) with Python 2.3

0 views
Skip to first unread message

cefstat

unread,
Sep 8, 2006, 5:43:54 PM9/8/06
to TurboGears
I deployed today a preliminary version of a TG application on a Debian
system with Python 2.3.5. Unfortunately, request urls of the form
.../page?id=1 do not work. The problem is in the function "to_kw" in
turbogears/util.py. In particular, the following

kw.update(izip(islice(argnames, start, len(argnames) - len(defaults)),
args))

does not work because in Python 2.3 update can not take an iterable as
argument. This can be easily corrected by using

kv_pairs = izip(islice(argnames, start, len(argnames) - len(defaults)),
args)
for k,v in kv_pairs:
kw[k] = v

Timur Izhbulatov

unread,
Sep 8, 2006, 7:42:01 PM9/8/06
to turbo...@googlegroups.com

Thanks!

I got the same problem this Thursday. My project did work on my laptop with 2.4
but it didn't on a development machine with 2.3. I thoght I'll have to
investigate that next week, but now I know the answer =)

--
Timur Izhbulatov
OILspace, 26 Leninskaya sloboda, bld. 2, 2nd floor, 115280 Moscow, Russia
P:+7 495 105 7245 + ext.205 F:+7 495 105 7246 E:TimurIz...@oilspace.com
Building Successful Supply Chains - One Solution At A Time.
www.oilspace.com

Mark Ramm

unread,
Sep 11, 2006, 12:23:24 AM9/11/06
to turbo...@googlegroups.com
As far as I know we are still trying to stay 2.3 compatable, so if you
open a ticket for this on Trac, (trac.turbogears.org) it should get
fixed.

You will have to register if you aren't already because we've had a
lot of trouble with wikispam.

--Mark Ramm


--
Mark Ramm-Christensen
email: mark at compoundthinking dot com
blog: www.compoundthinking.com/blog

Reply all
Reply to author
Forward
0 new messages