I ran the config_vars.py script and verified in Heroku that the config var exists with the correct content. However, the app fails to run. I added --debug flag in Procfila for voila and this is what I get:
FileNotFoundError Traceback (most recent call last)
~/.heroku/python/lib/python3.8/site-packages/ee/data.py in get_persistent_credentials()
218 try:
--> 219 tokens = json.load(open(oauth.get_credentials_path()))
220 refresh_token = tokens['refresh_token']
FileNotFoundError: [Errno 2] No such file or directory: '/app/.config/earthengine/credentials'
During handling of the above exception, another exception occurred:
EEException Traceback (most recent call last)
<ipython-input-1-44c582ebe6c9> in <module>
11
12 #ee.Authenticate()
---> 13 ee.Initialize()
~/.heroku/python/lib/python3.8/site-packages/ee/__init__.py in Initialize(credentials, opt_url, cloud_api_key, http_transport, project)
113 """
114 if credentials == 'persistent':
--> 115 credentials = data.get_persistent_credentials()
116 data.initialize(
117 credentials=credentials,
~/.heroku/python/lib/python3.8/site-packages/ee/data.py in get_persistent_credentials()
227 scopes=oauth.SCOPES)
228 except IOError:
--> 229 raise ee_exception.EEException(
230 'Please authorize access to your Earth Engine account by '
231 'running\n\nearthengine authenticate\n\nin your command line, and then '
EEException: Please authorize access to your Earth Engine account by running
earthengine authenticate
in your command line, and then retry.
I wonder if something has change in the python ee library or why the authentication doesn't seem to work.
I ran the config_vars.py script and verified in Heroku that the config var exists with the correct content. However, the app fails to run. I added --debug flag in Procfila for voila and this is what I get:
I wonder if something has change in the python ee library or why the authentication doesn't seem to work.