- 帖子
- 7
- 精华
- 0
- 积分
- 47
- 阅读权限
- 10
- 注册时间
- 2018-11-15
- 最后登录
- 2018-12-4
|
有点崩溃,第0课就遇到解决不了的问题,大神们帮忙看看
代码如下:
[size=16.6667px]import weburls = ('/', 'index')class index: def GET(self): return "Hello, world!"if __name__ == "__main__": app = web.application(urls, globals()) app.run()
报错如下:
Traceback (most recent call last):
File "D:\Program Files\Python37\lib\site-packages\web\utils.py", line 526, in take
yield next(seq)
StopIteration
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "D:/Program Files/Demo/Demo1.py", line 12, in <module>
app = web.application(urls, globals())
File "D:\Program Files\Python37\lib\site-packages\web\application.py", line 62, in __init__
self.init_mapping(mapping)
File "D:\Program Files\Python37\lib\site-packages\web\application.py", line 130, in init_mapping
self.mapping = list(utils.group(mapping, 2))
File "D:\Program Files\Python37\lib\site-packages\web\utils.py", line 531, in group
x = list(take(seq, size))
RuntimeError: generator raised StopIteration
|
|