[fix] this error can also occur and is fixed by regenerating the cache https://paste.yunohost.org/uvojidumik.rb (reported from support chan)

This commit is contained in:
Laurent Peuch 2018-07-20 14:11:29 +02:00
parent 9bf2642539
commit cbd2c1611c

View file

@ -391,7 +391,7 @@ class ActionsMap(object):
with open(actionsmap_pkl) as f:
actionsmaps[n] = pickle.load(f)
# TODO: Switch to python3 and catch proper exception
except IOError:
except (IOError, EOFError):
self.use_cache = False
actionsmaps = self.generate_cache(namespaces)
elif use_cache: # cached file doesn't exists