无法安装ndg-httpsclient或者我的解决方案错误
I'm new to python and have a little experience with VS, C# and WPF.
我是python的新手,对VS,C#和WPF有一点经验。
My question might seem similar to some asked questions, but I tried several of the suggested solutions (that worked for others), and yet it doesn't work for me.
我的问题似乎与一些问题类似,但我尝试了几个建议的解决方案(对其他人有效),但它对我不起作用。
I'm trying to build a simple WPF application that will send http requests. The solution structure is as follows:
我正在尝试构建一个发送http请求的简单WPF应用程序。解决方案结构如下:
Solution MyApp
Project 1 <This is the startup project>
GUImodul.py
queryStringBuilder.py
<This project uses IronPython env for the WPF support>
Project 2
QuerySender.py (includes two classes)
<This project uses Python 3.4 env, only in this one I managed installing the "requests" package which I need for sending the query>
When I try to run this I get an error "No module named ndg.httpsclient.ssl_peer_verification", even though I only import from project 2 a class that doesn't contain any import from "requests" (it only creates an instance of the other class there that does have such import).
当我尝试运行它时,我得到一个错误“没有名为ndg.httpsclient.ssl_peer_verification的模块”,即使我只从项目2导入一个不包含任何“请求”导入的类(它只创建一个实例)那里的其他类确实有这样的导入)。
When I try to install ndg-httpsclient using pip, I get "Command python setup.py egg_info failed with error code 1".
当我尝试使用pip安装ndg-httpsclient时,我得到“命令python setup.py egg_info失败,错误代码为1”。
Things I tried so far:
到目前为止我尝试的事情:
- Adding "-X:FullFrames" to the debug properties of both projects
- 将“-X:FullFrames”添加到两个项目的调试属性中
- (re)installing steuptools with from ez_setup.zip
- (重新)使用ez_setup.zip安装steuptools
- As said - ndg-httpsclient is installed for Python34
- 如上所述 - 为Python34安装了ndg-httpsclient
- Using the "import requests" command only within the class NOT imported to Project1 (the one with IronPython env)
- 仅在未导入Project1的类中使用“导入请求”命令(使用IronPython环境的那个)
- Tried installing a newer(?) version of urllib3
- 尝试安装urllib3的更新(?)版本
So... I just might be doing something fundamentally wrong in this solution, which in this case I wish someone to help me understand what it is.
所以...我可能在这个解决方案中做了一些根本错误的事情,在这种情况下,我希望有人帮助我理解它是什么。
Otherwise, any idea what can I try next to make this thing work?
否则,任何想法我可以尝试下一步使这个东西工作?
1 个解决方案
#1
0
If you read the fine print, ndg-httpsclient
is incompatible with Python 3, as it was developed for Python2.7 . That's probabably the root cause.
如果您阅读了精细打印,ndg-httpsclient与Python 3不兼容,因为它是为Python2.7开发的。这可能是根本原因。
RE: Why is Python 3.0 not backward compatible?
RE:为什么Python 3.0不向后兼容?
更多相关文章
- python调用shell命令之三慷慨法
- Linux系统监控命令详解
- Linux开发工具(gcc gdb make shell)——GDB中list命令详解
- Linux curl 命令模拟 POST/GET 请求
- Linux基础-常用命令
- Linux中iptables基础命令
- linux基础(三)----linux命令系统学习----安装和登录命令
- shell用户配置详解及bash命令参数
- Linux网络和进程管理命令