Re: [Zope-dev] zope2 webdav memory usage...

2008-01-15 Thread Chris Withers

Jim Fulton wrote:


You know, you could have provided a link.


I believe it's Dieter's policy never to actually provide links to 
anything ;-)


Chris

--
Simplistix - Content Management, Zope  Python Consulting
   - http://www.simplistix.co.uk
___
Zope-Dev maillist  -  Zope-Dev@zope.org
http://mail.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
http://mail.zope.org/mailman/listinfo/zope-announce

http://mail.zope.org/mailman/listinfo/zope )


[Zope-dev] Zope Tests: 5 OK

2008-01-15 Thread Zope Tests Summarizer
Summary of messages to the zope-tests list.
Period Mon Jan 14 12:00:00 2008 UTC to Tue Jan 15 12:00:00 2008 UTC.
There were 5 messages: 5 from Zope Unit Tests.


Tests passed OK
---

Subject: OK : Zope-2.7 Python-2.3.6 : Linux
From: Zope Unit Tests
Date: Mon Jan 14 20:52:03 EST 2008
URL: http://mail.zope.org/pipermail/zope-tests/2008-January/008951.html

Subject: OK : Zope-2.8 Python-2.3.6 : Linux
From: Zope Unit Tests
Date: Mon Jan 14 20:53:33 EST 2008
URL: http://mail.zope.org/pipermail/zope-tests/2008-January/008952.html

Subject: OK : Zope-2.9 Python-2.4.4 : Linux
From: Zope Unit Tests
Date: Mon Jan 14 20:55:03 EST 2008
URL: http://mail.zope.org/pipermail/zope-tests/2008-January/008953.html

Subject: OK : Zope-2.10 Python-2.4.4 : Linux
From: Zope Unit Tests
Date: Mon Jan 14 20:56:34 EST 2008
URL: http://mail.zope.org/pipermail/zope-tests/2008-January/008954.html

Subject: OK : Zope-trunk Python-2.4.4 : Linux
From: Zope Unit Tests
Date: Mon Jan 14 20:58:04 EST 2008
URL: http://mail.zope.org/pipermail/zope-tests/2008-January/008955.html

___
Zope-Dev maillist  -  Zope-Dev@zope.org
http://mail.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope )


[Zope-dev] proxies

2008-01-15 Thread Chris Withers

Hi All,

I saw the zope.proxies module and wondered if it might be able to help 
me with two problems I need to solve:


- can these proxies be used to keep track of a traversal path in much 
the same way (although no seperate containment and context chains 
needed) as the old Zope 2 acquisition wrappers did?


- once a proxy has been created, the the object it's proxying for be 
replaced?


cheers,

Chris

--
Simplistix - Content Management, Zope  Python Consulting
   - http://www.simplistix.co.uk
___
Zope-Dev maillist  -  Zope-Dev@zope.org
http://mail.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
http://mail.zope.org/mailman/listinfo/zope-announce

http://mail.zope.org/mailman/listinfo/zope )


Re: [Zope-dev] KeyError in ZRDB.DA cache handling

2008-01-15 Thread Chris Withers

Hi there,

J Cameron Cooper wrote:

but we have that fix in our Zope 2.9.8:
  http://osdir.com/ml/web.zope.all-cvs/2006-11/msg00150.html


Are you absolutely sure you're using a version of Zope with my patches 
included?


Perhaps it is another high-load leak? I don't think it can be multiple 
threads doing cleanup at the same time, unless maybe there's a 
transaction commit in there somewhere I don't know about.


I'm afraid it's long enough ago that this code was touched that I can't 
really comment on this bit :-S


Or maybe I'm running into the problem described in the big comment at 
the end?::


Don't think so, this describes a leak, not a cause of exceptions...

Would it be unsafe to toss a try/except around the del cache[q] bit on 
the theory that it's already deleted, so, hey, why fail? It'd be really 
nice to keep this off of users, even with it if does cause a bit of a leak.


