Documentation Build From Source Not reflective of steps.
See original GitHub issueDescribe the bug When following the build from source steps. During the docker build you are faced with
"RUN pipenv run python install_nlp_models.py --conf_file conf/default.yaml:
#29 3.271 Installing models from configuration: {'nlp_engine_name': 'spacy', 'models': [{'lang_code': 'en', 'model_name': 'en_core_web_sm'}]}
#29 3.356 Traceback (most recent call last):
#29 3.356 File "/usr/bin/presidio-analyzer/.venv/lib/python3.9/site-packages/urllib3/connectionpool.py", line 699, in urlopen
#29 3.359 httplib_response = self._make_request(
#29 3.359 File "/usr/bin/presidio-analyzer/.venv/lib/python3.9/site-packages/urllib3/connectionpool.py", line 382, in _make_request
#29 3.359 self._validate_conn(conn)
#29 3.359 File "/usr/bin/presidio-analyzer/.venv/lib/python3.9/site-packages/urllib3/connectionpool.py", line 1010, in _validate_conn
#29 3.360 conn.connect()
#29 3.360 File "/usr/bin/presidio-analyzer/.venv/lib/python3.9/site-packages/urllib3/connection.py", line 411, in connect
#29 3.361 self.sock = ssl_wrap_socket(
#29 3.361 File "/usr/bin/presidio-analyzer/.venv/lib/python3.9/site-packages/urllib3/util/ssl_.py", line 449, in ssl_wrap_socket
#29 3.362 ssl_sock = _ssl_wrap_socket_impl(
#29 3.362 File "/usr/bin/presidio-analyzer/.venv/lib/python3.9/site-packages/urllib3/util/ssl_.py", line 493, in _ssl_wrap_socket_impl
#29 3.363 return ssl_context.wrap_socket(sock, server_hostname=server_hostname)
#29 3.363 File "/usr/local/lib/python3.9/ssl.py", line 500, in wrap_socket
#29 3.365 return self.sslsocket_class._create(
#29 3.365 File "/usr/local/lib/python3.9/ssl.py", line 1040, in _create
#29 3.366 self.do_handshake()
#29 3.366 File "/usr/local/lib/python3.9/ssl.py", line 1309, in do_handshake
#29 3.368 self._sslobj.do_handshake()
#29 3.368 ssl.SSLCertVerificationError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:1129)
#29 3.368
#29 3.368 During handling of the above exception, another exception occurred:
#29 3.368
#29 3.368 Traceback (most recent call last):
#29 3.368 File "/usr/bin/presidio-analyzer/.venv/lib/python3.9/site-packages/requests/adapters.py", line 439, in send
#29 3.369 resp = conn.urlopen(
#29 3.370 File "/usr/bin/presidio-analyzer/.venv/lib/python3.9/site-packages/urllib3/connectionpool.py", line 755, in urlopen
#29 3.371 retries = retries.increment(
#29 3.371 File "/usr/bin/presidio-analyzer/.venv/lib/python3.9/site-packages/urllib3/util/retry.py", line 574, in increment
#29 3.373 raise MaxRetryError(_pool, url, error or ResponseError(cause))
#29 3.373 urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='raw.githubusercontent.com', port=443): Max retries exceeded with url: /explosion/spacy-models/master/compatibility.json (Caused by SSLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:1129)')))
#29 3.373
#29 3.373 During handling of the above exception, another exception occurred:
#29 3.373
#29 3.374 Traceback (most recent call last):
#29 3.374 File "/usr/bin/presidio-analyzer/install_nlp_models.py", line 64, in <module>
#29 3.376 install_models(conf_file=args.conf_file)
#29 3.376 File "/usr/bin/presidio-analyzer/install_nlp_models.py", line 34, in install_models
#29 3.377 _download_model(engine_name, model_name)
#29 3.377 File "/usr/bin/presidio-analyzer/install_nlp_models.py", line 44, in _download_model
#29 3.377 spacy.cli.download(model_name)
#29 3.377 File "/usr/bin/presidio-analyzer/.venv/lib/python3.9/site-packages/spacy/cli/download.py", line 67, in download
#29 3.378 compatibility = get_compatibility()
#29 3.378 File "/usr/bin/presidio-analyzer/.venv/lib/python3.9/site-packages/spacy/cli/download.py", line 78, in get_compatibility
#29 3.378 r = requests.get(about.__compatibility__)
#29 3.378 File "/usr/bin/presidio-analyzer/.venv/lib/python3.9/site-packages/requests/api.py", line 76, in get
#29 3.379 return request('get', url, params=params, **kwargs)
#29 3.379 File "/usr/bin/presidio-analyzer/.venv/lib/python3.9/site-packages/requests/api.py", line 61, in request
#29 3.379 return session.request(method=method, url=url, **kwargs)
#29 3.379 File "/usr/bin/presidio-analyzer/.venv/lib/python3.9/site-packages/requests/sessions.py", line 542, in request
#29 3.381 resp = self.send(prep, **send_kwargs)
#29 3.381 File "/usr/bin/presidio-analyzer/.venv/lib/python3.9/site-packages/requests/sessions.py", line 655, in send
#29 3.381 r = adapter.send(request, **kwargs)
#29 3.381 File "/usr/bin/presidio-analyzer/.venv/lib/python3.9/site-packages/requests/adapters.py", line 514, in send
#29 3.382 raise SSLError(e, request=request)
#29 3.382 requests.exceptions.SSLError: HTTPSConnectionPool(host='raw.githubusercontent.com', port=443): Max retries exceeded with url: /explosion/spacy-models/master/compatibility.json (Caused by SSLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:1129)')))
```"
**To Reproduce**
Follow the steps verbatim for the "Build from Source" issue.
**Expected behavior**
When following the build from source there should be something within the section/dev setup section that denotes the requires to build an SSL ceritificate to be provided to the docker file.
Issue Analytics
- State:
- Created 2 years ago
- Comments:9 (6 by maintainers)
Top Results From Across the Web
Building Unreal Engine from Source
From your first steps to complete mastery of Unreal Engine, we've got you covered. ... Share, inspire, and connect with creators across industries...
Read more >Build settings reference | Apple Developer Documentation
A detailed list of individual Xcode build settings that control or change the way a target is built.
Read more >Reflective Listening
A door opener is usually a reflection of only the behavior your see because often no words are expressed. Door openers involve four...
Read more >Transition from Java 8 to Java 11 - Azure - Microsoft Learn
What jdeprscan and jdeps cannot do is warn about the use of reflection to access encapsulated API. Reflective access is checked at runtime....
Read more >Build System (CMake) - Zephyr Project Documentation
All source code that goes into a Zephyr build does so by being included in a library ... and this step is skipped...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
I’ve run solely the analyzer. (I modified the docker-compose file) and this was the result. It looks like the issue lays with the spacy library? EDIT: I downloaded the presidio docker image and tried to install spacy following these the steps here: https://spacy.io/usage I still got the same validation error, so its not the presidio.
Module from within Docker container.
I found a few options that could help: First is to add a direct flag to the spacy download command:
python -m spacy download en_core_web_sm --direct
Second is to use wget or curl to download it manually (maybe disable ssl verification for insecure download) and install using pippython -m pip install en_core_web_sm-3.0.0.tar.gz
A third option, valid only if you were able to download locally outside of the container, is to define docker network mode to be ‘host’ when building