Re: PyObjC 3.0.1 on PyPI

Marc Van Olmen <[email protected]> Sun, 27 Jul 2014 15:54:46 -0400
Newsgroups gmane.comp.python.pyobjc.devel,gmane.comp.python.apple
Message-ID <[email protected]>
On Jul 27, 2014, at 10:50 AM, Ronald Oussoren <[email protected]> wrote:
>> 
>> Remarks:
>> So far the release seems stable the only issue we had was that since the latest upgrade to pyobjc 3.0 of 2014-05-30. + Python 2.7.6
>> The startup time of our app was about 10 seconds longer. I haven't had the time yet to investigate what caused it but profiler indicated it was in gzip.
>> So I changed our packaging and distribute site-packages as unzipped and notice at 10 seconds startup speed up.
>> Hopefully in the coming months I have sometime to investigate what caused it.
> 
> The metadata system may be at fault here, although it is supposed to be faster than before. Do you use “from Foundation import *”?  It is highly advisable to avoid that because the framework wrapper modules lazily instantiate their contents and star-imports forces greedy initialisation. At least 3.0 should avoid the additional slowdown that was in 2.5 in the code that handles __all__.

no "from XYZ import *" in our project.


> BTW. According to one of the talks at EP14 translating your source code using Cython could help in startup time. They started looking into Cython to get obfuscated code (to make it harder to reverse engineer their application) and noticed some performance improvements as well. That’s with plain Python code and no Cython-specific annotations.  It would be cool to teach py2app to do this automatically and I have filed a feature request for that. I don’t know when I’ll get around to that though.
> 
> The talk: https://ep2014.europython.eu/en/schedule/sessions/31/  (video and slides are available).

Interesting will take a look at that.

marc
------------------------------------------------------------------------------
Want fast and easy access to all the code in your enterprise? Index and
search up to 200,000 lines of code with a free copy of Black Duck
Code Sight - the same software that powers the world's largest code
search on Ohloh, the Black Duck Open Hub! Try it now.
http://p.sf.net/sfu/bds