-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
chore: replace browserify
with rollup
#1632
Conversation
Codecov ReportPatch coverage:
Additional details and impacted files@@ Coverage Diff @@
## main #1632 +/- ##
==========================================
- Coverage 85.74% 81.11% -4.64%
==========================================
Files 13 21 +8
Lines 1249 1366 +117
Branches 0 324 +324
==========================================
+ Hits 1071 1108 +37
- Misses 178 181 +3
- Partials 0 77 +77
☔ View full report in Codecov by Sentry. |
@vishnureddy17 @BertKleewein I made some changes here but I still get this error when i run the browser test:
Seems that rollup output boundle makes some strange tweaks on mqtt-packet. In that line Couldn't find anything to fix this issue, I just found a possible reference to it here: vitejs/vite#9703 but it doesn't solve the issue |
Consider also replacing terser with a rollup pluigin: https://rollupjs.org/configuration-options/#output-plugins |
Unfortunately, my knowledge on browser JS and and bundling is very limited :/ |
The In other words, callers can choose to do either One fix is to update the If you make this change to |
Thanks for the explanation @BertKleewein ! Anyway I also opened an issue on rollup yesterday and turns out that's a bug with rollup commonjs plugin... sad story this is my first time using rollup and I also found a bug, good news is that the user that answered my issue also created this PR to fix it. Hope it will not take too much time. I will also try to see if I can fix the readable-stream issue Some references to readable-stream error: |
Ok some steps forward. I used @BertKleewein suggestion to fix the mqtt-packet parser issue, I firstly tried by using rollup
Not sure if that's related to some compatibility issues with the |
With debug enabled:
Ok first problem seems that
fails as |
@robertsLando - This looks like the same behavior I saw when patched mqtt-packet and readable-stream. Thanks for confirming that you see the same thing. It smells like it's maybe related to some of the |
@BertKleewein I'm planning to do a PR that moves client pakcets handlers outside like aedes does: https://github.com/moscajs/aedes/tree/main/lib/handlers Hope that will not be so hard BTW... My plans are to refactor client piece by piece without breaking too much stuff |
@getlarge ever used rollup ? :) I'm a bit lost here |
Never did sorry! Still stuck ? |
@getlarge it seems to have better support for modern browsers |
…into rollup-browserify
Supersided by #1658 |
No description provided.