← Back to team overview

sikuli-driver team mailing list archive

Re: [Question #224359]: HowTo use Excel support (xlrd, xlwt, xlutils)

 

Question #224359 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/224359

cronay walls posted a new comment:
This error statement TypeError: 'module' object is not callable is
raised as you are being confused about the Class name and Module name.
The problem is in the import line . You are importing a module, not a
class. This happend because the module name and class name have the same
name .

If you have a class "MyClass" in a file called "MyClass.py" , then you should import :
 
from MyClass import MyClass

In Python , a script is a module, whose name is determined by the
filename . So when you start out your file MyClass.py with import
MyClass you are creating a loop in the module structure.

http://net-informations.com/python/iq/typeerror.htm

-- 
You received this question notification because your team Sikuli Drivers
is an answer contact for Sikuli.