mirror of
https://github.com/FoundationAgents/MetaGPT.git
synced 2026-05-15 11:02:36 +02:00
Update: optimize universal file read ability.
This commit is contained in:
parent
6ae0a6a98b
commit
35067ab0d1
1 changed files with 1 additions and 1 deletions
|
|
@ -66,7 +66,7 @@ class File:
|
|||
try:
|
||||
chunk_size = chunk_size or cls.CHUNK_SIZE
|
||||
async with aiofiles.open(file_path, mode="rb") as reader:
|
||||
chunks = []
|
||||
chunks = list()
|
||||
while True:
|
||||
chunk = await reader.read(chunk_size)
|
||||
if not chunk:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue