views:

41

answers:

1

Hi all,

I'm running a web crawler that gets called as a separate thread via Django. When it tries to store the scraped information I get this error:

File "/usr/lib/pymodules/python2.6/MySQLdb/cursors.py", line 147, in execute charset = db.character_set_name() InterfaceError: (0, '')

If I manually run the script from the command line I don't get this error. Any ideas?

My guess is that I do about 4 cursor.execute()s in one iteration of a loop. Could this be throwing something off?

Thanks!

A: 

Since it mentions the character set, my gut says you are running a different Django/Python/something from the command line than you are from the webserver. In your settings file, turn on DEBUG=True, restart the server, and then run this again. In particular, look at the list of paths shown. If they are not exactly what you expect them to be, then this is a Red Flag.

Peter Rowell