TypeError:'tuple' object is not callable
(2013-01-12 16:06:53)
标签:
djangopydevtypeerrortuplecallableit |
分类: django |
urlpatterns = patterns('',
而我在运行的时候,从网页登录,输入网址:http://127.0.0.1:8000/time/,却出现如下错误:
TypeError at /time/
'tuple' object is not callable
| Request Method: | GET |
|---|---|
| Request URL: | http://127.0.0.1:8000/time/ |
| Django Version: | 1.4.1 |
| Exception Type: | TypeError |
| Exception Value: |
'tuple' object is not callable |
| Exception Location: | /home/liul/workspace/mysite/mysite/urls.py in , line 20 |
| Python Executable: | /usr/bin/python2.7 |
| Python Version: | 2.7.3 |
经过验证,原来是url中所填写的函数变量search和contact与python内部模块中的函数重名了,就会出现这种错误,所以改变这两个函数名或删掉他们就OK啦

加载中…