Not sure about the try/except, would be better to nail why the key isn't 
there... Best bet is to start trying to reproduce this in a unit test, 
which can be pretty hard :-S


I'll probably be setting up some logging to try and characterize this 
further,


Any results from this?

cheers,

Chris

--
Simplistix - Content Management, Zope  Python Consulting
   - http://www.simplistix.co.uk
___
Zope-Dev maillist  -  Zope-Dev@zope.org
http://mail.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
http://mail.zope.org/mailman/listinfo/zope-announce

http://mail.zope.org/mailman/listinfo/zope )


[Zope-dev] more on stacked component registries

2008-01-15 Thread Chris Withers

Hi All,

Happy New Year, etc :-)

Been working more on this stuff so finally have some more questions...

Philipp von Weitershausen wrote:
Okay, but where's this code? (ie: what .py should I look at for the 
local registry implementation)


zope.app.component.site contains the LocalSiteManager class. This is the 
persistent component registry used in Zope 3's standard ISites. It 
inherits from zope.component.persistentregistry.PersistentComponents 
which in turn inherits from zope.component.registry.Components. The 
latter has the dynamic __bases__ property. You'll see that the setter 
really just sets the __bases__ on its internal adapter and utility 
registry. Both of those (sic!) 


What does this sic mean?

are some sort of subclass of 
zope.interface.adapter.BaseAdapterRegistry which has the handling for 
cascading lookups through its __bases__ property.


Actually, it doesn't. The handling of __bases__ appears to be done in 
the functions of the mysterious zope.interface.ro module.

(that ro thing takes the biscuit for obscure naming :-( )

Am I off base here? If so, more info please! :-)

Anyway, another question I have relates to the way in which registries 
and sub registries are stacked up. Am I right in assuming the current 
code is designed around a static setup of adapter registries which the 
deeper registries cache the results of the registries higher up?


For what I'm after, I need to have a more dynamic buildup of 
registrations based on which objects have been traversed through.


I can see two ways to approach this:

- stack the registries up during travesal in some way. I guess this
  would be a variant of what's done now with current nested registries.
  Is this feasible? Will there be performance problems?

- use one global registry and add/remove registrations during traversal 
as necessary. How fast is registration/unregistration of adapters and 
the like? How many adapter adds/removes at a traversal node would it 
take to really slow things down?


I still feeling like I'm grasping a bit here but I hope you guys can help!

cheers,

Chris

--
Simplistix - Content Management, Zope  Python Consulting
   - http://www.simplistix.co.uk
___
Zope-Dev maillist  -  Zope-Dev@zope.org
http://mail.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
http://mail.zope.org/mailman/listinfo/zope-announce

http://mail.zope.org/mailman/listinfo/zope )


Re: [Zope-dev] python 2.5 and zope components?

2008-01-15 Thread Christophe Combelles

Chris Withers a écrit :

Hi All,

Is there a known/unknown list of what Zope 3 components work with Python 
2.5 and what don't?


there is a wiki page
http://wiki.zope.org/zope3/Zope3UsingPython25
and a status list
http://wiki.zope.org/zope3/ModuleImplementationStatus

Christophe



My memory tells me a lot of work was done on this recently for a Google 
SoC project, I hope my memory is right :-)


Also, what's the canonical way of compiling Zope 3 components on Windows?

Is there a canonical source of compiled Zope 3 components for Windows?

cheers,

Chris



___
Zope-Dev maillist  -  Zope-Dev@zope.org
http://mail.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
http://mail.zope.org/mailman/listinfo/zope-announce

http://mail.zope.org/mailman/listinfo/zope )


[Zope-dev] Re: more on stacked component registries

2008-01-15 Thread Raphael Ritz

Chris Withers wrote:

[..]

Actually, it doesn't. The handling of __bases__ appears to be done in 
the functions of the mysterious zope.interface.ro module.

