当前位置:   article > 正文

ImportError: Bad git executable错误解决_importerror: bad git executable.

importerror: bad git executable.
  1. ImportError: Bad git executable.
  2. The git executable must be specified in one of the following ways:
  3.     - be included in your $PATH
  4.     - be set via $GIT_PYTHON_GIT_EXECUTABLE
  5.     - explicitly set via git.refresh()
  6. All git commands will error until this is rectified.
  7. This initial warning can be silenced or aggravated in the future by setting the
  8. $GIT_PYTHON_REFRESH environment variable. Use one of the following values:
  9.     - quiet|q|silence|s|none|n|0: for no warning or exception
  10.     - warn|w|warning|1: for a printed warning
  11.     - error|e|raise|r|2: for a raised exception
  12. Example:
  13.     export GIT_PYTHON_REFRESH=quiet

 报错解决办法

 在from git.types import PathLike前面,import os 后面添加了一行

os.environ["GIT_PYTHON_REFRESH"] = "quiet"

就到你的报错文件上面找

声明:本文内容由网友自发贡献,不代表【wpsshop博客】立场,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:https://www.wpsshop.cn/w/羊村懒王/article/detail/621182
推荐阅读
相关标签
  

闽ICP备14008679号