Skip to content

Conversation

@mistic
Copy link
Collaborator

@mistic mistic commented Dec 13, 2018

This is a revisit for #36
I just merged the branch present in the mentioned PR, applied the suggested review by @evilebottnawi. I had to rebase and amend the commits in order to proceed with this PR forward.

This is the list of changes on this PR:

  • Listen for end events
  • Fix compilation on Node > 8
  • Run canary ci on node 6

In the event that the read stream terminates before all of the data
has been read, the pipe will send an 'end' event. We should listen for
this event and hit the callback with it, instead of hanging forever.

Added tests to verify this. Verified the patch fixes the problem by
running the tests without the patch, observing that they timeout, then
running the tests with the patch and verifying you get an error back.
Attempting to run "npm install" on a new-ish Mac with Node v10.11
fails with a number of node-gyp compilation failures. Installing and
using the latest versions of node-sass, nan, and fsevents resolves
this failure, as each of those packages resolves the issues that led
to problems.

Update lodash to v4.17.11 to fix a security warning present in the
Travis CI configuration.

Add Node 10 to the build matrix so we can test for it.

I am nervous about the number of changes to package-lock.json and I am
not sure how to mitigate that - apparently NPM 6 changed the way
requirements are stored in the file so we'll just have to do this at
some point. npm/npm#20434
@alexander-akait
Copy link
Member

@mistic Looks good, remove nsp from deps and change "security": "nsp check", on "security": "npm audit", and we can merge this

@codecov
Copy link

codecov bot commented Dec 13, 2018

Codecov Report

Merging #42 into master will increase coverage by 0.26%.
The diff coverage is 25%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master      #42      +/-   ##
==========================================
+ Coverage   16.99%   17.26%   +0.26%     
==========================================
  Files           7        7              
  Lines         353      365      +12     
  Branches       58       60       +2     
==========================================
+ Hits           60       63       +3     
- Misses        261      268       +7     
- Partials       32       34       +2
Impacted Files Coverage Δ
src/readBuffer.js 33.33% <25%> (-4.17%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update fcbd813...3c6d0f4. Read the comment docs.

@mistic
Copy link
Collaborator Author

mistic commented Dec 13, 2018

@evilebottnawi done

@mistic mistic changed the title Listen end events Listen end events and replace nsp with npm audit Dec 13, 2018
@mistic mistic closed this Dec 14, 2018
@mistic mistic changed the title Listen end events and replace nsp with npm audit Listen end events Dec 18, 2018
@mistic mistic reopened this Dec 18, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants