Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use Browserify 17 #224

Open
m90 opened this issue May 26, 2021 · 1 comment
Open

Use Browserify 17 #224

m90 opened this issue May 26, 2021 · 1 comment

Comments

@m90
Copy link
Collaborator

m90 commented May 26, 2021

Ideally, Mochify would use Browserify 17 (instead of 16 at the time of writing) to keep in sync with maintained versions of the underlying tools.


Picking up the comment here: #223 (comment) I looked into why such an update from 16 to 17 is breaking Mochify and found out the following (this issue is mostly about collecting what I found out for whenever this updates becomes required for some reason):

  1. There is yet another new deprecation warning about the usage of SharedArrayBuffer that litters stderr, but that can be swallowed just as Mochify already does with other deprecation messages. (SharedArrayBuffer changes in Chrome 91+ browserify/node-util#58)
  2. After muting these warnings, the tests for --no-detect-globals fail because of the following:
    Browserify 17 updates util to 0.12 Upgrade util to v0.12.0. browserify/browserify#1844, containing this commit browserify/node-util@6b82825 which is reading process.env.NODE_DEBUG without checking whether process is even defined. This means that when passing the option not to shim globals to browserify, any code that requires util (Mocha for example) will fail with an Uncaught ReferenceError: process is not defined

I'm not entirely sure if this is something that could be or should be worked around in Mochify or if this is something that is to be considered an upstream bug in either node-util or browserify. Mochify could of course also drop the --no-detect-globals flag again but this would mean #208 comes back to life.

@m90
Copy link
Collaborator Author

m90 commented May 27, 2021

There's an issue in node-util about this browserify/node-util#43

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

No branches or pull requests

1 participant