Reading 64k per chunk
This commit is contained in:
parent
77a05fd507
commit
40450c0a9a
2 changed files with 4 additions and 3 deletions
|
|
@ -21,7 +21,7 @@ repos:
|
|||
hooks:
|
||||
- id: isort
|
||||
name: isort (python)
|
||||
language_version: '3.11'
|
||||
language_version: '3.8'
|
||||
args: ['--profile', 'black', '--filter-files']
|
||||
- repo: https://github.com/psf/black
|
||||
rev: '24.1.1'
|
||||
|
|
@ -31,6 +31,6 @@ repos:
|
|||
rev: v2.3.0
|
||||
hooks:
|
||||
- id: pycln
|
||||
language_version: '3.11'
|
||||
language_version: '3.8'
|
||||
args: [--all]
|
||||
exclude: ^tests/snapshot_tests
|
||||
|
|
|
|||
|
|
@ -239,8 +239,9 @@ class Driver(ABC):
|
|||
with open(save_path, mode) as destination_file:
|
||||
read = binary.read
|
||||
write = destination_file.write
|
||||
chunk_size = 1024 * 64
|
||||
while True:
|
||||
data = read(1024)
|
||||
data = read(chunk_size)
|
||||
if not data:
|
||||
break
|
||||
write(data)
|
||||
|
|
|
|||
Loading…
Reference in a new issue