Skip to content

fix: the file handler is close properly and wrap into a context manager#609

Merged
JoanFM merged 1 commit intomainfrom
fix-close-file-audio-load
Oct 11, 2022
Merged

fix: the file handler is close properly and wrap into a context manager#609
JoanFM merged 1 commit intomainfrom
fix-close-file-audio-load

Conversation

@samsja
Copy link
Copy Markdown
Member

@samsja samsja commented Oct 11, 2022

Context

atm when calling load_uri_to_audio_tensor we open a file but don't close it.

This PR enforce the closing behavior

@codecov
Copy link
Copy Markdown

codecov bot commented Oct 11, 2022

Codecov Report

Merging #609 (6221b78) into main (1e5ff36) will not change coverage.
The diff coverage is 73.33%.

@@           Coverage Diff           @@
##             main     #609   +/-   ##
=======================================
  Coverage   84.92%   84.92%           
=======================================
  Files         133      133           
  Lines        6715     6715           
=======================================
  Hits         5703     5703           
  Misses       1012     1012           
Flag Coverage Δ
docarray 84.92% <73.33%> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
docarray/document/mixins/audio.py 84.37% <73.33%> (ø)
docarray/array/mixins/plot.py 28.13% <0.00%> (-0.44%) ⬇️
docarray/array/storage/weaviate/find.py 84.81% <0.00%> (+1.26%) ⬆️

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants