首页 / 浏览问题 / 桌面GIS / 问题详情
在桌面成功添加了自定义的Python算子,运行报错
16EXP 2023年08月21日

用python语句写了将属性表分析成数据透视表的形式输出,运行的时候报错,报错如下,是因为pandas库未加载吗

idesktop版本为10.2.1

can not find {0} in environment,use {1}
Traceback (most recent call last):
  File "D:\BaiduNetdiskDownload\supermap-idesktopx-10.2.1-1229-6939-92245-win64-bin-zip-chs\support\MiniConda\conda_mini\lib\site-packages\pandas\io\excel\_base.py", line 827, in __new__
    engine = config.get_option(f"io.excel.{ext}.writer", silent=True)
  File "D:\BaiduNetdiskDownload\supermap-idesktopx-10.2.1-1229-6939-92245-win64-bin-zip-chs\support\MiniConda\conda_mini\lib\site-packages\pandas\_config\config.py", line 243, in __call__
    return self.__func__(*args, **kwds)
  File "D:\BaiduNetdiskDownload\supermap-idesktopx-10.2.1-1229-6939-92245-win64-bin-zip-chs\support\MiniConda\conda_mini\lib\site-packages\pandas\_config\config.py", line 115, in _get_option
    key = _get_single_key(pat, silent)
  File "D:\BaiduNetdiskDownload\supermap-idesktopx-10.2.1-1229-6939-92245-win64-bin-zip-chs\support\MiniConda\conda_mini\lib\site-packages\pandas\_config\config.py", line 101, in _get_single_key
    raise OptionError(f"No such keys(s): {repr(pat)}")
pandas._config.config.OptionError: "No such keys(s): 'io.excel..writer'"

The above exception was the direct cause of the following exception:

2 个回答

还有一部分的报错是说缺少模块,怎么在idesktop里加载python的工具包,比如加载openpyxl
16EXP 2023年08月21日
报错提示应该是缺少pandas模块或模块依赖包不完整。
咱们桌面的python环境是miniconda,环境包路径 在桌面的 support\MiniConda\conda_mini 目录下,可以自行检查模块环境和用pip安装新的模块。
1,400EXP 2023年08月21日
...