(that ro thing takes the biscuit for obscure naming :-( )



Without having a clue my first guess would be that this means
'Resolution Order' as we have 'mro' (Method Resolution Order)
and 'iro' (Interface Resolution Order) for instance.

But I could be completely off track ;-)

Raphael



Am I off base here? If so, more info please! :-)



___
Zope-Dev maillist  -  Zope-Dev@zope.org
http://mail.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
http://mail.zope.org/mailman/listinfo/zope-announce

http://mail.zope.org/mailman/listinfo/zope )


[Zope-dev] Re: KeyError in ZRDB.DA cache handling

2008-01-15 Thread J Cameron Cooper

Chris Withers wrote:

Hi there,

J Cameron Cooper wrote:

but we have that fix in our Zope 2.9.8:
  http://osdir.com/ml/web.zope.all-cvs/2006-11/msg00150.html


Are you absolutely sure you're using a version of Zope with my patches 
included?


Yes; I've checked both version (this went in for 2.9.6) and for that 
specific code. You can even see some of it in the excerpt in the 
original message, which I pasted straight from our production Zope.


I had hoped it was simply missing the fix, too, but no dice. Now, I 
can't guarantee that the fix in question has remained working since it 
was checked in, but the release code looks much like the the patch.


Perhaps it is another high-load leak? I don't think it can be multiple 
threads doing cleanup at the same time, unless maybe there's a 
transaction commit in there somewhere I don't know about.


I'm afraid it's long enough ago that this code was touched that I can't 
really comment on this bit :-S


Or maybe I'm running into the problem described in the big comment at 
the end?::


Don't think so, this describes a leak, not a cause of exceptions...

Would it be unsafe to toss a try/except around the del cache[q] bit on 
the theory that it's already deleted, so, hey, why fail? It'd be 
really nice to keep this off of users, even with it if does cause a 
bit of a leak.


Not sure about the try/except, would be better to nail why the key isn't 
there...


I agree, of course, but these do end up being user visible, and a 
workaround, as long as it's not going to cause worse things, would be nice.


Something like the original workaround in the bug might be in order for 
me (rather than a try/except) until the real fix is found.


http://launchpadlibrarian.net/9460742/Zope-2.8.6-cached-result.patch

I don't imagine it can cause more than cache bloat, and we restart 
enough that that shouldn't kill us.


Best bet is to start trying to reproduce this in a unit test, 
which can be pretty hard :-S


Yes, indeed. I did notice that the test you mention in:

https://bugs.launchpad.net/zope2/+bug/143805

doesn't seem to exist, at least in my version.

I'll probably be setting up some logging to try and characterize this 
further,


Any results from this?


I haven't yet inserted anything in production (I get funny looks at the 
suggestion) but we'll be trying to cause it in a development system soon.


   --jcc

--
Connexions
http://cnx.org

Building Websites with Plone
http://plonebook.packtpub.com

___
Zope-Dev maillist  -  Zope-Dev@zope.org
http://mail.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
http://mail.zope.org/mailman/listinfo/zope-announce

http://mail.zope.org/mailman/listinfo/zope )


[Zope-dev] Zope 3 without ZODB

2008-01-15 Thread David Pratt
Hi Chris. I was scanning the lists looking for posts similar to this. 
Were you successful in getting something like this to work? Anyone else 
document anything like this?


I wrote a different main.py at some point about a year or so ago so both 
twisted clients and servers to could be started up using schemas for 
zconfig but am looking at possibilities without and with other non ZODB 
backends. I see Philip provided some clues for a mixin that could be 
used to glue the publisher's traversal mechanism together with an 
alternative storage.  Many thanks.


Regards,
David


Chris Withers wrote:

Hey All,

I'm still continuing poking around (when I have the chance) to see how 
I'd get Zope running without ZODB.


Does the following line:

db = zope.app.appsetup.appsetup.multi_database(options.databases)[0][0]

...from:

http://svn.zope.org/Zope3/trunk/src/zope/app/server/main.py?rev=71011view=markup 



...mean that Zope 3 is currently hard-coded to need a ZODB?

If so, how should we go about making this optional?

(I am willing to put the work in to make this happen if people give me 
some hints...)


cheers,

Chris


___
Zope-Dev maillist  -  Zope-Dev@zope.org
http://mail.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
http://mail.zope.org/mailman/listinfo/zope-announce

http://mail.zope.org/mailman/listinfo/zope )


Re: [Zope-dev] zope2 webdav memory usage...

2008-01-15 Thread Dieter Maurer
Chris Withers wrote at 2008-1-15 09:42 +:
 You know, you could have provided a link.

I believe it's Dieter's policy never to actually provide links to 
anything ;-)

Indeed, I never search for others...

If I have the link at hand, you may get a link, but if not,
then your effort to search is as big as mine.



-- 
Dieter
___
Zope-Dev maillist  -  Zope-Dev@zope.org
http://mail.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope )


Re: [Zope-dev] Zope 3 without ZODB

2008-01-15 Thread Jim Washington
David Pratt wrote:
 Hi Chris. I was scanning the lists looking for posts similar to this.
 Were you successful in getting something like this to work? Anyone
 else document anything like this?

 I wrote a different main.py at some point about a year or so ago so
 both twisted clients and servers to could be started up using schemas
 for zconfig but am looking at possibilities without and with other non
 ZODB backends. I see Philip provided some clues for a mixin that could
 be used to glue the publisher's traversal mechanism together with an
 alternative storage.  Many thanks.

 Regards,
 David
I, too, am interested in this.

I'm taking a hard look at Sedna, http://modis.ispras.ru/sedna/ , a
multi-user XML database, which seems to fit my brain and my current
xml-ish bent a bit better than ZODB or rdb.

The python modules advertised don't work reliably enough for me, though
I have hacked together a protocol module that works to my satisfaction
so far.  If anyone wants to play with it, I'll throw it into the zif
collective on Sourceforge.  I'm thinking it may be possible to do an
elementtree (with full XPath!) interface to Sedna.

Anyway, Chris, any pointers on interfaces and configuration would be
very much appreciated.

-Jim Washington




___
Zope-Dev maillist  -  Zope-Dev@zope.org
http://mail.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope )


Re: [Zope-dev] Re: KeyError in ZRDB.DA cache handling

2008-01-15 Thread Dieter Maurer
J Cameron Cooper wrote at 2008-1-15 10:01 -0600:

I do not have a fix (or an explanation) for your problem -- but maybe
I can suggest a workaround: you might replace ZSQLMethod by my
CCSQLMethod.

  http://www.dieter.handshake.de/pyprojects/zope





-- 
Dieter
___
Zope-Dev maillist  -  Zope-Dev@zope.org
http://mail.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope )


[Zope-dev] [Zope2/Multi-Version-Eggs] Imports behaving strange

2008-01-15 Thread Andreas Jung

Hi,

I have running Zope 2 application using SQLAlchemy 0.3.11/z3c.sqlalchemy 
1.0.11 and needs to be migrated to SA 0.4/z3c.sqlalchemy 1.1. For the 
migration period I installed all four versions as multi-version eggs.


For debugging purposes, my lib/python/Zope2/Startup/zopectl.py
contains:

import pkg_resources
pkg_resources.require('sqlalchemy==0.4.2p3')
pkg_resources.require('z3c.sqlalchemy==1.1.0')
import sqlalchemy
print sqlalchemy.__version__
import z3c.sqlalchemy
from z3c.sqlalchemy.interfaces import ISQLAlchemyWrapper


This works nicely. The correct modules are imported properly.

Later during the startup phase while initializing a product called 
MedienDB the related code is doing the following import:


from z3c.sqlalchemy.interfaces import ISQLAlchemyWrapper

This import fails with

portError: 'No module named sqlalchemy.interfaces'

/local/HRS2/Devel/ajung/HaufeCMS/lib/python/mediendb/mediendb.py(19)?()

