gee-community / qgis-earthengine-plugin

Integrates Google Earth Engine and QGIS using Python API
http://qgis-ee-plugin.appspot.com
MIT License
454 stars 116 forks source link

Uncaught ImportError: cannot import name 'QgsFeaturePickerWidget' from 'qgis._gui' (C:/PROGRA~1/QGIS3~1.8/apps/qgis/./python\qgis\_gui.pyd) #119

Closed LutfyMira closed 2 years ago

LutfyMira commented 2 years ago

Couldn't load plugin 'geetimeseriesexplorer' Steps to reproduce

  1. First
  2. Second
  3. Third
Traceback (most recent call last):
  File "C:/PROGRA~1/QGIS3~1.8/apps/qgis/./python\qgis\utils.py", line 312, in loadPlugin
    __import__(packageName)
  File "C:/Users/lutfy/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\ee_plugin\__init__.py", line 38, in __wrapping_ee_import__
    _module_ = __builtin_import__(name, *args, **kwargs)
  File "C:/Users/lutfy/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\ee_plugin\__init__.py", line 38, in __wrapping_ee_import__
    _module_ = __builtin_import__(name, *args, **kwargs)
  File "C:/PROGRA~1/QGIS3~1.8/apps/qgis/./python\qgis\utils.py", line 737, in _import
    mod = _builtin_import(name, globals, locals, fromlist, level)
  File "C:/Users/lutfy/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\geetimeseriesexplorer\__init__.py", line 1, in <module>
    from geetimeseriesexplorer.plugin import Plugin
  File "C:/Users/lutfy/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\ee_plugin\__init__.py", line 38, in __wrapping_ee_import__
    _module_ = __builtin_import__(name, *args, **kwargs)
  File "C:/Users/lutfy/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\ee_plugin\__init__.py", line 38, in __wrapping_ee_import__
    _module_ = __builtin_import__(name, *args, **kwargs)
  File "C:/PROGRA~1/QGIS3~1.8/apps/qgis/./python\qgis\utils.py", line 737, in _import
    mod = _builtin_import(name, globals, locals, fromlist, level)
  File "C:/Users/lutfy/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\geetimeseriesexplorer\plugin.py", line 8, in <module>
    from geetimeseriesexplorer.dockwidget import DockWidget
  File "C:/Users/lutfy/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\ee_plugin\__init__.py", line 38, in __wrapping_ee_import__
    _module_ = __builtin_import__(name, *args, **kwargs)
  File "C:/Users/lutfy/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\ee_plugin\__init__.py", line 38, in __wrapping_ee_import__
    _module_ = __builtin_import__(name, *args, **kwargs)
  File "C:/PROGRA~1/QGIS3~1.8/apps/qgis/./python\qgis\utils.py", line 737, in _import
    mod = _builtin_import(name, globals, locals, fromlist, level)
  File "C:/Users/lutfy/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\geetimeseriesexplorer\dockwidget.py", line 30, in <module>
    from qgis._gui import (QgsDockWidget, QgsCollapsibleGroupBox, QgisInterface, QgsMapMouseEvent, QgsFeaturePickerWidget,
ImportError: cannot import name 'QgsFeaturePickerWidget' from 'qgis._gui' (C:/PROGRA~1/QGIS3~1.8/apps/qgis/./python\qgis\_gui.pyd)

ee_plugin 0.0.5, QGIS 3.8.0-Zanzibar on Windows 10

XavierCLL commented 2 years ago

Hi @LutfyMira

The error is directly from the geetimeseriesexplorer, it uses this plugin but the error is due to a lib that geetimeseriesexplorer is trying to import: QgsFeaturePickerWidget this class is only available for Qgis >= 3.14: https://qgis.org/pyqgis/3.16/gui/QgsFeaturePickerWidget.html#module-QgsFeaturePickerWidget

I recommend you update Qgis to the latest or stable version