-
Notifications
You must be signed in to change notification settings - Fork 90
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
Magepack never ends process with no error #37
Comments
Running into the same issue here. Is seems like collectModules.js can't continue on line 20.
|
Same here. Can't seem to figure out what's going wrong. Anyone? |
It's not a solution, but in my case this only happens in production mode. Switching to developer mode solved the problem for now. |
Run into similar issues before, solution is to run it with --debug mode and when it shows you chromium window you can open console and check JS error.s. Usually for me it was a result of some third-party script loading forever or JS file having error in console. |
When opening with --debug i can't seem to find any weird scripts being loaded or anything being stuck... After commenting out the 'rjsResolver' bit and adding a wait(10000), it starts collecting everything. This is no solution of course, but something in the process does not seem to be working correct. |
For me this happened when minify JS was enabled. Works fine when it is disabled. |
It would be great if verbose mode levels are passed as parameters and see where it gets stuck. For some unknown reason, cannot generate config file in a project I am working (there are no JS issues on the URLs used in |
We as well are having the same issues its getting caught on third party call to google for the recaptcha. Stays on pending forever. Sometimes it comes through no problem other times it gets hung up and doesnt work. During normal testing (not in chromium browser and not trying to bundle) recaptcha loads just fine and takes less than 100ms to load. |
Any script error can cause the process to hang which is a separate issue with how errors are caught/handled. The specific error OP mentioned will result in "TypeError: require is not a function" which can happen when you go to generate again after previously bundling. Turn bundling off in magento config and flip back to developer mode to generate. Another common error I saw was page timeouts while generating. These will also result in the script hanging indefinitely and can occur randomly on category, cms, product, or checkout. The default page timeout is 30 seconds, which isn't quite generous enough for some machines to generate locally. This fix requires a code change. Our fork with it. |
This issue with "infinite loading" mostly happens when the page it's self is already loading Magepack bundle-common and Magepack bundle(categories / checkout / etc)... So when you're re-running Magepack (to generate new magepack.config.js) You need to prevent the existing magepack bundle js loading in the Dom.
After you make sure that the page load without the bundle, only then you can run the magepack generate and magepack bundle. Once it's finished, re-activate Magepack by running the command below
Include this deactivation -> magepack -> reactivation sequence in your deployment sequence and that should be good. |
I'm trying to generate the bundler configuration but I can't. First, it gave me timeout errors. So I increased the timeout. But now it never ends the process with no error (with --debug). The website also works perfectly with no JS error in the console. The only output is:
What can I do to debug more?
The text was updated successfully, but these errors were encountered: