Zac Brown Zac Brown - 1 year ago 93
Python Question

Python raw_input("") error

I am writing a simple commandline script that uses raw_input, but it doesn't seem to work.

This code:

print "Hello!"

Produces this error:

Traceback (most recent call last):
File "<pyshell#6>", line 1, in <module>
TypeError: 'str' object is not callable

I have never encountered this error before, and couldn't find anything on Google. I am using Python 2.6 on Windows 7.

Answer Source

It appears you are using something called pyshell. There is likely a bug there in that shell itself. Try just using vanilla bash.

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download