WyriHaximus · GitHub

@WyriHaximus

Copy link Copy Markdown

Member

Currently unlike ReadableResourceStream the WritableResourceStream doesn't automatically closes the underlying stream resource with fclose. This PR aims to add that, but as of creating this PR two tests fail, purposely not updated tests to discuss how to handle those here before fixing them.

@WyriHaximus

@WyriHaximus

Merged

@clue

Copy link Copy Markdown

Member

Thanks for spotting this bug and filing this PR! 👍 I agree that your suggested fix makes sense and the two tests need to be updated because they rely on some rather pointless assumptions.

One possible option would be using a writer filter function instead of rewinding after close. Does this make sense to you?

@WyriHaximus

Copy link Copy Markdown

Member Author

One possible option would be using a writer filter function instead of rewinding after close. Does this make sense to you?

The idea makes sense, not sure yet how to implement that right now.

…table stream

@WyriHaximus

Copy link Copy Markdown

Member Author

Doh your package make it very easy ❤️ !

Ping @clue and @jsor, tests have been fixed and are green across the board.

clue

clue approved these changes Jun 13, 2017

jsor

jsor approved these changes Jun 14, 2017

@WyriHaximus

@WyriHaximus

Copy link Copy Markdown

Member Author

🎉

@clue clue mentioned this pull request

Oct 10, 2017

Merged

Read the original on github.com ↗