a curious IDLE Error

Stephan Deibel sdeibel at wingide.com
Thu Jan 22 09:24:08 EST 2004


On Thu, 22 Jan 2004, EP wrote:
> At 08:02 AM 1/22/2004 +0000, Alan Gauld wrote:
> >On Wed, 21 Jan 2004 21:50:01 -0800, EP <EP at zomething.com> wrote:
> >
> > > I opened a new Python shell from the instance of IDLE editor where my
> > > module was open and tried the raw_input():
> > >
> > >  >>> someFile=raw_input("enter:  ")
> > > Traceback (most recent call last):
> > >    File "<pyshell#36>", line 1, in ?
> > >      someFile=raw_input("enter:  ")
> > > TypeError: 'tuple' object is not callable
> > >
> >
> >This is a long shot but is it possible that you used raw_input as
> >the name of a variable somewhere. Thus you are trying to call
> >that variable (which apparently holds a tuple!).
> >
> >Try doing a text search for raw_input in your module code.
> >
> >Just a thought.
> 
> 
> I thought it might have been something like that as well, but I checked all 
> my variable names (and I was only importing the string module).
> 
> The strange behavior was that the module worked, just not in an IDLE shell 
> opened up out of the same instance I created the module in. 

I'm guessing too (sorry) but it may be that IDLE doesn't have support for
properly redirection reads on stdin to the shell?  This comes to mind only
because we had to write special code to make this happen properly in Wing
IDE.

Stephan Deibel

--
Wing IDE for Python
Archaeopteryx Software, Inc
Take Flight!

www.wingide.com




More information about the Python-list mailing list