mafintosh / tar-stream

tar-stream is a streaming tar parser and generator.
MIT License
406 stars 92 forks source link

Buffer constructor runtime deprecation - this package emits a warning on Node 10 #79

Closed benjamingr closed 6 years ago

benjamingr commented 6 years ago

Hey from Node.js here!,

Starting on Node 10 this package will emit deprecation warnings. See this guide on what you should do in order to migrate to Buffer.alloc/Buffer.from.

See https://github.com/nodejs/node/issues/19079 for discussion around this change and why we can't make new Buffer work

mafintosh commented 6 years ago

You wanna PR a fix?

benjamingr commented 6 years ago

@mafintosh done, though there is no contributing.md or building.md so please validate that my changes are on par with your policy and I didn't break anything :)

felixrabe commented 6 years ago

As a workaround for now, I've created a ~/bin/node script that comes before (Homebrew-installed) /usr/local/bin/node in my $PATH:

#!/bin/bash

/usr/local/bin/node --no-deprecation "$@"
mafintosh commented 6 years ago

Should be fixed. There was some deps that needed updating as well :/