[Zope-Checkins] SVN: Zope/trunk/ Integrate Zope 3-based exception views. Patch by Sidnei, integration
Log message for revision 77459: Integrate Zope 3-based exception views. Patch by Sidnei, integration work done for Infrae. Changed: U Zope/trunk/doc/CHANGES.txt U Zope/trunk/lib/python/Zope2/App/startup.py A Zope/trunk/lib/python/Zope2/App/tests/ A Zope/trunk/lib/python/Zope2/App/tests/__init__.py A Zope/trunk/lib/python/Zope2/App/tests/testExceptionHook.py U Zope/trunk/lib/python/zExceptions/__init__.py U Zope/trunk/lib/python/zExceptions/unauthorized.py -=- Modified: Zope/trunk/doc/CHANGES.txt === --- Zope/trunk/doc/CHANGES.txt 2007-07-05 13:34:33 UTC (rev 77458) +++ Zope/trunk/doc/CHANGES.txt 2007-07-05 14:35:49 UTC (rev 77459) @@ -100,6 +100,27 @@ - AccessControl: the form behind the Security tab has a new form for user-related reporting of permissions and roles + - Zope 3-based exception views can now be registered in ZCML for +various exceptions that can be raised by Zope. Registering an +exception view can be done like this: + + browser:page +for=zope.publisher.interfaces.INotFound +class=.view.SomeView +name=index.html +permission=zope.Public / + +Relevant exceptions that can have views are: + +zope.interface.common.interfaces.IException +zope.publisher.interfaces.INotFound +zope.security.interfaces.IForbidden +zope.security.interfaces.IUnauthorized + +Note that the name has to be 'index.html' for the exception +view to work. (patch by Sidnei da Silva from Enfold, +integration by Martijn Faassen (Startifact) for Infrae) + Bugs Fixed - Collector #1306: Missing acquisition context on local roles screen. Modified: Zope/trunk/lib/python/Zope2/App/startup.py === --- Zope/trunk/lib/python/Zope2/App/startup.py 2007-07-05 13:34:33 UTC (rev 77458) +++ Zope/trunk/lib/python/Zope2/App/startup.py 2007-07-05 14:35:49 UTC (rev 77459) @@ -13,6 +13,7 @@ Initialize the Zope2 Package and provide a published module +from zope.component import queryMultiAdapter from AccessControl.SecurityManagement import getSecurityManager from AccessControl.SecurityManagement import newSecurityManager from AccessControl.SecurityManagement import noSecurityManager @@ -20,7 +21,7 @@ from App.config import getConfiguration from time import asctime from types import StringType, ListType -from zExceptions import Unauthorized +from zExceptions import Unauthorized, Redirect from ZODB.POSException import ConflictError import transaction import AccessControl.User @@ -37,6 +38,8 @@ import Zope2 import ZPublisher +app = None +startup_time = asctime() def startup(): global app @@ -132,100 +135,124 @@ ) Zope2.DB.removeVersionPool(version) raise Unauthorized, You don't have permission to enter versions. - + class RequestContainer(ExtensionClass.Base): def __init__(self,r): self.REQUEST=r -conflict_errors = 0 -unresolved_conflict_errors = 0 +class ZPublisherExceptionHook: -conflict_logger = logging.getLogger('ZPublisher.Conflict') +def __init__(self): +self.conflict_errors = 0 +self.unresolved_conflict_errors = 0 +self.conflict_logger = logging.getLogger('ZPublisher.Conflict') +self.error_message = 'standard_error_message' +self.raise_error_message = 'raise_standardErrorMessage' -def zpublisher_exception_hook(published, REQUEST, t, v, traceback): -global unresolved_conflict_errors -global conflict_errors -try: -if isinstance(t, StringType): -if t.lower() in ('unauthorized', 'redirect'): -raise -else: -if t is SystemExit: -raise -if issubclass(t, ConflictError): -conflict_errors += 1 -level = getConfiguration().conflict_error_log_level -if level: -conflict_logger.log(level, -%s at %s: %s (%d conflicts (%d unresolved) -since startup at %s), -v.__class__.__name__, -REQUEST.get('PATH_INFO', 'unknown'), -v, -conflict_errors, -unresolved_conflict_errors, -startup_time) -raise ZPublisher.Retry(t, v, traceback) -if t is ZPublisher.Retry: -try: -v.reraise() -except: -# we catch the re-raised exception so that it gets -# stored in the error log and gets rendered with -# standard_error_message -t, v, traceback = sys.exc_info() -if issubclass(t, ConflictError): -
[Zope-Checkins] SVN: zdaemon/branches/jim-env/ retire old dev branch
Log message for revision 77463: retire old dev branch Changed: D zdaemon/branches/jim-env/ -=- ___ Zope-Checkins maillist - Zope-Checkins@zope.org http://mail.zope.org/mailman/listinfo/zope-checkins
[Zope-Checkins] SVN: zdaemon/branches/tseaver-eggification/ retire old dev branch
Log message for revision 77462: retire old dev branch Changed: D zdaemon/branches/tseaver-eggification/ -=- ___ Zope-Checkins maillist - Zope-Checkins@zope.org http://mail.zope.org/mailman/listinfo/zope-checkins
[Zope-dev] Fix for request must be post at Take Ownership
Hello, When do you plan to add the fix for request must be post at Take Ownership to a stable zope 2.10 release? It seems like this bug has been introduced with zope 2.10.2 or 2.10.3. An example of the bug can be found at http://zope.pastey.net/56726 It seems like you already submitted a fix to the svn trunk, see http://mail.zope.org/pipermail/zope-checkins/2007-March/032104.html But unfortunately this didn't went into a stable release yet. So my question is, do you plan to add this fix to the next zope2.10 stable release? greetings, jonas -- In post-historical society, the rulers have ceased to rule, but the slaves remain slaves. - Perry Anderson ___ 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] Fix for request must be post at Take Ownership
On 05/07/2007 Stefan H. Holek wrote: I may be missing something here, but the fact that you have to use POST is fully intentional and not a bug. Yes, but it seems like this is not the case for the module AccessControl. It uses GET and therefore produces a bug. That's what the patch from http://mail.zope.org/pipermail/zope-checkins/2007-March/032104.html seems to fix. My only question is when this patch will be merged into a stable 2.10 release. greetings, jonas -- In post-historical society, the rulers have ceased to rule, but the slaves remain slaves. - Perry Anderson ___ 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] Fix for request must be post at Take Ownership
I may be missing something here, but the fact that you have to use POST is fully intentional and not a bug. Stefan On 5. Jul 2007, at 11:27, Jonas Meurer wrote: When do you plan to add the fix for request must be post at Take Ownership to a stable zope 2.10 release? It seems like this bug has been introduced with zope 2.10.2 or 2.10.3. An example of the bug can be found at http://zope.pastey.net/56726 -- Anything that, in happening, causes something else to happen, causes something else to happen. --Douglas Adams ___ 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
Summary of messages to the zope-tests list. Period Wed Jul 4 12:00:00 2007 UTC to Thu Jul 5 12:00:00 2007 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: Wed Jul 4 20:53:13 EDT 2007 URL: http://mail.zope.org/pipermail/zope-tests/2007-July/007983.html Subject: OK : Zope-2.8 Python-2.3.6 : Linux From: Zope Unit Tests Date: Wed Jul 4 20:54:44 EDT 2007 URL: http://mail.zope.org/pipermail/zope-tests/2007-July/007984.html Subject: OK : Zope-2.9 Python-2.4.4 : Linux From: Zope Unit Tests Date: Wed Jul 4 20:56:24 EDT 2007 URL: http://mail.zope.org/pipermail/zope-tests/2007-July/007985.html Subject: OK : Zope-2.10 Python-2.4.4 : Linux From: Zope Unit Tests Date: Wed Jul 4 20:57:55 EDT 2007 URL: http://mail.zope.org/pipermail/zope-tests/2007-July/007986.html Subject: OK : Zope-trunk Python-2.4.4 : Linux From: Zope Unit Tests Date: Wed Jul 4 20:59:26 EDT 2007 URL: http://mail.zope.org/pipermail/zope-tests/2007-July/007987.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 )
Re: [Zope-dev] Fix for request must be post at Take Ownership
--On 5. Juli 2007 14:24:30 +0200 Jonas Meurer [EMAIL PROTECTED] wrote: On 05/07/2007 Stefan H. Holek wrote: I may be missing something here, but the fact that you have to use POST is fully intentional and not a bug. Yes, but it seems like this is not the case for the module AccessControl. It uses GET and therefore produces a bug. That's what the patch from http://mail.zope.org/pipermail/zope-checkins/2007-March/032104.html seems to fix. My only question is when this patch will be merged into a stable 2.10 release. As far as I can see the patch has been applied to the Z.10 branch in a slight different form using a @postonly decorator. -aj pgp2lDlShWcvs.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 )
[Zope-dev] Re: Fix for request must be post at Take Ownership
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Jonas Meurer wrote: Hello, When do you plan to add the fix for request must be post at Take Ownership to a stable zope 2.10 release? It seems like this bug has been introduced with zope 2.10.2 or 2.10.3. An example of the bug can be found at http://zope.pastey.net/56726 It seems like you already submitted a fix to the svn trunk, see http://mail.zope.org/pipermail/zope-checkins/2007-March/032104.html But unfortunately this didn't went into a stable release yet. So my question is, do you plan to add this fix to the next zope2.10 stable release? The pastebin output above doesn't explain why you think Zope's behavior is a bug: it shows an attempt to call 'manage_takeOwnership' using a non-POST method, which is no longer allowed after the 'postonly' changes. Those changes landed for Zope 2.10.3: http://svn.zope.org/Zope/tags/2.10.3/lib/python/AccessControl/Owned.py 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 iD8DBQFGjQzN+gerLs4ltQ4RAuUMAKCtaeYH8wGlnEZldVqjy0SJBK5vFQCgwL8L tWsNSDUQuKqNF70Fm5Pk/j4= =9xm8 -END 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 )
[Zope-dev] Zope 2.11.0b1 plans
Hi, now that Zope 3.4.0b1 has been tagged, I plan to release Zope 2.11.0b1 by mid-July. Objections? 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 pgp6RxKgejViv.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: [Zope-dev] Zope 2.11.0b1 plans
Will there not be an alpha? On Jul 5, 2007, at 3:23 PM, Andreas Jung wrote: Hi, now that Zope 3.4.0b1 has been tagged, I plan to release Zope 2.11.0b1 by mid-July. Objections? 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 ___ 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 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: Zope 2.11.0b1 plans
Andreas Jung wrote: now that Zope 3.4.0b1 has been tagged, I plan to release Zope 2.11.0b1 by mid-July. Objections? Like Chris, I'd rather have one or two alphas first. Why not make an alpha mid-July and perhaps a beta at the end of July? -- http://worldcookery.com -- Professional Zope documentation and training ___ 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] Logon process
Hi all! I've developed a site that if you are not logged in renders in a way but if you are logged in renders in another way (with more functionality) I would like to create a logon form and the validate the user in an AJAX way Where can I read about it? Or where the acl_users code is located? I would like to avoid the use of alternatives acl_users products if possible because I would like to store users on the ZODB normaly as original acl_users object do (I don't need ExUserFolder or similar if possible) Thanks! -- Mis Cosas http://blogs.sistes.net/Garito ___ 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] [ANN] Zope 2.10.4 and Zope 2.9.8 released
The Zope developer community is pleased to announce two new Zope releases: 2.9.8 and 2.10.4 You can download the releases from: http://www.zope.org/Products/Zope/2.9.8/ http://www.zope.org/Products/Zope/2.10.4/ The release notes are available directly from the links above. All releases are bugfix releases and include the hotfix published some days ago: http://www.zope.org/Products/Zope/Hotfix-2007-03-20 - -- Andreas Jung -- 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 pgpYeIbIOqXKn.pgp Description: 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] Logon process
Not sure if it's exactly what you're looking for but you may want to check out the Cookie Crumbler product. http://packages.debian.org/stable/source/zope-cookiecrumbler On Jul 5, 2007, at 2:41 AM, Garito wrote: Hi all! I've developed a site that if you are not logged in renders in a way but if you are logged in renders in another way (with more functionality) I would like to create a logon form and the validate the user in an AJAX way Where can I read about it? Or where the acl_users code is located? I would like to avoid the use of alternatives acl_users products if possible because I would like to store users on the ZODB normaly as original acl_users object do (I don't need ExUserFolder or similar if possible) Thanks! -- Mis Cosas http://blogs.sistes.net/Garito ___ 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] Re: Fix for request must be post at Take Ownership
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Jonas Meurer wrote: Hello, When do you plan to add the fix for request must be post at Take Ownership to a stable zope 2.10 release? It seems like this bug has been introduced with zope 2.10.2 or 2.10.3. An example of the bug can be found at http://zope.pastey.net/56726 It seems like you already submitted a fix to the svn trunk, see http://mail.zope.org/pipermail/zope-checkins/2007-March/032104.html But unfortunately this didn't went into a stable release yet. So my question is, do you plan to add this fix to the next zope2.10 stable release? The pastebin output above doesn't explain why you think Zope's behavior is a bug: it shows an attempt to call 'manage_takeOwnership' using a non-POST method, which is no longer allowed after the 'postonly' changes. Those changes landed for Zope 2.10.3: http://svn.zope.org/Zope/tags/2.10.3/lib/python/AccessControl/Owned.py 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 iD8DBQFGjQzN+gerLs4ltQ4RAuUMAKCtaeYH8wGlnEZldVqjy0SJBK5vFQCgwL8L tWsNSDUQuKqNF70Fm5Pk/j4= =9xm8 -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] Logon process
Thanks, I try to use a more easy solution but it's ok I check this and ExUserFolder but in both cases I don't understand the product's setup process Do you know where I can found a tutorial about how to setup and use Cookie Crumbler product? Thanks again! 2007/7/5, Tom Von Lahndorff [EMAIL PROTECTED]: Not sure if it's exactly what you're looking for but you may want to check out the Cookie Crumbler product. http://packages.debian.org/stable/source/zope-cookiecrumbler On Jul 5, 2007, at 2:41 AM, Garito wrote: Hi all! I've developed a site that if you are not logged in renders in a way but if you are logged in renders in another way (with more functionality) I would like to create a logon form and the validate the user in an AJAX way Where can I read about it? Or where the acl_users code is located? I would like to avoid the use of alternatives acl_users products if possible because I would like to store users on the ZODB normaly as original acl_users object do (I don't need ExUserFolder or similar if possible) Thanks! -- Mis Cosas http://blogs.sistes.net/Garito ___ 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 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] Logon process
Thanks, I try to use a more easy solution but it's ok I check this and ExUserFolder but in both cases I don't understand the product's setup process Do you know where I can found a tutorial about how to setup and use Cookie Crumbler product? I think you should rather take a look at PAS - PluggableAuthService and possibly just write your own plugin. There is Zope-PAS mailing list too. You may take a look at docs/ and interfaces in this package. Default PAS plugins include ZODB users storage and cookie authentication. -- Maciej Wisniowski ___ 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-DB] Migration from Windows to Linux. How to do it?
I am newbie and sorry for if I ask too simple question. I have designed my Plone site on my localhost (Windows server) machine. Then I need to move my real Zope and Plone server running on the Linux machine. How do I to do this? My both Windows and Linux config is following: Plone port: 80 Zope port: 8080 originally works fine on the each OSs before the migration. I have tried and copied only Data.fs file from Windows to Linux machines related /var/opt/zope/default/var/ folder. Then I have problem with my Plone server running instead Zope of port number 8080. I would really appreciate it if you could help me any of suggestion. - Park yourself in front of a world of choices in alternative vehicles. Visit the Yahoo! Auto Green Center.___ Zope-DB mailing list Zope-DB@zope.org http://mail.zope.org/mailman/listinfo/zope-db