Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: Zope: Dev
A suggestion for changing exception handler when loading 'c' optimisations to make modules more friendly for GAE
 

Index | Next | Previous | View Flat


timh at zute

Jul 2, 2009, 5:39 PM


Views: 826
Permalink
A suggestion for changing exception handler when loading 'c' optimisations to make modules more friendly for GAE

Hi all

Can I make a suggestion that would make a couple of modules more gae
friendly ;-)
zope.interface and zope.i18nmessageid have 'c' optimisations which
obviously don't work under app engine.


When these modules are imported you get the following exception.

gae/1.333250465889549129/zope/i18nmessageid/_zope_i18nmessageid_message.py",
line 6, in __bootstrap__
imp.load_dynamic(__name__,__file__)
File "/base/python_dist/lib/python2.5/py_imp.py", line 116, in load_dynamic
raise NotImplementedError('This function is not supported on App Engine.')

Unfortunately the code (in this case in zope.i18nmessageid.Message)
does the following which doesn't deal with the Exception
raised by the app engine runtime.


try:
from _zope_i18nmessageid_message import Message
except ImportError:
pass

To make it more "gae friendly" I think we should change these occurrences to

try:
from _zope_i18nmessageid_message import Message
except ImportError, NotImplementedError:
pass

Regards

Tim
_______________________________________________
Zope-Dev maillist - Zope-Dev[at]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 )

Subject User Time
A suggestion for changing exception handler when loading 'c' optimisations to make modules more friendly for GAE timh at zute Jul 2, 2009, 5:39 PM
    Re: A suggestion for changing exception handler when loading 'c' optimisations to make modules more friendly for GAE tobias.rodaebel at mac Jul 3, 2009, 1:33 AM
    Re: A suggestion for changing exception handler when loading 'c' optimisations to make modules more friendly for GAE chris at simplistix Jul 3, 2009, 1:38 AM
        Re: A suggestion for changing exception handler when loading 'c' optimisations to make modules more friendly for GAE timh at zute Jul 3, 2009, 2:05 AM
        Re: A suggestion for changing exception handler when loading 'c' optimisations to make modules more friendly for GAE tobias.rodaebel at mac Jul 3, 2009, 2:05 AM
            Re: A suggestion for changing exception handler when loading 'c' optimisations to make modules more friendly for GAE chris at simplistix Jul 3, 2009, 2:09 AM
    Re: A suggestion for changing exception handler when loading 'c' optimisations to make modules more friendly for GAE jim at zope Jul 3, 2009, 3:04 AM
        Re: A suggestion for changing exception handler when loading 'c' optimisations to make modules more friendly for GAE timh at zute Jul 3, 2009, 3:25 AM
        Re: A suggestion for changing exception handler when loading 'c' optimisations to make modules more friendly for GAE tseaver at palladion Jul 3, 2009, 10:29 AM
            Re: A suggestion for changing exception handler when loading 'c' optimisations to make modules more friendly for GAE chrism at plope Jul 3, 2009, 1:44 PM
    Re: A suggestion for changing exception handler when loading 'c' optimisations to make modules more friendly for GAE jim at zope Jul 3, 2009, 3:33 AM
        Re: A suggestion for changing exception handler when loading 'c' optimisations to make modules more friendly for GAE tobias.rodaebel at mac Jul 3, 2009, 5:08 AM
            Re: A suggestion for changing exception handler when loading 'c' optimisations to make modules more friendly for GAE timh at zute Jul 3, 2009, 6:21 AM

  Index | Next | Previous | View Flat
 
 


Interested in having your list archived? Contact lists@gossamer-threads.com
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.