amemv-crawler icon indicating copy to clipboard operation
amemv-crawler copied to clipboard

建议:下载时刷新缓存

Open happyli0826 opened this issue 6 years ago • 0 comments

        with open(file_path, 'wb') as fh:
            for chunk in resp.iter_content(chunk_size=1024):
                fh.write(chunk)
                fh.flush()  # add  增加刷新缓存立即写入硬盘,大量下载时内存占用过高

happyli0826 avatar Dec 07 '18 03:12 happyli0826