pip 导入包时出现如下错误

  Complete output from command python setup.py egg_info:
/bin/sh: : mysql_config: not found
Traceback (most recent call last):
File "<string>", line , in <module>
File "/tmp/pip-install-6p9kqc0e/mysqlclient/setup.py", line , in <module>
metadata, options = get_config()
File "/tmp/pip-install-6p9kqc0e/mysqlclient/setup_posix.py", line , in get_config
libs = mysql_config("libs_r")
File "/tmp/pip-install-6p9kqc0e/mysqlclient/setup_posix.py", line , in mysql_config
raise EnvironmentError("%s not found" % (mysql_config.path,))
OSError: mysql_config not found ----------------------------------------
Command "python setup.py egg_info" failed with error code in /tmp/pip-install-6p9kqc0e/mysqlclient/

出现上面错误主要还是因为未安装python依赖,及mysqlclient:

问题解决:

 sudo apt-get install python3-dev libmysqlclient-dev
pip install mysqlclient

django 错误之 OSError: mysql_config not found的更多相关文章

  1. 【Django错误】OSError: raw write() returned invalid length 14 (should have been between 0 and 7)

    错误环境 使用Django框架创建完models类的之后,用python manage.py migrate命令来生成数据库表的时候出错 错误代码 Operations to perform: App ...

  2. 安装Python mysqlclient出现“OSError: mysql_config not found”错误

    问题:               使用Python3开发一个管理平台,用MySQL数据库存放元数据.使用pip安装mysqlclient模块时出现“OSError: mysql_config not ...

  3. OSError: mysql_config not found

    使用Python3开发一个管理平台,用MySQL数据库存放元数据.使用pip安装mysqlclient模块时出现“OSError: mysql_config not found”错误. 解决: # a ...

  4. 解决问题:OSError: mysql_config not found

    通过pip install mysqlclient时报出了OSError: mysql_config not found错误,如下 Traceback (most recent call last): ...

  5. pip 安装mysqlclient报错OSError: mysql_config not found

    执行 pip install mysqlclient 报错信息如下: [root@CentOS7-demo bin]# pip install mysqlclient Collecting mysql ...

  6. 第四百零五节,centos7下搭建sentry错误日志服务器,接收python以及Django错误,

    第四百零五节,centos7下搭建sentry错误日志服务器,接收python以及Django错误, 注意:版本,不然会报错 Docker >=1.11Compose >1.6.0 通过d ...

  7. 安装mysqlclient报OSError: mysql_config not found

    输入命令: :~$ pip install mysqlclient 报错: Collecting mysqlclient Using cached https://files.pythonhosted ...

  8. DJango错误日志生成

    DJango错误日志生成 setting.py设置 LOGGING = { 'version': 1, 'disable_existing_loggers': False, 'formatters': ...

  9. 错误:OSError: [Errno 1] Operation not permitted: 'lib/python/six-1.4.1-py2.7.egg-info'

    解决办法: $ $ pip install mock --ignore-installed six --user 问题:安装mock时报错: (venv)➜ test git:(master) pip ...

随机推荐

  1. 前端JS校验银行卡卡号和身份证号码(附ES6版方法)

    1.银行卡卡号校验方法. function luhnCheck(bankno) { var lastNum = bankno.substr(bankno.length - 1, 1); //取出最后一 ...

  2. unity游戏热更新总结

    1.利用反射来做Dll更新 这种方式只支持windows以及安卓这种支持JIT的平台,对于IOS就不适用了,IOS这种Full-AOT的平台不支持生成新的代码,因此这种热更方式很少用到.   2.利用 ...

  3. table <thead>表格css‘样式

    <table class="table table-bordered table-hover" id=""> <thead> <t ...

  4. [日常] Linux使用diff来比较目录

    Linux diff比较两个目录的不同: diff dir1 dir2  -urNaq -a  --text  Treat all files as text. -u  -U NUM  --unifi ...

  5. iOS开发消息推送原理

    转载自:http://www.cnblogs.com/cdts_change/p/3240893.html 一.消息推送原理: 在实现消息推送之前先提及几个于推送相关概念,如下图1-1: 1.Prov ...

  6. 【代码笔记】iOS-单击手势的添加

    一,效果图. 二,工程图. 三,代码. RootViewController.h #import <UIKit/UIKit.h> @interface RootViewController ...

  7. textarea 元素的 placeholder 属性不显示

    <textarea> 标签定义多行的文本输入控件. placeholder:描述文本区域预期值的简短提示. textarea 的 placeholder 属性值不显示的原因可能是 < ...

  8. elixir 表单 map

    键-值对 iex(13)> map = %{:a => 1, 2 => :b}%{2 => :b, :a => 1}iex(14)> map[:a]1iex(15) ...

  9. LeetCode 527---Word Abbreviation

    527. Word Abbreviation Given an array of n distinct non-empty strings, you need to generate minimal ...

  10. 一文详解 Linux 系统常用监控工具(top,htop,iotop,iftop)

      概 述 本文主要记录一下 Linux 系统上一些常用的系统监控工具,非常好用.正所谓磨刀不误砍柴工,花点时间总结一下是值得的! 本文内容脑图如下: top 命令 top 命令我想大家都挺熟悉吧! ...