On Tue, Apr 06, 2004 at 11:30:38AM +0200, Daniele Varrazzo wrote: > Sorry, i don't know the internals of quixote compiling and traversal, > but a linear scan on the _q_exports list sounds a bit strange to me. > Wouldn't it be better to obtain a dict mapping sometimes (but once - > don't know where)? I'd be astonished if it made a difference; _q_exports lists are probably short (<20 items), and on a poky little iBook 'str in list' takes only a microsecond or two. Most URLs are probably short, too, so the linear search will likely cost less than a millisecond. This time is swamped by network uncertainties, the time for database queries and I/O, and the computations done in the application code. Zope also provides a lesson here; its publishing loop is even more complicated than Quixote's, yet Zope still performs acceptably. Computers are really fast these days, and a few extra Python operations on every request aren't visible to users. --amk