I am in Mongolia and cannot download any of the models from command line using:
python -m spacy download en_core_web_sm
and error follows:
Collecting en_core_web_sm==2.2.5
Downloading https://github.com/explosion/spacy-models/releases/download/en_core_web_sm-2.2.5/en_core_web_sm-2.2.5.tar.gz (12.0MB)
ERROR: Exception:
Traceback (most recent call last):
File "/Users/bayartsogtyadamsuren/DDAM-Projects/isid/myenv/lib/python3.7/site-packages/pip/_vendor/urllib3/response.py", line 425, in _error_catcher
yield
File "/Users/bayartsogtyadamsuren/DDAM-Projects/isid/myenv/lib/python3.7/site-packages/pip/_vendor/urllib3/response.py", line 507, in read
data = self._fp.read(amt) if not fp_closed else b""
File "/usr/local/Cellar/python/3.7.4_1/Frameworks/Python.framework/Versions/3.7/lib/python3.7/http/client.py", line 457, in read
n = self.readinto(b)
File "/usr/local/Cellar/python/3.7.4_1/Frameworks/Python.framework/Versions/3.7/lib/python3.7/http/client.py", line 501, in readinto
n = self.fp.readinto(b)
File "/usr/local/Cellar/python/3.7.4_1/Frameworks/Python.framework/Versions/3.7/lib/python3.7/socket.py", line 589, in readinto
return self._sock.recv_into(b)
File "/usr/local/Cellar/python/3.7.4_1/Frameworks/Python.framework/Versions/3.7/lib/python3.7/ssl.py", line 1071, in recv_into
return self.read(nbytes, buffer)
File "/usr/local/Cellar/python/3.7.4_1/Frameworks/Python.framework/Versions/3.7/lib/python3.7/ssl.py", line 929, in read
return self._sslobj.read(len, buffer)
socket.timeout: The read operation timed out
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/Users/bayartsogtyadamsuren/DDAM-Projects/isid/myenv/lib/python3.7/site-packages/pip/_internal/cli/base_command.py", line 153, in _main
status = self.run(options, args)
File "/Users/bayartsogtyadamsuren/DDAM-Projects/isid/myenv/lib/python3.7/site-packages/pip/_internal/commands/install.py", line 382, in run
resolver.resolve(requirement_set)
File "/Users/bayartsogtyadamsuren/DDAM-Projects/isid/myenv/lib/python3.7/site-packages/pip/_internal/legacy_resolve.py", line 201, in resolve
self._resolve_one(requirement_set, req)
File "/Users/bayartsogtyadamsuren/DDAM-Projects/isid/myenv/lib/python3.7/site-packages/pip/_internal/legacy_resolve.py", line 365, in _resolve_one
abstract_dist = self._get_abstract_dist_for(req_to_install)
File "/Users/bayartsogtyadamsuren/DDAM-Projects/isid/myenv/lib/python3.7/site-packages/pip/_internal/legacy_resolve.py", line 313, in _get_abstract_dist_for
req, self.session, self.finder, self.require_hashes
File "/Users/bayartsogtyadamsuren/DDAM-Projects/isid/myenv/lib/python3.7/site-packages/pip/_internal/operations/prepare.py", line 194, in prepare_linked_requirement
progress_bar=self.progress_bar
File "/Users/bayartsogtyadamsuren/DDAM-Projects/isid/myenv/lib/python3.7/site-packages/pip/_internal/download.py", line 465, in unpack_url
progress_bar=progress_bar
File "/Users/bayartsogtyadamsuren/DDAM-Projects/isid/myenv/lib/python3.7/site-packages/pip/_internal/download.py", line 316, in unpack_http_url
progress_bar)
File "/Users/bayartsogtyadamsuren/DDAM-Projects/isid/myenv/lib/python3.7/site-packages/pip/_internal/download.py", line 551, in _download_http_url
_download_url(resp, link, content_file, hashes, progress_bar)
File "/Users/bayartsogtyadamsuren/DDAM-Projects/isid/myenv/lib/python3.7/site-packages/pip/_internal/download.py", line 255, in _download_url
consume(downloaded_chunks)
File "/Users/bayartsogtyadamsuren/DDAM-Projects/isid/myenv/lib/python3.7/site-packages/pip/_internal/utils/misc.py", line 641, in consume
deque(iterator, maxlen=0)
File "/Users/bayartsogtyadamsuren/DDAM-Projects/isid/myenv/lib/python3.7/site-packages/pip/_internal/download.py", line 223, in written_chunks
for chunk in chunks:
File "/Users/bayartsogtyadamsuren/DDAM-Projects/isid/myenv/lib/python3.7/site-packages/pip/_internal/utils/ui.py", line 160, in iter
for x in it:
File "/Users/bayartsogtyadamsuren/DDAM-Projects/isid/myenv/lib/python3.7/site-packages/pip/_internal/download.py", line 212, in resp_read
decode_content=False):
File "/Users/bayartsogtyadamsuren/DDAM-Projects/isid/myenv/lib/python3.7/site-packages/pip/_vendor/urllib3/response.py", line 564, in stream
data = self.read(amt=amt, decode_content=decode_content)
File "/Users/bayartsogtyadamsuren/DDAM-Projects/isid/myenv/lib/python3.7/site-packages/pip/_vendor/urllib3/response.py", line 529, in read
raise IncompleteRead(self._fp_bytes_read, self.length_remaining)
File "/usr/local/Cellar/python/3.7.4_1/Frameworks/Python.framework/Versions/3.7/lib/python3.7/contextlib.py", line 130, in __exit__
self.gen.throw(type, value, traceback)
File "/Users/bayartsogtyadamsuren/DDAM-Projects/isid/myenv/lib/python3.7/site-packages/pip/_vendor/urllib3/response.py", line 430, in _error_catcher
raise ReadTimeoutError(self._pool, None, "Read timed out.")
pip._vendor.urllib3.exceptions.ReadTimeoutError: HTTPSConnectionPool(host='github-production-release-asset-2e65be.s3.amazonaws.com', port=443): Read timed out.
and it is same using browser https://github.com/explosion/spacy-models/releases/tag/en_core_web_sm-2.2.5
I checked my internet connection and other stuff working well. So I thought it is not because of my machine.
There are other closed issues similar to this one but none of them actually solved in terms of internet connection error.
How can I fix this?
* Operating System: MacOS
* Python Version Used: 3.7.4
* spaCy Version Used: 2.2.4
* Environment Information: pip virtualenv
[update] I also tried it in other environments but no difference:
Tried a new machine with:
* Operating System: Ubuntu 16.04.6 LTS
* Python Version Used: 3.6.9
* spaCy Version Used: 2.2.4
* Environment Information: pip virtualenv
Hmm, I know that github was having some problems last week that affected downloads, but as far as I know they've been fixed. It sounds like you've tried this, but just to double-check, you can't download this link at all?
https://github.com/explosion/spacy-models/releases/download/en_core_web_sm-2.2.5/en_core_web_sm-2.2.5.tar.gz
Do you have a work VPN or firewall that might have restrictions on what you can access? Have you had any problems downloading anything from github in the past?
+1
Not fixed yet.
@adrianeboyd any timelines on when will it be solved?
The model downloads are all through github and they're not reporting any problems currently (https://www.githubstatus.com), so we're not sure what's going on. What errors do you see when you try to download the direct link above?
it is showing timeout right now.
Could you try downloading this link, and let us know whether that works?
https://github.com/psf/black/releases/download/19.10b0/black
Thank you for your quick response! @adrianeboyd
I have no problem with downloading anything from github except the model. Even installing spaCy on a new environment, it is downloading without problem.
It's working now using VPN, somehow particular networks has issue even though other things are working fine.
Thanks very much for your response.
But @bayartsogt-ya, you still run into problems? Have you tried downloading the black link I shared? It's equal size to the en_core_web_sm model so it would be a good test.
@svlandeg
I am still running into the problem. I tried that link already but still no difference.
Is this because of the region?
@bayartsogt-ya I am facing the exact same issue. It timesout and fails. The download fails even if I use the browser to download directly
Which region are you in, @prasanth-ntu ?
To be honest, we really don't know what could be causing this. Many users have no problem at all with downloading our assets either from the browser or through commandline. So the issue does not seem to be on our side. If you are 100% certain this is not caused by a firewall on your local network, perhaps it would make sense to open an issue with github support?
This issue has been automatically closed because there has been no response to a request for more information from the original author. With only the information that is currently in the issue, there's not enough information to take action. If you're the original author, feel free to reopen the issue if you have or find the answers needed to investigate further.
Is there any s3 link for en_core_web_sm model download
Most helpful comment
It's working now using VPN, somehow particular networks has issue even though other things are working fine.
Thanks very much for your response.