mirror of
https://github.com/home-assistant/supervisor.git
synced 2025-07-26 18:46:29 +00:00
Revert "Fix add-on store reset"
This reverts commit da8c6cf1117e1b3d9522a293912376f5d455b389.
This commit is contained in:
parent
da8c6cf111
commit
5733db94aa
@ -1,6 +1,5 @@
|
|||||||
"""Helpers to check and fix issues with free space."""
|
"""Helpers to check and fix issues with free space."""
|
||||||
|
|
||||||
from functools import partial
|
|
||||||
import logging
|
import logging
|
||||||
|
|
||||||
from ...coresys import CoreSys
|
from ...coresys import CoreSys
|
||||||
@ -41,9 +40,7 @@ class FixupStoreExecuteReset(FixupBase):
|
|||||||
_LOGGER.warning("Can't find store %s for fixup", reference)
|
_LOGGER.warning("Can't find store %s for fixup", reference)
|
||||||
return
|
return
|
||||||
|
|
||||||
await self.sys_run_in_executor(
|
await self.sys_run_in_executor(remove_folder, repository.git.path)
|
||||||
partial(remove_folder, folder=repository.git.path, content_only=True)
|
|
||||||
)
|
|
||||||
|
|
||||||
# Load data again
|
# Load data again
|
||||||
try:
|
try:
|
||||||
|
@ -106,7 +106,8 @@ def remove_folder(
|
|||||||
except OSError as err:
|
except OSError as err:
|
||||||
_LOGGER.exception("Can't remove folder %s: %s", folder, err)
|
_LOGGER.exception("Can't remove folder %s: %s", folder, err)
|
||||||
except subprocess.CalledProcessError as procerr:
|
except subprocess.CalledProcessError as procerr:
|
||||||
_LOGGER.critical("Can't remove folder %s: %s", folder, procerr.stderr.strip())
|
_LOGGER.error("Can't remove folder %s: %s", folder, procerr.stderr.strip())
|
||||||
|
raise procerr
|
||||||
|
|
||||||
|
|
||||||
def remove_folder_with_excludes(
|
def remove_folder_with_excludes(
|
||||||
|
Loading…
x
Reference in New Issue
Block a user