- from z3c.sqlalchemy.interfaces import ISQLAlchemyWrapper

although the same import worked much earlier?

Any ideas? As said: this issue only occurs with multi-version eggs.

Andreas


--
ZOPYX Ltd.  Co. KG - Charlottenstr. 37/1 - 72070 Tübingen - Germany
Web: www.zopyx.com - Email: [EMAIL PROTECTED] - Phone +49 - 7071 - 793376
Registergericht: Amtsgericht Stuttgart, Handelsregister A 381535
Geschäftsführer/Gesellschafter: ZOPYX Limited, Birmingham, UK

E-Publishing, Python, Zope  Plone development, Consulting


pgp8Ghs94qHf3.pgp
Description: PGP signature
___
Zope-Dev maillist  -  Zope-Dev@zope.org
http://mail.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope )


Re: [ZWeb] Would someone publish my ZSP document please

2008-01-15 Thread Sascha Welter
(Tue, Jan 15, 2008 at 10:57:00AM +0100) Michael Haubenwallner 
wrote/schrieb/egrapse:
  [1] http://www.zope.org/Resources/ZSP/
  
 
 We have hit a hardcoded limit again, collection size is at 300 atm.
 I'll check with one of the powers.

Looking through the list I notice that we can throw out Network AG
(Location Schlieren, Switzerland), Website: http://www.network-ag.com/
Profile: http://www.zope.org/Resources/ZSP/NetworkAG
- I used to work there, until the company went bancrupt a few years ago
(in 2004 IIRC).

Regards,

Sascha

___
Zope-web maillist  -  Zope-web@zope.org
http://mail.zope.org/mailman/listinfo/zope-web


[Zope] Zope ZMI Templates

2008-01-15 Thread Jurian Botha

I'm currently developing some customized ZMI pages and I was hoping someone
could give me some insight into what the best way would be to do this.

I see that Zope 2 uses dtml methods to build the standard ZMI pages but as
far as I know (Zope 3 wise) I should rather be using Zope Page Templates to
build the pages.

I would also like the product to gracefully move on to Zope 3 in future, so
that should be taken into consideration as well.

Are there perhaps some existsing templates for ZMI that can also be used
with Zope 3?
-- 
View this message in context: 
http://www.nabble.com/Zope-ZMI-Templates-tp14734109p14734109.html
Sent from the Zope - General mailing list archive at Nabble.com.

___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )


Re: [Zope] Zope ZMI Templates

2008-01-15 Thread Peter Bengtsson
I would strongly advice against building on top of the ZMI. It's dated 
and as you say, in DTML. It's also too geeky to be acceptable by any 
client of mine.
Personally I'd build something standalone that you have ultimate control 
over. You can still use things like manage_renameObjects() in your own 
mnagement interface; which you'd be able to replace once you move to zope 3.


Jurian Botha wrote:

I'm currently developing some customized ZMI pages and I was hoping someone
could give me some insight into what the best way would be to do this.

I see that Zope 2 uses dtml methods to build the standard ZMI pages but as
far as I know (Zope 3 wise) I should rather be using Zope Page Templates to
build the pages.

I would also like the product to gracefully move on to Zope 3 in future, so
that should be taken into consideration as well.

Are there perhaps some existsing templates for ZMI that can also be used
with Zope 3?


--
Peter Bengtsson,
work www.fry-it.com
home www.peterbe.com
hobby www.issuetrackerproduct.com
___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
http://mail.zope.org/mailman/listinfo/zope-announce

http://mail.zope.org/mailman/listinfo/zope-dev )


[Zope] Re: Zope ZMI Templates

2008-01-15 Thread Tres Seaver
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Jurian Botha wrote:
 I'm currently developing some customized ZMI pages and I was hoping someone
 could give me some insight into what the best way would be to do this.
 
 I see that Zope 2 uses dtml methods to build the standard ZMI pages but as
 far as I know (Zope 3 wise) I should rather be using Zope Page Templates to
 build the pages.
 
 I would also like the product to gracefully move on to Zope 3 in future, so
 that should be taken into consideration as well.
 
 Are there perhaps some existsing templates for ZMI that can also be used
 with Zope 3?

