-
Notifications
You must be signed in to change notification settings - Fork 74
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
FIX, ENH: Handle nested archive members; allow arbitrary unpack locations #224
FIX, ENH: Handle nested archive members; allow arbitrary unpack locations #224
Conversation
💖 Thanks for opening your first pull request! 💖 Please make sure you read the following:
A few things to keep in mind:
|
992c1dd
to
f9f8dc7
Compare
This is ready for review. I'll need a little advice on testing/coverage; I thought that I could just change this line to use On a side note, |
@drammock thanks for the issue and PR! Life's a bit hectic at the moment so I'll be a little while before I can review this. If anyone else wants to have a go, they are more than welcome 🙂
Maybe something with the Python environment that is running each? This is the first I'm hearing of something like this which is very odd.
This is a bug in our code that when we go to save the file to the filesystem, we don't create missing parent directories like |
That is exactly the problem that I thought I fixed in this PR (point number 1 in the PR description). And it seems to be working in my local testing with my own data, but it's not working with the sample testing data included with Pooch.
I thought that's what these lines do: |
OK, I figured out how to write the correct test so that the new code has 100% coverage. But now all the windows CIs are failing because (I think) Also, the various tests in |
fc7f5af
to
ef96a24
Compare
OK @leouieda I've managed to get all the tests to pass now, and also removed some of the redundancy in the processors test by using multiple |
bump. Over at MNE-Python we want to switch to using pooch, but need the functionality in this PR to make it possible. All tests are passing... any idea how long we're likely to have to wait? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@drammock sorry for the very long delay on this. It's been a tough semester.
Just found some time to review this and it looks great! Thanks for the refactoring of the processor tests as well (and the typo fixes). Merging as soon as CIs are green again and I'll cut a new release in the following weeks.
🎉🎉🎉 Congrats on merging your first pull request and welcome to the team! 🎉🎉🎉 If you would like to be added as a author on the Zenodo archive of the next release, make sure that you have added your full name, affiliation, and ORCID (optional) to the We hope that this was a good experience for you. Let us know if there is any way that the contributing process could be improved. |
closes #223
This PR does two things:
members
passed to a processor reside within subfolders inside the archive, by creating the necessary destination subfolders before attempting to write the unpacked file. Previously, using a processor like thisUntar(members=['archive_internal_subfolder/desired_file.txt'])
would fail with aFileNotFoundError
.extract_dir
. Ifextract_dir
isNone
(the default) then the current suffix-based approach is used as a fallback.Reminders:
make format
andmake check
to make sure the code follows the style guide.Add new public functions/methods/classes toN/Adoc/api/index.rst
and the base__init__.py
file for the package.AUTHORS.md
file (if you haven't already) in case you'd like to be listed as an author on the Zenodo archive of the next release.