Node 10.4.0 emits noisy warning about Buffer

(Mike Taylor) #1

Every node program I run – e.g. yarn – begins by emitting this noisy warning: “(node:45508) [DEP0005] DeprecationWarning: Buffer() is deprecated due to security and usability issues. Please use the Buffer.alloc(), Buffer.allocUnsafe(), or Buffer.from() methods instead.”

I assume that this must have been fixed in Node itself by now. Is there a procedure for getting the Homebrew package updated to use the fixed version?

(Sean Molenaar) #2

You can make a pull request on the formula

(Mike Taylor) #3

Thanks, I’ll look into it.

BTW., for anyone else suffering under this, I found a way to shut it up: the node command-line argument --no-deprecation stops it from whining, and you can get node to run that way by default if you set the NODE_OPTIONS environment variable to --no-deprecation.