You could choose to use a 'zmi_master' template which looked like so::

 metal:x metal:define-macro=master
 tal:x tal:replace=structure context/manage_page_header /
 tal:x tal:replace=structure context/manage_tabs /
 div metal:define-slot=main
   Non-boilerplate goes here.
 /div
 tal:x tal:replace=structure context/manage_page_footer /
 /metal:x

If you registered that template as a view in your product's
'configure.zcml', e.g.:

  browser:page
 for=*
 name=zmi_master
 template=zmi_master.pt
 /

you can then use it in your own ZMI templates, e.g.:

  html metal:use-macro=context/@@zmi_master/macros/master
  body
  div metal:fill-slot=main
   h1 Test ZMI Macro /h1
  /div
  /body
  /html

I have attached a tarball of a simple Zope2 product which does this.
After installation, you should be able to visit
http://localhost:8080/zmi_test to see the results.


Tres.
- --
===
Tres Seaver  +1 540-429-0999  [EMAIL PROTECTED]
Palladion Software   Excellence by Designhttp://palladion.com
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFHjQMy+gerLs4ltQ4RAvHpAJ4h8VuFM3M4v333UU4jB71CJgvNqgCfcnjf
YMSO8d3hiDf5eMyG31nn9Ng=
=fh+F
-END PGP SIGNATURE-


zmi3.tar.gz
Description: application/gzip
___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )


Re: [Zope] Re: Zope ZMI Templates

2008-01-15 Thread Garito
Hi again, Tres!
Can you point as where we can find this kind of help? Are there some
reference manual or similar? (I'm using Zope2) Perhaps on Five manual?

Thanks a lot!

2008/1/15, Tres Seaver [EMAIL PROTECTED]:

 -BEGIN PGP SIGNED MESSAGE-
 Hash: SHA1

 Jurian Botha wrote:
  I'm currently developing some customized ZMI pages and I was hoping
 someone
  could give me some insight into what the best way would be to do this.
 
  I see that Zope 2 uses dtml methods to build the standard ZMI pages but
 as
  far as I know (Zope 3 wise) I should rather be using Zope Page Templates
 to
  build the pages.
 
  I would also like the product to gracefully move on to Zope 3 in future,
 so
  that should be taken into consideration as well.
 
  Are there perhaps some existsing templates for ZMI that can also be used
  with Zope 3?

 You could choose to use a 'zmi_master' template which looked like so::

 metal:x metal:define-macro=master
 tal:x tal:replace=structure context/manage_page_header /
 tal:x tal:replace=structure context/manage_tabs /
 div metal:define-slot=main
Non-boilerplate goes here.
 /div
 tal:x tal:replace=structure context/manage_page_footer /
 /metal:x

 If you registered that template as a view in your product's
 'configure.zcml', e.g.:

   browser:page
  for=*
  name=zmi_master
  template=zmi_master.pt
  /

 you can then use it in your own ZMI templates, e.g.:

   html metal:use-macro=context/@@zmi_master/macros/master
   body
   div metal:fill-slot=main
h1 Test ZMI Macro /h1
   /div
   /body
   /html

 I have attached a tarball of a simple Zope2 product which does this.
 After installation, you should be able to visit
 http://localhost:8080/zmi_test to see the results.


 Tres.
 - --
 ===
 Tres Seaver  +1 540-429-0999  [EMAIL PROTECTED]
 Palladion Software   Excellence by Designhttp://palladion.com
 -BEGIN PGP SIGNATURE-
 Version: GnuPG v1.4.6 (GNU/Linux)
 Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

 iD8DBQFHjQMy+gerLs4ltQ4RAvHpAJ4h8VuFM3M4v333UU4jB71CJgvNqgCfcnjf
 YMSO8d3hiDf5eMyG31nn9Ng=
 =fh+F
 -END PGP SIGNATURE-

 ___
 Zope maillist  -  Zope@zope.org
 http://mail.zope.org/mailman/listinfo/zope
 **   No cross posts or HTML encoding!  **
 (Related lists -
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )





-- 
Mis Cosas
http://blogs.sistes.net/Garito
Zope Smart Manager
http://blogs.sistes.net/Garito/670
___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )


