由于项目开发过程汇总涉及到利用python调用geoserver发布服务的过程,需要用到以下的python包
# _*_coding:utf-8_*_
from geoserver.catalog import Catalog
from geoserver.support import JDBCVirtualTable, JDBCVirtualTableGeometry, JDBCVirtualTableParam
geoserver有红色下划线,很明显三方库没有导入,鼠标放在单词上 按alt+enter,自动导入会报错
Executed command:
pip install --user gsconfig
Error occurred:
Non-zero exit code (2
Proposed solution:
ry to run this command from the system terminal. Make sure that you use the correct version otyour Python interpreter located at 'C:(Usersladmin AppData\LocalPrograms(Python(Python36\p
导入失败尝试用命令行导入:
(1)、查看python 安装路径
C:users admin>where python
C:users admin AppData Local Programs Python Python36 python.exe:
C:Wsers admin Enus ai Scripts python.exe
(2)切换到有python.exe的文件夹地址
cd C:Users\admin\AppData\Local\Programs\Python\Python36
(3)第一次和第二次尝试都失败
pip install gsconfig
报错
莫名其妙
以为是镜像问题
尝试下面这个 ,还是不行
pip install -i https://pypi.tuna.tsinghua.edu.cn/simple gsconfig
最后考虑到版本问题 ,我用的python版本是python3.6,所以要安装gsconfig-py3版本
pip install -i https://pypi.tuna.tsinghua.edu.cn/simple gsconfig-py3
安装成功!