Python 2.4.4 crashes inside a turbogears project

B

bulgaro

Hi everybody.
I hope not to be OT but this is a python problem, not a turbogears
one.
I have a problem when starting a turbogears project.
In my model.py i import an api to work with a db which imports a pyd
library.
It gives me this output:

C:\Turbogears>python start-traffic.py dev.cfg
2007-12-11 09:52:52,701 traffic.controllers DEBUG New session
--------------------------------
2007-12-11 09:52:52,701 traffic.controllers DEBUG New session
--------------------------------
sys:1: DeprecationWarning: Non-ASCII character '\x90' in file C:
\Python24\python.exe on line 1, but no encoding declared; see
http://www.python.org/peps/pep-0263.html for details
File "C:\Python24\python.exe", line 1
MZÉ$,000$0 0☺ö~
^
SyntaxError: invalid syntax
2007-12-11 09:52:54,224 cherrypy.msg INFO ENGINE: SystemExit raised:
shutting down autoreloader
2007-12-11 09:52:54,224 cherrypy.msg INFO HTTP: HTTP Server shut down
2007-12-11 09:52:54,234 turbogears.identity INFO Identity shutting
down
2007-12-11 09:52:54,234 cherrypy.msg INFO ENGINE: CherryPy shut down

It looks like it reads the binary file python.exe
I know this is probably a python error but i can't find any solution.
I use python 2.4.4.
Any clue?
Thank you in advance.
 
T

Terry Reedy

| I hope not to be OT but this is a python problem, not a turbogears one.

What you have shown is not a crash but a planned shutdown in response to an
error. There is a difference ;-). It is almost certainly not a problem
with the CPython interpreter but with your program or something else.

| I have a problem when starting a turbogears project.
| In my model.py i import an api to work with a db which imports a pyd
| library.

If it 'imports' (in the Python sense) something that is neither Python code
or a compiled version thereof, that would explain the message below.

| It gives me this output:
|
| C:\Turbogears>python start-traffic.py dev.cfg
| 2007-12-11 09:52:52,701 traffic.controllers DEBUG New session
| --------------------------------
| 2007-12-11 09:52:52,701 traffic.controllers DEBUG New session
| --------------------------------
| sys:1: DeprecationWarning: Non-ASCII character '\x90' in file C:
| \Python24\python.exe on line 1, but no encoding declared; see
| http://www.python.org/peps/pep-0263.html for details
| File "C:\Python24\python.exe", line 1
| MZÉ$,000$0 0?ö~
| ^
| SyntaxError: invalid syntax

Sometime is trying to read python.exe as Python code. It is not.

| 2007-12-11 09:52:54,224 cherrypy.msg INFO ENGINE: SystemExit raised:
| shutting down autoreloader
| 2007-12-11 09:52:54,224 cherrypy.msg INFO HTTP: HTTP Server shut down
| 2007-12-11 09:52:54,234 turbogears.identity INFO Identity shutting
| down
| 2007-12-11 09:52:54,234 cherrypy.msg INFO ENGINE: CherryPy shut down
|
| It looks like it reads the binary file python.exe
| I know this is probably a python error but i can't find any solution.

Don't do that.

tjr
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,744
Messages
2,569,480
Members
44,900
Latest member
Nell636132

Latest Threads

Top