云游碧海 发表于 2020-9-27 08:09:27

python中的mzgeohash模块安装失败

具体错误:
ERROR: Command errored out with exit status 1:
   command: 'C:\PyCharm作业\venv\Scripts\python.exe' -c 'import sys, setuptools, tokenize; sys.argv = '"'"'C:\\Users\\86178\\AppData\\Local\\Temp\\pycharm-packaging\\mzgeohash\\setup.py'"'"'; __file__='"'"'C:\\Users\\86178\\AppData\\Local\\Temp\\pycharm-packaging\\mzgeohash\\setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' egg_info --egg-base 'C:\Users\86178\AppData\Local\Temp\pip-pip-egg-info-a27kiebc'
         cwd: C:\Users\86178\AppData\Local\Temp\pycharm-packaging\mzgeohash\
    Complete output (7 lines):
    Traceback (most recent call last):
      File "<string>", line 1, in <module>
      File "C:\Users\86178\AppData\Local\Temp\pycharm-packaging\mzgeohash\setup.py", line 3, in <module>
      import mzgeohash
      File "C:\Users\86178\AppData\Local\Temp\pycharm-packaging\mzgeohash\mzgeohash\__init__.py", line 1, in <module>
      from geohash import encode, decode, adjacent, neighbors, neighborsfit
    ImportError: cannot import name 'encode'
    ----------------------------------------
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
望解答 {:10_266:}

不能懒 发表于 2020-9-27 10:12:59

卸载重装,然后重装加-m试试看

hrp 发表于 2020-9-27 10:20:51

从 geohash 导入 encode 失败,试试先安装 geohash,看看有没有这个包

云游碧海 发表于 2020-9-27 20:08:24

hrp 发表于 2020-9-27 10:20
从 geohash 导入 encode 失败,试试先安装 geohash,看看有没有这个包

安装了把Geohash改为geohash,还是显示      from geohash import encode, decode, adjacent, neighbors, neighborsfit
    ImportError: cannot import name 'adjacent这种错误{:10_243:}
页: [1]
查看完整版本: python中的mzgeohash模块安装失败