[Zope] Re: Zope ZMI Templates

2008-01-15 Thread Tres Seaver
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Garito wrote:
 Hi again, Tres!
 Can you point as where we can find this kind of help? Are there some
 reference manual or similar? (I'm using Zope2) Perhaps on Five manual?

I'm afraid I don't know the docs very well:  I tend to use the source
when memory fails me. ;)  Honestly, I typed those examples in off the
top of my head, and then created the product to test them:  except for a
single typo, it Just Worked (TM).



Tres.
- --
===
Tres Seaver  +1 540-429-0999  [EMAIL PROTECTED]
Palladion Software   Excellence by Designhttp://palladion.com
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFHjRoC+gerLs4ltQ4RAsF9AJ9g5kghDMORCsHeD6bM391MuGpLKwCg0erV
+9TiFSIzjeSwRGpz720sDGQ=
=CytP
-END PGP SIGNATURE-

___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )


Re: [Zope] Zope ZMI Templates

2008-01-15 Thread Tim Nash
Jurian,
  While the ZMI is a bit geeky for the average user, it works quite
well inside an iframe.
iframes are used by many ajax/web2 (whatever you want to call it)
libraries. So in my application (for example) I currently make ajax
calls to load specific zmi pages inside tabs of a window layout.

I agree with Peter that you are better off building your own interface
(if you are going to expose the manage_* methods) but I personally
hope the zmi stays around for a while!
Tim


On Jan 15, 2008 11:02 AM, Peter Bengtsson [EMAIL PROTECTED] wrote:
 I would strongly advice against building on top of the ZMI. It's dated
 and as you say, in DTML. It's also too geeky to be acceptable by any
 client of mine.
 Personally I'd build something standalone that you have ultimate control
 over. You can still use things like manage_renameObjects() in your own
 mnagement interface; which you'd be able to replace once you move to zope 3.

 Jurian Botha wrote:
  I'm currently developing some customized ZMI pages and I was hoping someone
  could give me some insight into what the best way would be to do this.
 
  I see that Zope 2 uses dtml methods to build the standard ZMI pages but as
  far as I know (Zope 3 wise) I should rather be using Zope Page Templates to
  build the pages.
 
  I would also like the product to gracefully move on to Zope 3 in future, so
  that should be taken into consideration as well.
 
  Are there perhaps some existsing templates for ZMI that can also be used
  with Zope 3?

 --
 Peter Bengtsson,
 work www.fry-it.com
 home www.peterbe.com
 hobby www.issuetrackerproduct.com

 ___
 Zope maillist  -  Zope@zope.org
 http://mail.zope.org/mailman/listinfo/zope
 **   No cross posts or HTML encoding!  **
 (Related lists -
  http://mail.zope.org/mailman/listinfo/zope-announce
  http://mail.zope.org/mailman/listinfo/zope-dev )

___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )


[Zope] lambda's in external methods

2008-01-15 Thread David Bear
In the zope 2.7 book it mentions that an optimization technique for
external methods is to compile regular expressions in global scope to
the module. The re's will then be compiled at zope load time.

I am wondering if the same holds for lambdas. I created some simple
filters using lambdas. I defined them in the functions where I use
them. Is there any advantage to defining them globally to the module?

Are there any gottcha's with globally scope objects?

-- 
David Bear
phone:  602-496-0424
fax:602-496-0955
College of Public Programs/ASU
University Center Rm 622
411 N Central
Phoenix, AZ 85007-0685
 Beware the IP portfolio, everyone will be suspect of trespassing
___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )