iterative / iterative/PyDrive2
fs.cp_file: out of memory error (don't store file in RAM)
- Lingua principale
- Python
- Stelle
- 670
- Fork
- 75
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Descrizione
https://github.com/iterative/PyDrive2/blob/378c6e80471d44f4164e64a178efc2f06ecae882/pydrive2/fs/spec.py#L358-L365
ref. https://github.com/iterative/PyDrive2/pull/119#pullrequestreview-753066960 suggestion:
> ```diff
> - """In-memory streamed copy"""
> - with self.open(lpath) as stream:
> - # IterStream objects doesn't support full-length
> - # seek() calls, so we have to wrap the data with
> - # an external buffer.
> - buffer = io.BytesIO(stream.read())
> - self.upload_fobj(buffer, rpath)
> + with self.open(lpath) as stream:
> + self.upload_fobj(stream, rpath)
> ```
>
> and fix `self.open` to return a proper stream.
Guida per i contributori
Apri la guida per i contributori
Valutazione
Questa issue non è ancora stata valutata.