Name the cause when an OSError has no strerror

This commit is contained in:
2026-10-02 07:40:12 +02:00
parent ce9c96c57c
commit 041fb8b98d
+1 -1
View File
@@ -46,5 +46,5 @@ def delete_session(session: Session) -> Failure | None:
try:
shutil.rmtree(sibling) if os.path.isdir(sibling) else os.remove(sibling)
except OSError as failure:
return Failure(f"could not delete {sibling}: {failure.strerror}; delete {stem}* and rerun loop-claude, or the next chunk resumes the finished chunk's session")
return Failure(f"could not delete {sibling}: {failure.strerror or failure}; delete {stem}* and rerun loop-claude, or the next chunk resumes the finished chunk's session")
return None