2
0
Эх сурвалжийг харах

Remove non-existent argument to Path

'mode' is not a valid argument to (Pure)Path. Passing keyword arguments is
deprecated since Python 3.12. I don't suspect it ever did anything. It is
removed in Python 3.14.

Without this patch, borgmatic crashes on Python 3.14.

This code was first introduced in e76bfa555fbab360a512c378e185707037d912ce.
Carmen Bianca BAKKER 1 сар өмнө
parent
commit
2b34c62e6f

+ 1 - 1
borgmatic/actions/check.py

@@ -246,7 +246,7 @@ def write_check_time(path):  # pragma: no cover
     logger.debug(f'Writing check time at {path}')
     logger.debug(f'Writing check time at {path}')
 
 
     os.makedirs(os.path.dirname(path), mode=0o700, exist_ok=True)
     os.makedirs(os.path.dirname(path), mode=0o700, exist_ok=True)
-    pathlib.Path(path, mode=0o600).touch()
+    pathlib.Path(path).touch(mode=0o600)
 
 
 
 
 def read_check_time(path):
 def read_check_time(path):