urllib3 or chardet outdated
Closed this issue · 3 comments
JulioJu commented
Hi !
Since the last upgrade of my System (I'm on Arch Linux) I've the following error on the first request (not the following):
"../rest_request_with_vim.roast" 158L, 3908C
Error detected while processing /home/julioprayer/.vim/plugged/roast.vim/autoload/roast.vim:
line 15:
/usr/lib/python3.7/site-packages/requests/__init__.py:91: RequestsDependencyWarning: urllib3 (1.25.2) or chardet (3.0.4) doesn't match a supported version!
RequestsDependencyWarning)
It seems that the Roast Plugin continue to work without problems…
My python --version
: 3.7.3
Thanks in advance !
JulioJu commented
Furthermore sometimes I have the following error:
Error detected while processing function roast#run:
line 1:
Traceback (most recent call last):
File "/usr/lib/python3.7/site-packages/urllib3/connectionpool.py", line 603, in urlopen
chunked=chunked)
File "/usr/lib/python3.7/site-packages/urllib3/connectionpool.py", line 387, in _make_request
six.raise_from(e, None)
File "<string>", line 2, in raise_from
File "/usr/lib/python3.7/site-packages/urllib3/connectionpool.py", line 383, in _make_request
httplib_response = conn.getresponse()
File "/usr/lib/python3.7/http/client.py", line 1321, in getresponse
response.begin()
File "/usr/lib/python3.7/http/client.py", line 296, in begin
version, status, reason = self._read_status()
File "/usr/lib/python3.7/http/client.py", line 284, in _read_status
raise BadStatusLine(line)
http.client.BadStatusLine: HTTP/1.1 20 ^M
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/lib/python3.7/site-packages/requests/adapters.py", line 449, in send
timeout=timeout
File "/usr/lib/python3.7/site-packages/urllib3/connectionpool.py", line 641, in urlopen
_stacktrace=sys.exc_info()[2])
File "/usr/lib/python3.7/site-packages/urllib3/util/retry.py", line 368, in increment
raise six.reraise(type(error), error, _stacktrace)
File "/usr/lib/python3.7/site-packages/urllib3/packages/six.py", line 685, in reraise
raise value.with_traceback(tb)
File "/usr/lib/python3.7/site-packages/urllib3/connectionpool.py", line 603, in urlopen
chunked=chunked)
File "/usr/lib/python3.7/site-packages/urllib3/connectionpool.py", line 387, in _make_request
six.raise_from(e, None)
File "<string>", line 2, in raise_from
File "/usr/lib/python3.7/site-packages/urllib3/connectionpool.py", line 383, in _make_request
httplib_response = conn.getresponse()
File "/usr/lib/python3.7/http/client.py", line 1321, in getresponse
response.begin()
File "/usr/lib/python3.7/http/client.py", line 296, in begin
version, status, reason = self._read_status()
File "/usr/lib/python3.7/http/client.py", line 284, in _read_status
raise BadStatusLine(line)
urllib3.exceptions.ProtocolError: ('Connection aborted.', BadStatusLine('HTTP/1.1 20 \r\n'))
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/julioprayer/.vim/plugged/roast.vim/python3/roast.py", line 34, in run
response = sessions[vim.current.buffer.number].send(request.prepare())
File "/usr/lib/python3.7/site-packages/requests/sessions.py", line 646, in send
r = adapter.send(request, **kwargs)
File "/usr/lib/python3.7/site-packages/requests/adapters.py", line 498, in send
raise ConnectionError(err, request=request)
requests.exceptions.ConnectionError: ('Connection aborted.', BadStatusLine('HTTP/1.1 20 \r\n'))
-- More --
sharat87 commented
I think the problem is with having multiple installs of the requests library. Can you get me the output of the following python code snippet from your system please?
import requests, urllib3, chardet
print('requests', requests.__version__)
print('urllib3', urllib3.__version__)
print('chardet', chardet.__version__)
Thanks!
JulioJu commented
Ok thanks for your answer. Actually this error doesn't occur anymore. If this error occur again, I will check this.