安装mysqlclient报错 /bin/sh: mysql_config: command not found /bin/sh: mariadb_config: command not

在MacOSVentura13.0系统中,用户遇到了安装mysqlclient时因mysql_config和mariadb_config命令未找到的错误。通过查找,发现mysql_config文件位于/usr/local/mysql-8.0.32-macos13-x86_64/bin目录下。为解决这个问题,用户更新了zshshell的环境变量,在~/.zprofile文件中添加了路径,并通过source~/.zprofile使更改生效。随后,mysqlclient通过pip成功安装。

报错记录

Looking in indexes: https://pypi.douban.com/simple/
Collecting mysqlclient
  Using cached https://pypi.doubanio.com/packages/50/5f/eac919b88b9df39bbe4a855f136d58f80d191cfea34a3dcf96bf5d8ace0a/mysqlclient-2.1.1.tar.gz (88 kB)
  Preparing metadata (setup.py) ... error
  error: subprocess-exited-with-error
  
  × python setup.py egg_info did not run successfully.
  │ exit code: 1
  ╰─> [18 lines of output]
      /bin/sh: mysql_config: command not found
      /bin/sh: mariadb_config: command not found
      /bin/sh: mysql_config: command not found
      Traceback (most recent call last):
        File "<string>", line 2, in <module>
        File "<pip-setuptools-caller>", line 34, in <module>
        File "/private/va

评论 2
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值