首页
学习
活动
专区
圈层
工具
发布
首页
学习
活动
专区
圈层
工具
MCP广场
社区首页 >问答首页 >pip安装python质子:如何修复windows上的错误?

pip安装python质子:如何修复windows上的错误?
EN

Stack Overflow用户
提问于 2022-05-24 15:53:39
回答 1查看 303关注 0票数 0

在运行质子时,我得到了以下错误:

  1. 错误:需要MicrosoftVisualC++ 14.0或更高版本。

我通过安装2022和2022修复了这个问题

  1. 致命错误C1083:无法打开编译器生成的文件

如果路径太长,显然会出现此错误。因此,我将临时文件夹的路径更改为较短的路径。为此,我在C:\Windows\TEMP下创建了一个新文件夹,并更改了设置以下环境变量:

TEMP=C:\TEMP和TMP=C:\TEMP

在这两个步骤之后,

  1. 得到了一个不同的错误。有人知道怎么解决这个问题吗?也许在windows上安装python-qpd-质子也有不同的方法吗?我会非常感激的.

此错误发生在此表单中的许多警告之后。

代码语言:javascript
运行
复制
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\src\core\buffer.c(279): warning C4267: '+=': conversion from 'size_t' to 'unsigned int', possible loss of data  
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\src\core\buffer.c(280): warning C4267: '-=': conversion from 'size_t' to 'unsigned int', possible loss of data  
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\src\core\buffer.c(273): warning C4267: 'initializing': conversion from 'size_t' to 'unsigned int', possible loss of data

还有一些错误:

代码语言:javascript
运行
复制
cproton_wrap.c  
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/object.h(242): error C2061: syntax error: identifier 
'pn_list_index'  
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/object.h(242): error C2059: syntax error: ';'         
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/object.h(242): error C2059: syntax error: '<parameter
-list>'  
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/object.h(280): error C2061: syntax error: identifier 
'pn_string_put'
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/object.h(280): error C2059: syntax error: ';'        
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/object.h(280): error C2059: syntax error: '<parameter
-list>'  
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/codec.h(546): error C2061: syntax error: identifier '
pn_data_encode'
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/codec.h(546): error C2059: syntax error: ';'  
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/codec.h(546): error C2059: syntax error: '<parameter-
list>'  
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/codec.h(555): error C2061: syntax error: identifier '  
pn_data_encoded_size'
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/codec.h(555): error C2059: syntax error: ';'  
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/codec.h(555): error C2059: syntax error: '<parameter-
list>'  
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/codec.h(574): error C2061: syntax error: identifier '
pn_data_decode'  
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/codec.h(574): error C2059: syntax error: ';'  
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/codec.h(574): error C2059: syntax error: '<parameter-
list>'  
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/link.h(587): error C2061: syntax error: identifier 'p
n_link_send'  
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/link.h(587): error C2059: syntax error: ';'  
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/link.h(587): error C2059: syntax error: '<parameter-l
ist>'   
 C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/link.h(640): error C2061: syntax error: identifier 'p
n_link_recv'  
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/link.h(640): error C2059: syntax error: ';'  
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/link.h(640): error C2059: syntax error: '<parameter-l
ist>'  
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/transport.h(489): error C2061: syntax error: identifi  
er 'pn_transport_input'
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/transport.h(489): error C2059: syntax error: ';'       
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/transport.h(489): error C2059: syntax error: '<parame
ter-list>'  
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/transport.h(494): error C2061: syntax error: identifi  
er 'pn_transport_output'
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/transport.h(494): error C2059: syntax error: ';'     
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/transport.h(494): error C2059: syntax error: '<parame
ter-list>'  
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/transport.h(513): error C2061: syntax error: identifi
er 'pn_transport_capacity'  
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/transport.h(513): error C2059: syntax error: ';'     
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/transport.h(513): error C2059: syntax error: '<parame
ter-list>'  
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/transport.h(546): error C2061: syntax error: identifi
er 'pn_transport_push'  
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/transport.h(546): error C2059: syntax error: ';'     
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/transport.h(546): error C2059: syntax error: '<parame
ter-list>'  
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/transport.h(593): error C2061: syntax error: identifier 'pn_transport_pending'  
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/transport.h(593): error C2059: syntax error: ';'     
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/transport.h(593): error C2059: syntax error: '<parame
ter-list>'  
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/transport.h(625): error C2061: syntax error: identifi
er 'pn_transport_peek'
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/transport.h(625): error C2059: syntax error: ';'     
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/transport.h(625): error C2059: syntax error: '<parame
ter-list>'  
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/message.h(752): error C2061: syntax error: identifier
 'pn_message_encode2'  
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/message.h(752): error C2059: syntax error: ';'       
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/message.h(752): error C2059: syntax error: '<paramete
r-list>'  
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/message.h(777): error C2061: syntax error: identifier
 'pn_message_send'  
      C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/message.h(777): error C2059: syntax error: ';'       
C:\Temp\pip-install-rv64pyj0\python-qpid-proton_043295171d11447ab93794ab575dd56d\include\proton/message.h(777): error C2059: syntax error: '<paramete
r-list>'  
      cproton_wrap.c(3131): error C2061: syntax error: identifier 'wrap_pn_link_recv'  
      cproton_wrap.c(3131): error C2059: syntax error: ';'  
      cproton_wrap.c(3131): error C2059: syntax error: '<parameter-list>'  
      cproton_wrap.c(3142): error C2061: syntax error: identifier 'wrap_pn_transport_peek'  
      cproton_wrap.c(3142): error C2059: syntax error: ';'  
      cproton_wrap.c(3142): error C2059: syntax error: '<parameter-list>'  
      cproton_wrap.c(3191): error C2061: syntax error: identifier 'wrap_pn_data_encode'  
      cproton_wrap.c(3191): error C2059: syntax error: ';'  
      cproton_wrap.c(3191): error C2059: syntax error: '<parameter-list>'  
      cproton_wrap.c(3760): error C2065: 'ssize_t': undeclared identifier  
      cproton_wrap.c(3760): error C2146: syntax error: missing ';' before identifier 'result'  
      cproton_wrap.c(3760): error C2065: 'result': undeclared identifier  
      cproton_wrap.c(3784): error C2065: 'result': undeclared identifier  
      cproton_wrap.c(3784): error C2065: 'ssize_t': undeclared identifier  
      cproton_wrap.c(3784): error C2146: syntax error: missing ';' before identifier 'pn_link_send'  
      cproton_wrap.c(3784): warning C4013: 'pn_link_send' undefined; assuming extern returning int  
      cproton_wrap.c(3787): error C2065: 'result': undeclared identifier  
      cproton_wrap.c(3806): error C2065: 'ssize_t': undeclared identifier  
      cproton_wrap.c(3806): error C2146: syntax error: missing ';' before identifier 'result'  
      cproton_wrap.c(3806): error C2065: 'result': undeclared identifier  
      cproton_wrap.c(3824): error C2065: 'result': undeclared identifier  
      cproton_wrap.c(3824): error C2065: 'ssize_t': undeclared identifier  
      cproton_wrap.c(3824): error C2146: syntax error: missing ';' before identifier  
 'wrap_pn_link_recv'   
      cproton_wrap.c(3824): warning C4013: 'wrap_pn_link_recv' undefined; assuming extern returning int    
      cproton_wrap.c(3827): error C2065: 'result': undeclared identifier    
      cproton_wrap.c(3845): error C2065: 'ssize_t': undeclared identifier    
      cproton_wrap.c(3845): error C2146: syntax error: missing ';' before identifier 'result'  
      cproton_wrap.c(3845): error C2065: 'result': undeclared identifier  
      cproton_wrap.c(3869): error C2065: 'result': undeclared identifier  
      cproton_wrap.c(3869): error C2065: 'ssize_t': undeclared identifier  
      cproton_wrap.c(3869): error C2146: syntax error: missing ';' before identifier  'pn_transport_push'  
      cproton_wrap.c(3869): warning C4013: 'pn_transport_push' undefined; assuming extern returning int  
      cproton_wrap.c(3872): error C2065: 'result': undeclared identifier  
      cproton_wrap.c(3891): error C2065: 'ssize_t': undeclared identifier  
      cproton_wrap.c(3891): error C2146: syntax error: missing ';' before identifier 'result'  
      cproton_wrap.c(3891): error C2065: 'result': undeclared identifier  
      cproton_wrap.c(3909): error C2065: 'result': undeclared identifier  
      cproton_wrap.c(3909): error C2065: 'ssize_t': undeclared identifier  
      cproton_wrap.c(3909): error C2146: syntax error: missing ';' before identifier  
 'wrap_pn_transport_peek'  
      cproton_wrap.c(3909): warning C4013: 'wrap_pn_transport_peek' undefined; assuming extern returning int  
      cproton_wrap.c(3912): error C2065: 'result': undeclared identifier   
      cproton_wrap.c(4005): error C2065: 'ssize_t': undeclared identifier   
      cproton_wrap.c(4005): error C2146: syntax error: missing ';' before identifier 'result'   
      cproton_wrap.c(4005): error C2065: 'result': undeclared identifier    
      cproton_wrap.c(4029): error C2065: 'result': undeclared identifier    
      cproton_wrap.c(4029): error C2065: 'ssize_t': undeclared identifier    
      cproton_wrap.c(4029): error C2146: syntax error: missing ';' before identifier 'pn_data_decode'    
      cproton_wrap.c(4029): warning C4013: 'pn_data_decode' undefined; assuming extern returning int  
      cproton_wrap.c(4032): error C2065: 'result': undeclared identifier  
      cproton_wrap.c(4051): error C2065: 'ssize_t': undeclared identifier  
      cproton_wrap.c(4051): error C2146: syntax error: missing ';' before identifier 'result'  
      cproton_wrap.c(4051): error C2065: 'result': undeclared identifier  
      cproton_wrap.c(4069): error C2065: 'result': undeclared identifier  
      cproton_wrap.c(4069): error C2065: 'ssize_t': undeclared identifier  
      cproton_wrap.c(4069): error C2146: syntax error: missing ';' before identifier 'wrap_pn_data_encode'  
      cproton_wrap.c(4069): warning C4013: 'wrap_pn_data_encode' undefined; assuming extern returning int  
      cproton_wrap.c(4072): error C2065: 'result': undeclared identifier  
      cproton_wrap.c(12214): error C2065: 'ssize_t': undeclared identifier  
      cproton_wrap.c(12214): error C2146: syntax error: missing ';' before identifier 'result'  
      cproton_wrap.c(12214): error C2065: 'result': undeclared identifier  
      cproton_wrap.c(12234): error C2065: 'result': undeclared identifier  
      cproton_wrap.c(12234): error C2065: 'ssize_t': undeclared identifier  
      cproton_wrap.c(12234): fatal error C1003: error count exceeds 100; stopping compilation
      error: command 'C:\\Program Files\\Microsoft Visual Studio\\2022\\Professional\\VC\\Tools\\MSVC\\14.32.31326\\bin\\HostX86\\x64\\cl.exe' failed with 
exit code 2`    
EN

回答 1

Stack Overflow用户

回答已采纳

发布于 2022-05-28 09:21:07

我使用Python3.9而不是Python3.10修复了最后一个错误。显然Python质子0.37.0只与Python3.9兼容。

票数 2
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/72365928

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档