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

Unify utility Reader/Writer types into internalio #145

Closed
masih opened this issue Jul 8, 2021 · 2 comments · Fixed by #173
Closed

Unify utility Reader/Writer types into internalio #145

masih opened this issue Jul 8, 2021 · 2 comments · Fixed by #173
Assignees
Labels
P3 Low: Not priority right now v2-before-release
Milestone

Comments

@masih
Copy link
Member

masih commented Jul 8, 2021

should this live in internal/io?

Originally posted by @willscott in #144 (comment)

@masih masih added the P3 Low: Not priority right now label Jul 8, 2021
@masih masih added this to the CAR v2 milestone Jul 8, 2021
masih added a commit that referenced this issue Jul 15, 2021
Implement the ability to generate index from a CARv1 payload given only
an `io.Reader`, where the previous implementation required
`io.ReadSeeker`. The rationale is to be minimal in what we expect in the
API, since index generation from a CARv1 payload never need to rewind
the reader and only moves forward in the stream.

Refactor utility IO functions that convert between types in one place.
Implement constructor functions that only instantiate wrappers when the
passed argument does not satisfy a required interface.

Fixes:
- #146

Relates to:
- #145
@masih masih self-assigned this Jul 16, 2021
@masih masih linked a pull request Jul 16, 2021 that will close this issue
@masih
Copy link
Member Author

masih commented Jul 16, 2021

Resolved by #173

mvdan pushed a commit that referenced this issue Jul 16, 2021
Improve reader type conversion by checking if type satisfies
ReaderAt to avoid unnecessary wrapping.

Move io converters into one place.

Fixes:
- #145
@mvdan
Copy link
Contributor

mvdan commented Jul 16, 2021

Merged.

@mvdan mvdan closed this as completed Jul 16, 2021
mvdan pushed a commit that referenced this issue Jul 16, 2021
Implement the ability to generate index from a CARv1 payload given only
an `io.Reader`, where the previous implementation required
`io.ReadSeeker`. The rationale is to be minimal in what we expect in the
API, since index generation from a CARv1 payload never need to rewind
the reader and only moves forward in the stream.

Refactor utility IO functions that convert between types in one place.
Implement constructor functions that only instantiate wrappers when the
passed argument does not satisfy a required interface.

Fixes:
- #146

Relates to:
- #145
mvdan pushed a commit that referenced this issue Jul 16, 2021
Improve reader type conversion by checking if type satisfies
ReaderAt to avoid unnecessary wrapping.

Move io converters into one place.

Fixes:
- #145
Jorropo pushed a commit to ipfs/boxo that referenced this issue Mar 22, 2023
Implement the ability to generate index from a CARv1 payload given only
an `io.Reader`, where the previous implementation required
`io.ReadSeeker`. The rationale is to be minimal in what we expect in the
API, since index generation from a CARv1 payload never need to rewind
the reader and only moves forward in the stream.

Refactor utility IO functions that convert between types in one place.
Implement constructor functions that only instantiate wrappers when the
passed argument does not satisfy a required interface.

Fixes:
- ipld/go-car#146

Relates to:
- ipld/go-car#145


This commit was moved from ipld/go-car@6b085bc
Jorropo pushed a commit to ipfs/boxo that referenced this issue Mar 22, 2023
Improve reader type conversion by checking if type satisfies
ReaderAt to avoid unnecessary wrapping.

Move io converters into one place.

Fixes:
- ipld/go-car#145


This commit was moved from ipld/go-car@f3fc595
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
P3 Low: Not priority right now v2-before-release
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants