Python踩坑之路


pip/easy_install无法安装Twisted或者安装后无法导入Twisted

看到MM网站上很多图,想用Scrapy框架爬点图,遇到各种库的问题,蛋疼。
一直twisted安装不上,总是报错failed with error code 1 in /tmp/pip-build-H1bj8E/twisted/ 好奇,不就想下个图么。pip和easy_install老是报错,只好试试源码安装了。

  1. 更新系统
    yum update
  2. 安装Twisted依赖关系包
    yum install wget python-devel python-zope-interface
  3. 安装开发环境工具
    yum group install 'development tools'
  4. Twisted官网下载最新版本安装
    wget http://twistedmatrix.com/Releases/Twisted/17.5/Twisted-17.5.0.tar.bz2
  5. 解压安装
    tar -jxvf Twisted-17.5.0.tar.bz2
    cd Twisted-17.5.0
    python setup.py install

无奈,只好死马当活马医。

Centos/Fedora下安装Twisted,failed with error code 1 in /tmp/pip-build-H1bj8E/twisted/解决方法的更多相关文章

  1. python开发环境软件包安装相关 failed with error code 1 in /tmp/pip-build-vn_f_e1n/psutil/

    指定源安装 pip install git+https://github.com/xxxxxx.git pip install -r requirements.txt -i https://mirro ...

  2. ubuntu下安装pandas出现 compile failed with error code 1 in /tmp/pip_build_hadoop/pandas

    都是用pip装的,是不是应该用apt-get 装的呀 ubuntu下安装pandas (出现 compile failed with error code 1 in /tmp/pip_build_ha ...

  3. python2 使用pip安装psycopg2出现错误:Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-install-mvzdNj/psycopg2/

    公司业务需求,开发语言python2,需要使用数据库:postgresql,需要安装模块psycopg2这个模块, 使用pip install psycopg2 报错: Command "p ...

  4. pip安装mysql-python报错:Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-install-enRreC/mysql-python/

    公司业务开发,用python开发网站;需要使用模块MySQLdb. 我直接pip install MySQLdb,当然不成功了,模块名字因该是mysql-python pip install mysq ...

  5. pip安装报错Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-build-e_k8hq6a/pynacl/

    Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-build-e_k8hq6a/pyn ...

  6. 解决Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-install-f8IeEI/MYSQL-python/

    Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-install-f8IeEI/MYS ...

  7. Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-build-9enuqi/MySQL-python/

    hu@hu-VirtualBox:/home/newdisk/telnet-scanner$ sudo pip install MySQL-python[sudo] hu 的密码: The direc ...

  8. python3 中mlpy模块安装 出现 failed with error code 1的决绝办法(其他模块也可用本方法)

    在python3 中安装其它模块时经常出现 failed with error code 1等状况,使的安装无法进行.而解决这个问题又非常麻烦. 接下来以mlpy为例,介绍一种解决此类安装问题的办法. ...

  9. 在linux系统下安装mysql详解,以及远程调用连接不上mysql的解决方法。

    步骤: 1)查看CentOS自带的mysql 输入 rpm -qa | grep mysql 2)将自带的mysql卸载 3)上传Mysql的安装包到linux 4)安装mysql的依赖(不是必须) ...

随机推荐

  1. 常见面试算法题JS实现-设计一个有getMin功能的栈

    前言: 已经确定工作了-下周一正式入职,按理说应该是可以好好浪荡一周的,但是内心总是不安,总觉得自己这个水平真的太菜了,还是趁着现在有自己的时间,赶紧多看看书,多学习学习吧orz所以把之前校招买的书, ...

  2. 查找linux镜像源中的软件版本并进行安装

    输入以下代码进行软件查找 sudo apt-cache search YourSoftwareName 根据所得到的结果进行安装 sudo apt-get install YourSoftwareNa ...

  3. windows下安装Mongodb_4.0.6最新版及常用命令

    今天下载了最新版Mongodb进行安装,发现相比较于以前,方便了很多,直接下载: 一.下载地址:https://www.mongodb.com/download-center/enterprise 二 ...

  4. elementUI实现前端分页

    按照他的文档来写分页,最主要的是el-table里面展示的数据怎么处理 <el-table :data="AllCommodityList.slice((currentPage-1)* ...

  5. webpack新手入门——配置及安装

    webpack 是一个现代 JavaScript 应用程序的静态模块打包器.当 webpack 处理应用程序时,它会递归地构建一个依赖关系图(dependency graph),其中包含应用程序需要的 ...

  6. Oracle之带参存储过程(存储过程中for循环调用存储过程)

    --带参存储过程create or replace procedure testdate(v in number) is i number; begin i:=v; insert into test_ ...

  7. 基于C#的机器学习--惩罚与奖励-强化学习

    强化学习概况 正如在前面所提到的,强化学习是指一种计算机以“试错”的方式进行学习,通过与环境进行交互获得的奖赏指导行为,目标是使程序获得最大的奖赏,强化学习不同于连督学习,区别主要表现在强化信号上,强 ...

  8. c++文件对齐

    头文件#include <iomanip> 关键词:setw(n),std::left,std::right 实例:输出一个0-4的12*12方阵,要求数字宽度为4,居左对齐,右下角输出出 ...

  9. PHP 抽象类和接口区别

    php中抽象类和接口的区别 1) 概念 面向对象的三大概念:封装,继承,多态 把属性和方法封装起来就是类.      一个类的属性和方法被另外的类复制就是继承,PHP里面的任何类都可以被继承,被继承的 ...

  10. CS小分队第二阶段冲刺站立会议(6月1日)

    昨日成果:完成了,文件图标的获取,以及代码删除获取文件的图标的功能:实现了从桌面拖动一个应用到窗体进行添加的功能: 遇到问题:获取的文件图标太小了,比较模糊:从外面拖动文件到窗体时,图标一直获取错误, ...