On 10/24/2011 04:12 AM, Ronald Oussoren wrote:
On 13 Oct, 2011, at 18:25, Sean Robinson wrote:
On 10/10/2011 07:44 AM, Sean Robinson wrote:
On 10/08/2011 07:36 AM, Ronald Oussoren wrote:
On 6 Oct, 2011, at 22:35, Sean Robinson wrote:
I believe I can overcome this error by finding the right path(s) to
append to the app bundle's sys.path, but I'm surprised that py2app
does not do this automagically.
py2app should do this automaticly. What version of python do you use?
Is that a custom install or the system version of python? And finally,
which OSX version are you using?
This is on OSX 10.6.8, using the system version of Python 2.6.1. The
only non-standard packages/modules are py2app (0.6.4 pre-release and its
requirements) installed local to the user account. I am developing as
vanilla as I can get.
Ronald,
So, to follow-up... I have been able to create a working semi-standalone app
bundle (which is what I wanted) by adding two more dirs to sys.path. Thank you
for py2app and for your help. My app bundles work on 10.6.3 and 10.6.8 with
the default Apple-provided Python on each.
Attached to this message is a zip archive with two minimal projects (working
and not_working) which highlight the single difference which allows AppKit to
be imported. Each project is three lines of python plus the setup.py created
by py2applet. IHTH.
That was a pretty lame bug: when using the system build of Python we don't include Python
and the "standard" library into the application bundle, including the extra
libraries like PyObjC and wxWidgets. That part worked fine, but py2app never made sure
that the directory with extra libraries was available on sys.path and that causes the
problem you're having.
I've pushed a fix for that to the repository, and will push a new release to
PyPI later today.
This morning, I removed my explicit additions to sys.path within my
project and I tested creating an app bundle using py2app from the
repository (changeset 179:5e27e7b0b17d). Everything tests well. AppKit
and the rest of PyObjC is imported correctly when the app bundle is
launched.
Thank you, again, for your maintenance and improvement of py2app.
--
Sean Robinson
Laboratory Technician
Physics Astronomy Geology
sean.robin...@sccmail.maricopa.edu
_______________________________________________
Pythonmac-SIG maillist - Pythonmac-SIG@python.org
http://mail.python.org/mailman/listinfo/pythonmac-sig
unsubscribe: http://mail.python.org/mailman/options/Pythonmac-SIG