Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

运行这一步时候报错 curl -X POST localhost:1235/parse -d '{"q":"我的流量还剩多少"}' | python -m json.tool请大神帮帮忙看看 #35

Open
a461925358 opened this issue May 15, 2019 · 4 comments

Comments

@a461925358
Copy link

2019-05-15 11:15:37+0800 [-] Unhandled Error
Traceback (most recent call last):
File "D:\anaconda\envs\rasa\lib\site-packages\twisted\web\server.py", line 259, in render
body = resrc.render(self)
File "D:\anaconda\envs\rasa\lib\site-packages\klein\resource.py", line 210, in render
d = defer.maybeDeferred(_execute)
File "D:\anaconda\envs\rasa\lib\site-packages\twisted\internet\defer.py", line 151, in maybeDeferred
result = f(*args, **kw)
File "D:\anaconda\envs\rasa\lib\site-packages\klein\resource.py", line 204, in _execute
**kwargs)
--- ---
File "D:\anaconda\envs\rasa\lib\site-packages\twisted\internet\defer.py", line 151, in maybeDeferred
result = f(*args, **kw)
File "D:\anaconda\envs\rasa\lib\site-packages\klein\app.py", line 128, in execute_endpoint
return endpoint_f(self._instance, *args, **kwargs)
File "D:\anaconda\envs\rasa\lib\site-packages\klein\app.py", line 227, in _f
return _call(instance, f, request, *a, **kw)
File "D:\anaconda\envs\rasa\lib\site-packages\klein\app.py", line 50, in _call
result = f(*args, **kwargs)
File "E:/Rasa/rasa_chatbot-master/httpserver.py", line 28, in save_item
data = json.loads(data_string)
File "D:\anaconda\envs\rasa\lib\json_init
.py", line 354, in loads
return _default_decoder.decode(s)
File "D:\anaconda\envs\rasa\lib\json\decoder.py", line 339, in decode
obj, end = self.raw_decode(s, idx=_w(s, 0).end())
File "D:\anaconda\envs\rasa\lib\json\decoder.py", line 357, in raw_decode
raise JSONDecodeError("Expecting value", s, err.value) from None
json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)

2019-05-15 11:15:37+0800 [-] "127.0.0.1" - - [15/May/2019:03:15:37 +0000] "POST /parse HTTP/1.1" 500 7650 "-" "curl/7.55.1"

@lida1997
Copy link

用postman

@l2009312042
Copy link

@lida1997 用postman也是报错 我用的是rasa nlu0.15版本

@lida1997
Copy link

lida1997 commented Jul 8, 2019

@lida1997 用postman也是报错 我用的是rasa nlu0.15版本

试试 0.12版本

@ly987
Copy link

ly987 commented Feb 17, 2021

你好,你的问题解决了吗,我的request.content.read().decode('utf-8', 'strict')这句代码就开始报错了,builtins.UnicodeDecodeError: 'utf-8' codec can't decode byte 0xce in position 4: invalid continuation byte

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants