MCPcopy Create free account
hub / github.com/vastsa/FileCodeBox / clean_chunks

Method clean_chunks

core/storage.py:834–840  ·  view source on GitHub ↗

清理 OneDrive 上的临时分片文件

(self, upload_id: str, save_path: str)

Source from the content-addressed store, hash-verified

832 raise e
833
834 async def clean_chunks(self, upload_id: str, save_path: str):
835 """清理 OneDrive 上的临时分片文件"""
836 chunk_dir = str(Path(save_path).parent / "chunks" / upload_id)
837 try:
838 await asyncio.to_thread(self._delete_chunk_dir, chunk_dir)
839 except Exception as e:
840 logger.info(f"清理 OneDrive 分片时出错: {e}")
841
842 def _file_exists(self, save_path: str) -> bool:
843 """同步检查文件是否存在"""

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected