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

Convert ReadSubjectFile to a FS #131

Open
MattWindsor91 opened this issue Feb 17, 2021 · 0 comments
Open

Convert ReadSubjectFile to a FS #131

MattWindsor91 opened this issue Feb 17, 2021 · 0 comments
Labels
enhancement New feature or request

Comments

@MattWindsor91
Copy link
Collaborator

ReadSubjectFile is a function that does not spark joy. It is intended to behave like a call to os.Open, except that, in certain cases, it can traverse inside a tarball and pretend that tarball is transparently part of the filesystem. Its main reason for existence is to deal with the fact that plans can refer to files that only exist inside tarred snapshots of failed tests.

This feels like a useful example of where go1.16's FS could be useful: we can write a FS that behaves like a real filesystem most of the time but, if asked to go into a directory that is actually a tarball, delegates to something like tarfs instead.

In fact, we could probably replace current read-only uses of tarballs with such an FS.

@MattWindsor91 MattWindsor91 added the enhancement New feature or request label Feb 17, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant