By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
448,679 Members | 1,063 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 448,679 IT Pros & Developers. It's quick & easy.

SQLAlchemy, py2exe and Python 2.5 problem?

P: n/a
I've just upgraded to Python 2.5, SQLAlchemy 0.3.3, and py2exe 0.6.5
(the py2.5 version, yes).

Simple:

---
import sqlalchemy
print 'Test'
---

works when interpreted by Python, but when running it from compiled
py2exe binary, it fails with this error:

Traceback (most recent call last):
File "main.py", line 1, in <module>
File "sqlalchemy\__init__.pyc", line 10, in <module>
File "sqlalchemy\orm\__init__.pyc", line 12, in <module>
File "sqlalchemy\orm\mapper.pyc", line 7, in <module>
File "sqlalchemy\logging.pyc", line 30, in <module>
ImportError: No module named logging

Ofcourse, library.zip (in the dist directory) contains 'sqlalchemy
\logging.pyc'. After I copy logging.pyc to library.zips' root, I get
this error:

Traceback (most recent call last):
File "main.py", line 1, in <module>
File "sqlalchemy\__init__.pyc", line 10, in <module>
File "sqlalchemy\orm\__init__.pyc", line 12, in <module>
File "sqlalchemy\orm\mapper.pyc", line 7, in <module>
File "sqlalchemy\logging.pyc", line 30, in <module>
File "sqlalchemy\logging.pyc", line 33, in <module>
AttributeError: 'module' object has no attribute 'getLogger'

Does anyone have a clue why this happens? And what is responsible for
this? SQLAlchemy, or py2exe?

Thanks in advance...

--
_______ Karlo Lozovina - Mosor
| | |.-----.-----. web: http://www.mosor.net || ICQ#: 10667163
| || _ | _ | Parce mihi domine quia Dalmata sum.
|__|_|__||_____|_____|
Dec 19 '06 #1
Share this question for a faster answer!
Share on Google+

This discussion thread is closed

Replies have been disabled for this discussion.