tags:

views:

134

answers:

1

I can import MySQLdb from the interactive python command line but Zope gives me an import error when I try it from within a script (python) in Zope. Could Zope be not looking in the same places as the command line for some reason?

A: 

It could be because of you have 2 versions of python, you could check with sys.executable

You could solve that by

  • changing Zope's python running environment to be match with your account environment
  • install MySQLdb for python version used by Zope
S.Mark
They are both using the same version of python. However, I'm using virtualenv to run zope. I think that might be a part of the problem.
offex