mirror of
https://github.com/home-assistant/supervisor.git
synced 2025-12-24 12:29:08 +00:00
@@ -1,6 +1,5 @@
|
||||
"""Helpers to check and fix issues with free space."""
|
||||
|
||||
from functools import partial
|
||||
import logging
|
||||
|
||||
from ...coresys import CoreSys
|
||||
@@ -41,9 +40,7 @@ class FixupStoreExecuteReset(FixupBase):
|
||||
_LOGGER.warning("Can't find store %s for fixup", reference)
|
||||
return
|
||||
|
||||
await self.sys_run_in_executor(
|
||||
partial(remove_folder, folder=repository.git.path, content_only=True)
|
||||
)
|
||||
await self.sys_run_in_executor(remove_folder, repository.git.path)
|
||||
|
||||
# Load data again
|
||||
try:
|
||||
|
||||
@@ -106,7 +106,8 @@ def remove_folder(
|
||||
except OSError as err:
|
||||
_LOGGER.exception("Can't remove folder %s: %s", folder, err)
|
||||
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(
|
||||
|
||||
Reference in New Issue
Block a user