buildozer
buildozer copied to clipboard
buildozer fails installing Android NDK
My system is MacOS 10.11.6 Python 3.8
When I issue the command 'buildozer android debug' the process aborts at
# Android NDK is missing, downloading
# Downloading https://dl.google.com/android/repository/android-ndk-r19c-darwin-x86_64.zip
Traceback (most recent call last):
File "/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/urllib/request.py", line 1759, in open
return getattr(self, name)(url)
File "/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/urllib/request.py", line 1968, in open_https
return self._open_generic_http(self._https_connection, url, data)
File "/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/urllib/request.py", line 1917, in _open_generic_http
http_conn.request("GET", selector, headers=headers)
File "/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/http/client.py", line 1230, in request
self._send_request(method, url, body, headers, encode_chunked)
File "/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/http/client.py", line 1276, in _send_request
self.endheaders(body, encode_chunked=encode_chunked)
File "/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/http/client.py", line 1225, in endheaders
self._send_output(message_body, encode_chunked=encode_chunked)
File "/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/http/client.py", line 1004, in _send_output
self.send(msg)
File "/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/http/client.py", line 965, in send
self.sock.sendall(data)
File "/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/ssl.py", line 1205, in sendall
v = self.send(byte_view[count:])
File "/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/ssl.py", line 1174, in send
return self._sslobj.write(data)
ssl.SSLCertVerificationError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:2457)
This problem is similar to [(https://github.com/kivy/kivy/issues/5784)] but the solution there is for python 2.7.
All advice welcomed.
我的解决方法是在buildozer库里的应该是__init__.py的文件里添加一个 import ssl
ssl._create_default_https_context=ssl._create_unverified_context 不一定会解决你的问题,但你可以试试
I made the ssl.SSLCertVerificationError
go away by running open /Applications/Python\ 3.10/Install\ Certificates.command
. However, I then ran into #1112.
👋 @tomfowle, we use the issue tracker exclusively for bug reports and feature requests. However, this issue appears to be a support request. Please use our support channels to get help with the project. Let us know if this comment was made in error, and we'll be happy to reopen the issue.