-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
Pushing a stream to 'wrap' in the internal pipeline broke in 9.0.5 #1200
Comments
Probably the same problem that I have with browserify >9.0.2 and merging streams in gulp. |
Making the output bundle read-only had no effect on I tried creating a reproducible case (front the root directory of node-browserify), and was unable to reproduce your report, I got the expected amount of "hello world"s, and a single "hello, spawn". |
@terinjokes Thanks for looking into this. The only reproducible example that I know currently is the Mochify test suite (https://github.com/mantoni/mochify.js). I nailed browserify to v9.0.4 to make the tests pass. Upgrading browserify to any newer version causes half the test suite to fail. Since the only change seems to be the one that makes the pipeline readonly, I suspected it must have something to do with that. |
I had to update the way I use gulp after browserify 9.0.5. I used the following recipe for hints: |
@jokeyrhyme, how do you do it now? I used to combine JSHint and Browserify in the way that doesn't work now because of read-only stream. Probably I should learn how streams work, but well... (lazy programmer mode on). Anyway, I do it like that: gulp.src(files)
.pipe(jshint())
.pipe(bundler.bundle())
.pipe(source(bundleName))
.pipe(gulp.dest(bundleDir)) Seemed reasonable until that breaking change... |
I worked around the issue by using the browserify pipeline directly: mantoni/mochify.js@efaf1b3 This is fine in my case since I'm extending the pipeline anyway. Still this feels wrong to me. |
@erykpiast oh, that recipe I linked is working perfectly for me now: https://github.com/gulpjs/gulp/blob/master/docs/recipes/browserify-transforms.md The original version of that guide was what I started with ages ago, and that version of the guide no longer works after browserify 9.0.5: https://github.com/gulpjs/gulp/blob/064e2fceb96/docs/recipes/browserify-transforms.md |
Ok, get it, thank you! I have a problem because of JSHint, so I guess I have to fix that in some other way. |
For reasons that are beyond my understanding, this is not an issue anymore with |
Making the output bundle readonly seems to break a feature that is very important to Mochify (See issue mantoni/mochify.js#80).
When I push a stream to
b.pipeline.get('wrap')
, the stream is not part of the browserify output. The pipeline modification is done before the call tobundle()
.Please advice if there is anything I can do to work around the issue.
The text was updated successfully, but these errors were encountered: