earthdaily / qgis-plugin

🗺️ To be able to discover, request and use aggregate imagery products based on landsat-8/9, Sentinel 2 and other sensors from within QGIS, using the <geosys/> API.
GNU General Public License v3.0
15 stars 8 forks source link

Issue creating a difference map #82

Open timlinux opened 5 years ago

timlinux commented 5 years ago

Describe the bug A clear and concise description of what the bug is.

Trying to do a difference map I get:

2019-05-03T11:08:52     WARNING    Traceback (most recent call last):
              File "/Users/timlinux/Library/Application Support/QGIS/QGIS3/profiles/Maceira/python/plugins/geosys-qgis-plugin/geosys/ui/widgets/geosys_dockwidget.py", line 536, in start_difference_map_creation
              filename, output_map_format=self.output_map_format)
              File "/Users/timlinux/Library/Application Support/QGIS/QGIS3/profiles/Maceira/python/plugins/geosys-qgis-plugin/geosys/ui/widgets/geosys_coverage_downloader.py", line 326, in create_difference_map
              proxies=QGISSettings.get_qgis_proxy())
              File "/Users/timlinux/Library/Application Support/QGIS/QGIS3/profiles/Maceira/python/plugins/geosys-qgis-plugin/geosys/bridge_api_wrapper.py", line 109, in __init__
              self.authenticated, self.authentication_message = self.authenticate()
              File "/Users/timlinux/Library/Application Support/QGIS/QGIS3/profiles/Maceira/python/plugins/geosys-qgis-plugin/geosys/bridge_api_wrapper.py", line 150, in authenticate
              self.client_secret)
              File "/Users/timlinux/Library/Application Support/QGIS/QGIS3/profiles/Maceira/python/plugins/geosys-qgis-plugin/geosys/bridge_api/connection.py", line 69, in get_access_token
              return response.json()
              File "/Applications/QGIS3.4.app/Contents/MacOS/../Resources/python/requests/models.py", line 897, in json
              return complexjson.loads(self.text, **kwargs)
              File "/Applications/QGIS3.4.app/Contents/MacOS/../Resources/python/simplejson/__init__.py", line 518, in loads
              return _default_decoder.decode(s)
              File "/Applications/QGIS3.4.app/Contents/MacOS/../Resources/python/simplejson/decoder.py", line 370, in decode
              obj, end = self.raw_decode(s)
              File "/Applications/QGIS3.4.app/Contents/MacOS/../Resources/python/simplejson/decoder.py", line 400, in raw_decode
              return self.scan_once(s, idx=_w(s, idx).end())
             simplejson.errors.JSONDecodeError: Expecting value: line 1 column 1 (char 0)
myarjunar commented 5 years ago

thanks for spotting this @timlinux . I think the problem is it somehow failed to authenticate. I will create a handler for that.