planetfederal / qgis-geoserver-plugin

GNU General Public License v2.0
62 stars 52 forks source link

error when a store/layer is not available anymore #56

Closed gioman closed 7 years ago

gioman commented 7 years ago

It can happen that a resource like a store becomes unavailable maybe because was deleted using the Geosever control panel. If the Geoserver Explorer tree is not refreshed clicking on such resource can lead to errors like

An error has occurred while executing Python code: 

FailedRequestError: Tried to make a GET request to http://192.168.43.237:8080/geoserver/rest/workspaces/opengeo/coveragestores/aaa.xml but got a 404 status code: No such coverage store: opengeo,aaa 
Traceback (most recent call last):
  File "C:/Users/qgis/.qgis2/python/plugins\geoserverexplorer\gui\explorertree.py", line 75, in treeItemClicked
    widget = item.descriptionWidget(self, self.explorer)
  File "C:/Users/qgis/.qgis2/python/plugins\geoserverexplorer\gui\exploreritems.py", line 32, in descriptionWidget
    text = self.getDescriptionHtml(tree, explorer)
  File "C:/Users/qgis/.qgis2/python/plugins\geoserverexplorer\gui\exploreritems.py", line 47, in getDescriptionHtml
    html += self._getDescriptionHtml(tree, explorer)
  File "C:/Users/qgis/.qgis2/python/plugins\geoserverexplorer\gui\gsexploreritems.py", line 1335, in _getDescriptionHtml
    html += '