我想在我公司的笔记本电脑上构建Matter ChipTool应用程序作为WSL2上Android的apk。这个应用程序的通用仓库是https://github.com/project-chip/connectedhomeip。我按照这里的https://github.com/project-chip/connectedhomeip/blob/master/docs/guides/android_building.md指令构建了这个应用程序,但是当我运行source scripts/bootstrap.sh
时,我得到了这个错误:
Downloading and installing packages into local source directory:
Setting up CIPD package manager...[|]
Bootstrap: SSL error in Python when downloading CIPD client.
If using system Python try
sudo pip install certifi
And if on the system Python on a Mac try
/Applications/Python 3.6/Install Certificates.command
If using Homebrew Python try
brew install openssl
brew uninstall python
brew install python
If those don't work, address all the potential issues shown
by the following command.
brew doctor
Otherwise, check that your machine's Python can use SSL, testing with the httplib module on Python 2 or http.client on Python 3.
Traceback (most recent call last):
File "/home/florianw/dev/git/connectedhomeip/third_party/pigweed/repo/pw_env_setup/py/pw_env_setup/env_setup.py", line 857, in <module>
sys.exit(main())
File "/home/florianw/dev/git/connectedhomeip/third_party/pigweed/repo/pw_env_setup/py/pw_env_setup/env_setup.py", line 849, in main
return EnvSetup(**vars(parse())).setup()
File "/home/florianw/dev/git/connectedhomeip/third_party/pigweed/repo/pw_env_setup/py/pw_env_setup/env_setup.py", line 501, in setup
result = step(spin)
File "/home/florianw/dev/git/connectedhomeip/third_party/pigweed/repo/pw_env_setup/py/pw_env_setup/env_setup.py", line 595, in cipd
cipd_client = cipd_wrapper.init(
File "/home/florianw/dev/git/connectedhomeip/third_party/pigweed/repo/pw_env_setup/py/pw_env_setup/cipd_setup/wrapper.py", line 378, in init
bootstrap(client, silent, rosetta=rosetta)
File "/home/florianw/dev/git/connectedhomeip/third_party/pigweed/repo/pw_env_setup/py/pw_env_setup/cipd_setup/wrapper.py", line 328, in bootstrap
tmp.write(client_bytes(rosetta))
File "/home/florianw/dev/git/connectedhomeip/third_party/pigweed/repo/pw_env_setup/py/pw_env_setup/cipd_setup/wrapper.py", line 252, in client_bytes
conn.request('GET', path)
File "/usr/lib/python3.8/http/client.py", line 1256, in request
self._send_request(method, url, body, headers, encode_chunked)
File "/usr/lib/python3.8/http/client.py", line 1302, in _send_request
self.endheaders(body, encode_chunked=encode_chunked)
File "/usr/lib/python3.8/http/client.py", line 1251, in endheaders
self._send_output(message_body, encode_chunked=encode_chunked)
File "/usr/lib/python3.8/http/client.py", line 1011, in _send_output
self.send(msg)
File "/usr/lib/python3.8/http/client.py", line 951, in send
self.connect()
File "/usr/lib/python3.8/http/client.py", line 1425, in connect
self.sock = self._context.wrap_socket(self.sock,
File "/usr/lib/python3.8/ssl.py", line 500, in wrap_socket
return self.sslsocket_class._create(
File "/usr/lib/python3.8/ssl.py", line 1040, in _create
self.do_handshake()
File "/usr/lib/python3.8/ssl.py", line 1309, in do_handshake
self._sslobj.do_handshake()
ssl.SSLCertVerificationError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: self signed certificate in certificate chain (_ssl.c:1131)
我已经检查了我是否安装了python3(它是3.8.10版本),也像它说的那样安装了openssl,但我仍然得到同样的错误。我也extecuted了sudo pip install certifi
,它成功地安装了它,但我仍然得到同样的错误。
1条答案
按热度按时间t2a7ltrp1#
我终于发现了问题。我需要将我公司的根证书添加到WSL中,并使用: