Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adjusted local-to-remote copy with folders #308

Merged
merged 1 commit into from
Dec 8, 2023

Conversation

GlassOfWhiskey
Copy link
Member

The local-to-remote copy was failing when trying to copy a folder with multiple files, as only the first file was actually tansferred. This commit solves this issue by modifying the aiotarstream module to deal with tell and seek operations, allowing to position the stream pointer in the correct position.

In detail, two new classes have been implemented:

  • TellableStreamWrapper, which keeps track of the actual stream pointer position;
  • SeekableStreamReaderWrapper, which allows forward seek operations in a stream reader.

Note that these classes are internal to the aiotarstram module, so nothing changes in the publicly exposed API.

The local-to-remote copy was failing when trying to copy a folder with
multiple files, as only the first file was actually tansferred. This
commit solves this issue by modifying the `aiotarstream` module to deal
with `tell` and `seek` operations, allowing to position the stream
pointer in the correct position.

In detail, two new classes have been implemented:

- `TellableStreamWrapper`, which keeps track of the actual stream
   pointer position;
- `SeekableStreamReaderWrapper`, which allows forward seek operations
  in a stream reader.

Note that these classes are internal to the `aiotarstram` module, so
nothing changes in the publicly exposed API.
@GlassOfWhiskey GlassOfWhiskey merged commit a492ae2 into master Dec 8, 2023
31 checks passed
@GlassOfWhiskey GlassOfWhiskey deleted the fix-remote-to-local-dirs branch December 8, 2023 10:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant