这个问题在这里已有答案:
我如何解决这个问题。它是在脚本即时使用或它在Python.Im使用Debian OS并尝试安装此代码https://github.com/rkubik/paypark
Traceback (most recent call last):
File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 2309, in __call__
return self.wsgi_app(environ, start_response)
File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 2295, in wsgi_app
response = self.handle_exception(e)
File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1741, in handle_exception
reraise(exc_type, exc_value, tb)
File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 2292, in wsgi_app
response = self.full_dispatch_request()
File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1815, in full_dispatch_request
rv = self.handle_user_exception(e)
File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1718, in handle_user_exception
reraise(exc_type, exc_value, tb)
File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1813, in full_dispatch_request
rv = self.dispatch_request()
File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1799, in dispatch_request
return self.view_functions[rule.endpoint](**req.view_args)
File "/var/paypark/paypark/frontend/auth.py", line 14, in auth_login
if current_user.is_authenticated() or form.validate_on_submit():
TypeError: 'bool' object is not callable
我同意Artyer的观点。当方法更改为属性或反之亦然时会发生这种python问题,但并非所有调用代码都已经过验证并更改为匹配。我猜测它的Flask-Login已被更改,但您正在使用的代码的作者已经指出了2年没有更新任何内容。 current_user.is_authenticate()
是最可能的原因,一些挖掘,但改变两者或两者很快就会看到。您也可以找到其他实例。