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

blob_download unnecessarily tries to connect to a peer even if the requested blob is found locally. #1947

Closed
expenses opened this issue Jan 11, 2024 · 2 comments · Fixed by #1969
Labels
bug Something isn't working c-iroh
Milestone

Comments

@expenses
Copy link
Contributor

I ran into this issue when testing the RPC interface, by taking a BlobTicket, deconstructing it, constructing a BlobDownloadRequest and calling BlobsClient::download. It's trivial to work around, simply call BlobsClient::read or BlobsClient::read_to_bytes first and use that result if you don't get an error. Perhaps this behaviour is intended, but it's a little unintuitive.

@ramfox ramfox added this to the v0.13.0 milestone Jan 11, 2024
@dignifiedquire dignifiedquire added c-iroh bug Something isn't working labels Jan 18, 2024
@dignifiedquire
Copy link
Contributor

Yes, we should avoid creating network connections if we don't actually need them

@dignifiedquire
Copy link
Contributor

This is fixed in #1962

github-merge-queue bot pushed a commit that referenced this issue Jan 23, 2024
…lly (#1969)

Avoid establishing a connection in `blobs.download` if content is
already locally available.

Closes #1947
fubuloubu pushed a commit to ApeWorX/iroh that referenced this issue Feb 21, 2024
…lly (n0-computer#1969)

Avoid establishing a connection in `blobs.download` if content is
already locally available.

Closes n0-computer#1947
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working c-iroh
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

3 participants