question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

couldn't activate the plugin

See original GitHub issue

Hi, I just installed the plugin but when I wanted to activate it, I faced this error:

Couldn't load plugin 'ee_plugin' due to an error when calling its classFactory() method 

TypeError: get_authorization_url() missing 1 required positional argument: 'code_challenge' 
Traceback (most recent call last):
  File "C:\Users\javad\AppData\Roaming\QGIS\QGIS3\profiles\default\python\plugins\ee_plugin\extlibs_windows\ee\data.py", line 230, in get_persistent_credentials
    tokens = json.load(open(oauth.get_credentials_path()))
FileNotFoundError: [Errno 2] No such file or directory: 'C:\\Users\\javad/.config/earthengine/credentials'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "C:/Users/javad/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\ee_plugin\ee_auth.py", line 19, in init
    ee.Initialize()
  File "C:\Users\javad\AppData\Roaming\QGIS\QGIS3\profiles\default\python\plugins\ee_plugin\extlibs_windows\ee\__init__.py", line 114, in Initialize
    credentials = data.get_persistent_credentials()
  File "C:\Users\javad\AppData\Roaming\QGIS\QGIS3\profiles\default\python\plugins\ee_plugin\extlibs_windows\ee\data.py", line 241, in get_persistent_credentials
    'Please authorize access to your Earth Engine account by '
ee.ee_exception.EEException: Please authorize access to your Earth Engine account by running

earthengine authenticate

in your command line, and then retry.

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "C:/PROGRA~1/QGIS3~1.12/apps/qgis/./python\qgis\utils.py", line 334, in _startPlugin
    plugins[packageName] = package.classFactory(iface)
  File "C:/Users/javad/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\ee_plugin\__init__.py", line 25, in classFactory
    from .ee_plugin import GoogleEarthEnginePlugin
  File "C:/PROGRA~1/QGIS3~1.12/apps/qgis/./python\qgis\utils.py", line 744, in _import
    mod = _builtin_import(name, globals, locals, fromlist, level)
  File "C:/Users/javad/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\ee_plugin\ee_plugin.py", line 26, in 
    ee_plugin.ee_auth.init()
  File "C:/Users/javad/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\ee_plugin\ee_auth.py", line 21, in init
    authenticate()
  File "C:/Users/javad/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\ee_plugin\ee_auth.py", line 32, in authenticate
    auth_url = ee.oauth.get_authorization_url()
TypeError: get_authorization_url() missing 1 required positional argument: 'code_challenge'


Python version: 3.7.0 (v3.7.0:1bf9cc5093, Jun 27 2018, 04:59:51) [MSC v.1914 64 bit (AMD64)] 
QGIS version: 3.12.0-București București, cd141490ec 

Python Path:
C:/PROGRA~1/QGIS3~1.12/apps/qgis/./python
C:/Users/javad/AppData/Roaming/QGIS/QGIS3\profiles\default/python
C:/Users/javad/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins
C:/PROGRA~1/QGIS3~1.12/apps/qgis/./python/plugins
C:\PROGRA~1\QGIS3~1.12\apps\Python37
C:\PROGRA~1\QGIS3~1.12\apps\Python37\Scripts
C:\PROGRA~1\QGIS3~1.12\bin\python37.zip
C:\PROGRA~1\QGIS3~1.12\apps\Python37\DLLs
C:\PROGRA~1\QGIS3~1.12\apps\Python37\lib
C:\PROGRA~1\QGIS3~1.12\bin
C:\Users\javad\AppData\Roaming\Python\Python37\site-packages
C:\PROGRA~1\QGIS3~1.12\apps\Python37\lib\site-packages
C:\PROGRA~1\QGIS3~1.12\apps\Python37\lib\site-packages\win32
C:\PROGRA~1\QGIS3~1.12\apps\Python37\lib\site-packages\win32\lib
C:\PROGRA~1\QGIS3~1.12\apps\Python37\lib\site-packages\Pythonwin
C:/Users/javad/AppData/Roaming/QGIS/QGIS3\profiles\default/python
C:/Users/javad/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\qgis2web
C:\Users\javad\AppData\Roaming\QGIS\QGIS3\profiles\default\python\plugins
C:/Users/javad/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\qgis_resource_sharing
C:\Users\javad\AppData\Roaming\QGIS\QGIS3\profiles\default\python\plugins\qgis_resource_sharing
C:\Users\javad\AppData\Roaming\QGIS\QGIS3\profiles\default\python\plugins\qgis_resource_sharing\ext_libs
.
D:/javad/Documents/Work/hydrotech toos/QuickOSM-municipality
C:\Users\javad\AppData\Roaming\QGIS\QGIS3\profiles\default\python\plugins\ee_plugin\extlibs_windows

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:18

github_iconTop GitHub Comments

1reaction
XavierCLLcommented, Aug 6, 2020

are you through a proxy? In your scripts, configure proxy settings on top of them:

import os
os.environ['HTTP_PROXY'] = 'http://[username:password@]<ip_address_or_domain>:<port>'
os.environ['HTTPS_PROXY'] = 'http://[username:password@]<ip_address_or_domain>:<port>'

import ee
from ee_plugin import Map

check the FAQ https://github.com/gee-community/qgis-earthengine-plugin#faq

1reaction
XavierCLLcommented, Aug 5, 2020

@M-Rezvanpour yes now, could you please test with this zip (I couldn’t reproduce it then I’m not sure if with this changes fix the problem): https://drive.google.com/file/d/1x8QCQ-5CzjQEk-cNEyMU87Xz5S8LaR7s/view?usp=sharing

Read more comments on GitHub >

github_iconTop Results From Across the Web

can't activate plugin - WordPress.org
I have deleted the plugin in my wordpress dashboard, installed it again but when I want to activate it I get the same...
Read more >
Fix Plugin Could Not Be Activated Because It Triggered a ...
Plugin Could Not Be Activated Because It Triggered a Fatal Error:- This error occurs when you are trying to install the older version...
Read more >
WordPress Problem: Can Not Activate a Plugin
WordPress: Activating a Plugin Manually · 1. Attempt to reactivate using functions.php · 2. Add your plugin to the WordPress “Must Use” folder....
Read more >
I can't activate new plugins on MPC ONE
When I log into the "Activate Plugins" screen, I used the account I ... and so I couldn't recieve any serial and couldn't...
Read more >
Connect & activate your license - Elementor
Try to reconnect” error, or any similar “Error Occurred” message, when attempting to activate Pro, please go to Settings > General and check...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found