make os mv and cp commands non interactive (#430)

- fix(fs): handle NFS permission errors with robust fallback - Catch
PermissionError/OSError(EPERM) in atomic_move and atomic_copy -
Implement layered fallback: shutil.copyfile (content only) -> system
mv/cp - Add _perform_nfs_fallback and _system_op helpers to reduce
duplication - Set fallback logging to DEBUG to reduce spam on NFS mounts
- make os mv and cp commands non interactive (-f)
This commit is contained in:
CaliBrain
2026-01-13 00:08:49 -05:00
committed by GitHub
parent 1ca80e8b6f
commit 92b8323a8b
+1 -1
View File
@@ -63,7 +63,7 @@ def _system_op(op: str, source: Path, dest: Path) -> None:
"""Execute system command (mv or cp) as final fallback."""
logger.info(f"Attempting system {op} as final fallback: {source} -> {dest}")
subprocess.run(
[op, str(source), str(dest)],
[op, "-f", str(source), str(dest)],
check=True,
capture_output=True,
text=True