小编Jea*_*oto的帖子

在 macOS 上默认使用 Python3,但 pip 仍然使用 python 2.7

我使用的是 macOS Big Sur 11.0.1。

我正在设置一个virtual env

$python3 -m venv $my_workdir)/.virtualenv
Run Code Online (Sandbox Code Playgroud)

但在构建wheel包时出现此错误:

building '_openssl' extension
  creating build/temp.macosx-10.14.6-x86_64-3.8/build
  creating build/temp.macosx-10.14.6-x86_64-3.8/build/temp.macosx-10.14.6-x86_64-3.8
  clang -Wno-unused-result -Wsign-compare -Wunreachable-code -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -iwithsysroot/System/Library/Frameworks/System.framework/PrivateHeaders -iwithsysroot/Applications/Xcode.app/Contents/Developer/Library/Frameworks/Python3.framework/Versions/3.8/Headers -arch arm64 -arch x86_64 -I/usr/local/opt/gettext/include -I/Users/engontang/devspace/energisme/terraform/tfwrapper-infra-pda/.wrapper/.virtualenv/include -I/Applications/Xcode.app/Contents/Developer/Library/Frameworks/Python3.framework/Versions/3.8/include/python3.8 -c build/temp.macosx-10.14.6-x86_64-3.8/_openssl.c -o build/temp.macosx-10.14.6-x86_64-3.8/build/temp.macosx-10.14.6-x86_64-3.8/_openssl.o -Wconversion -Wno-error=sign-conversion
  build/temp.macosx-10.14.6-x86_64-3.8/_openssl.c:575:10: fatal error: 'openssl/opensslv.h' file not found
  #include <openssl/opensslv.h>
           ^~~~~~~~~~~~~~~~~~~~
  1 error generated.
  error: command 'clang' failed with exit status 1 

----------------------------------------

ERROR: Failed building wheel for cryptography

Building wheel for pynacl …
Run Code Online (Sandbox Code Playgroud)

python pip python-venv python-wheel

7
推荐指数
2
解决办法
8725
查看次数

错误“未找到受支持的 WSMan 客户端库。” 使用 macOS pwsh

从 macOS 终端,当我执行时:

pwsh -command "Enter-PSSession myhost"
Run Code Online (Sandbox Code Playgroud)

我从 PowerShell 收到错误消息:

pwsh -command "Enter-PSSession myhost"
Run Code Online (Sandbox Code Playgroud)

我花了 2 个小时才找到解决方案。我要回答我自己的问题。

macos powershell openssl wsman

4
推荐指数
3
解决办法
9266
查看次数

如何使用ansible安装特定版本的brew cask Formula?

如何使用 ansible 安装特定版本的自制桶公式?例如,vagrant 2.2.6,而最新可用的是 2.2.7。

versioning ansible homebrew-cask

3
推荐指数
1
解决办法
5268
查看次数

如何强制 Eclipse 使用特定版本的 NodeJS 来修复错误“Node.js 版本无法确定”?

我已经安装了最新版本的 Eclipse-IDE (2020-03),安装程序选项为“适用于 Web 和 JavaScript 开发人员的 Eclipse IDE”。它非常慢。打开文件需要 2-3 秒。最后显示以下错误: 错误 Node.JS 版本无法确定。

eclipse macos node.js wildwebdeveloper

1
推荐指数
1
解决办法
3083
查看次数