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
Add seek call after sf.info #942
Conversation
I think we should have a unit test for this regardless of if it's a bug (or otherwise undocumented behavior in soundfile). |
@bmcfee I added the code path to |
Thanks for doing this! I think the best way to handle setup/teardown is with a pytest fixture. Something like what's described here: https://docs.pytest.org/en/latest/fixture.html#fixture-finalization-executing-teardown-code |
Believe this is ready for merge, @bmcfee and @lostanlen |
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.
Thanks @carlthome , this looks great! I had two last nitpicks, noted below.
LGTM! Thanks for all your work on this one! |
Reference Issue
Fixes #941
What does this implement/fix? Explain your changes.
Rewinds the read position in
librosa.stream
in case the input is a file handle.Any other comments?
Perhaps a unit test should be added for this as well? I'm also curious if this is really something
librosa
should handle or if it's actually a mistake insoundfile.info
?