在 https 上使用 Twill 或其他 http 工具
我可以使用 twill
登录到普通的 HTTP 站点。但是,当我尝试登录 SSL 站点时,出现以下错误:
$ twill-sh
>> go http://www.google.com
==> at http://www.google.com
>> go http://itunesconnect.apple.com/WebObjects/iTunesConnect.woa
ERROR: No module named mechanize
current page: *empty page*
我收到此错误的原因是什么?我认为这与 itunes 页面的安全性有关?我如何通过命令行登录给定页面?
I am able to use twill
to log in to a normal HTTP site. However, when I try and log into an SSL site, I get the following error:
$ twill-sh
>> go http://www.google.com
==> at http://www.google.com
>> go http://itunesconnect.apple.com/WebObjects/iTunesConnect.woa
ERROR: No module named mechanize
current page: *empty page*
What is the reason I am getting this error, which I think has to do with the security of the itunes page? And how would I log into the given page via command-line?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我相信,python-mechanize(它的 Ubuntu 名称,可能因其他系统而异)以及其他一些依赖项可能未在您的系统上安装(或删除)。虽然 twill 发行版提供了自己的机制,但发行版通常会确保做得正确。
在求助于 sudo easy_install 之前,请考虑使用您的发行版的方式查找和安装软件包。
在Ubuntu上:
I believe, python-mechanize (Ubuntu name for it, may vary for other systems) and maybe some other dependencies are somehow not installed (or removed) on your system. While twill distro provides its own mechanize, distros usually make sure to do it right.
Before resorting to sudo easy_install, consider finding and installing packages by using your distro's way.
On Ubuntu: