-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 07/07/2011 03:24 AM, Shane Hathaway wrote:
> On 07/06/2011 10:59 AM, Hanno Schlichting wrote:
>> The ZMI is a highly insecure, completely outdated and
>> user-unfriendly interface.
> 
> As I read this, I got an idea for a possible way forward.  I haven't
>  been reading zope-dev much lately, so forgive me if something like
> this has been mentioned already.
> 
> What if we had decorators that let us disable old code by default,
> yet allowed users to enable the old code with configuration?
> Something like this:
> 
> 
> import zope.oldcode
> 
> class SomeClass(SimpleObject):
> 
> @zope.oldcode.zmi def manage_edit(self, REQUEST): # ...
> 
> 
> The idea here is we'll create a zope.oldcode egg and fill it with 
> decorators for pervasive features of Zope that need to be removed
> over time, such as the current ZMI.  We'll also create a
> configuration switch for each of those old features so that people
> can keep using them for a reasonable period of time.  When the "zmi"
> feature is disabled, the code above will replace the manage_edit
> method with a "zope.oldcode.Disabled" object that raises a helpful
> exception if anyone tries to call it.
> 
> It would also be good to make these decorators implement __nonzero__
> to allow conditional attribute definition:
> 
> if zope.oldcode.zmi: manage_properties = (...)
> 
> I would want to make sure conditional tests are possible as well:
> 
> @zope.oldcode.zmi def test_manage_edit(self): # ...
> 
> (The zope.oldcode package probably ought to enable all old features
> by default when running tests.)
> 
> What do you think?

Neat -- sounds like an interesting thing to try a "spike" on, anyway.



Tres.
- -- 
===================================================================
Tres Seaver          +1 540-429-0999          tsea...@palladion.com
Palladion Software   "Excellence by Design"    http://palladion.com
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAk4WLuwACgkQ+gerLs4ltQ46IgCgivBo8ucn91ix8YlsYknNG7HB
+fcAn2wyEQoKNNpZ+yv5OXHi9vKmtiHh
=Dm5a
-----END PGP SIGNATURE-----

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

Reply via email to