planetfederal / qgis-geogiglight-plugin

GNU General Public License v2.0
19 stars 9 forks source link

removing all branches corrupts a repository(?) #22

Closed gioman closed 8 years ago

gioman commented 8 years ago
Plugin version: 1.0-20160720-342d01cc7f1f2b21a9abe90c346a836a31a1c2c7
Traceback (most recent call last):
  File "C:/Users/qgis/.qgis2/python/plugins\geogig\layeractions.py", line 170, in addLayer
    dlg = ImportDialog(config.iface.mainWindow(), layer = layer)
  File "C:/Users/qgis/.qgis2/python/plugins\geogig\gui\dialogs\importdialog.py", line 49, in __init__
    self.initGui()
  File "C:/Users/qgis/.qgis2/python/plugins\geogig\gui\dialogs\importdialog.py", line 77, in initGui
    self.branches = self.repo.branches() if self.repo is not None else repos[0].branches()
  File "C:/Users/qgis/.qgis2/python/plugins\geogig\geogigwebapi\repository.py", line 151, in branches
    resp = self._apicall("branch", {"list":True})
  File "C:/Users/qgis/.qgis2/python/plugins\geogig\geogigwebapi\repository.py", line 148, in _apicall
    return execute(lambda: self.__apicall(command, payload, transaction))
  File "C:/Users/qgis/.qgis2/python/plugins\geogig\gui\executor.py", line 69, in execute
    return func()
  File "C:/Users/qgis/.qgis2/python/plugins\geogig\geogigwebapi\repository.py", line 148, in <lambda>
    return execute(lambda: self.__apicall(command, payload, transaction))
  File "C:/Users/qgis/.qgis2/python/plugins\geogig\geogigwebapi\repository.py", line 138, in __apicall
    r.raise_for_status()
  File "C:\Users\qgis\.qgis2\python\plugins\geogig\ext-libs\requests-2.9.1-py2.7.egg\requests\models.py", line 840, in raise_for_status
    raise HTTPError(http_error_msg, response=self)
HTTPError: 500 Server Error: Internal Server Error for url: http://192.168.186.253:8182/repos/repos/branch?output_format=json&list=True
An error occurred while fetching repository data! See the logs for details.

that in the log corresponds to

An error occurred while fetching repository data! 500 Server Error: Internal Server Error for url: http://192.168.186.253:8182/repos/repos/ls-tree?path=HEAD&output_format=json&onlyTrees=True

then I have not been able to use again the repository.

gioman commented 8 years ago

Fix ok, seems reasonable to not be possible to delete a branch if this is the only one in the repo.