Chrome extension hint.js & ngHintModules

Our angular app sometimes fails to load on chrome canary (version 41.0.2237.0 canary (64-bit)), saying

Failed to create ngHintModules module due to: RangeError: Maximum call stack size exceeded

But it loads fine in firefox, chrome (version 39.0.2171.71 (64-bit)), safari.

Probably not sure if there is anything to do with angular or not.

Complete mistake

Uncaught Error: [$injector:modulerr] Failed to instantiate module ngHintModules due to: RangeError: Maximum call stack size exceeded at Array.forEach (native) at module.exports (chrome-extension://ighdmehidhipcmcojjgiloacoafjmpfk/dist/hint.js:2333:21) at module.exports (chrome-extension://ighdmehidhipcmcojjgiloacoafjmpfk/dist/hint.js:2384:5) at chrome-extension://ighdmehidhipcmcojjgiloacoafjmpfk/dist/hint.js:2387:7 at Array.forEach (native) at module.exports (chrome-extension://ighdmehidhipcmcojjgiloacoafjmpfk/dist/hint.js:2385:21) at chrome-extension://ighdmehidhipcmcojjgiloacoafjmpfk/dist/hint.js:2387:7 at Array.forEach (native) at module.exports (chrome-extension://ighdmehidhipcmcojjgiloacoafjmpfk/dist/hint.js:2385:21) at chrome-extension://ighdmehidhipcmcojjgiloacoafjmpfk/dist/hint.js:2387:7 

NB: The error I am showing here is from

Version 41.0.2237.0 canary (64-bit)

+58
angularjs google-chrome google-chrome-extension
Dec 10 '14 at 4:28
source share
5 answers

I also had this problem that was resolved by disabling Batarang.

+46
Dec 10 '14 at 6:33
source share

This issue is open on Batarang Github here: https://github.com/angular/angularjs-batarang/issues/156

You can download the previous version of Batarang from this zip file: https://github.com/angular/angularjs-batarang/archive/v0.4.3.zip

  • Open Advanced Tools-> Extensions in Chrome
  • Find AngularJS Batarang and click on the trash can to remove the extension.
  • Download .zip
  • Extract the file
  • Open Advanced Tools-> Extensions in Chrome
  • Check developer mode at the top
  • Click Download Unpacked Extension
  • Select the directory where you extracted the zip
  • If you received an error message in the manifest file, then you probably selected the directory level too high. Make sure you select the lower level directory angularjs-batarang-0.4.3.
  • Download the AngularJS page and use Batarang with the inspector again, as before.

This will lead to the restoration of the previous version, which, if there are problems, has some mostly working functions, such as performance profiling, area inspector, options and the help tab, which have left the latest version. Version 0.7.1 fixes the main breakdown of applications, but it provides only a tree of areas (without inspectors) and new angular functionality.

+28
Dec 10 '14 at 15:15
source share

You do not need to disable Angular batarang; just follow these steps:

  • Open the developer tools and go to the hint.js file (the one that causes the stack to overflow)
  • Go to line 453 add add breakpoint
  • reload the application and when it hits the breakpoint, just comment it (setupModuleLoader (window)) and click continue
  • It throws an exception anyway, (Uncaught ReferenceError: Angular not defined), but you can run batarang

I know this is not the best solution, but this is the fastest thing I could find without delving too deep into the problem.

Update

Checking what happens, I noticed that the problem occurs when we define several modules, and we add the same dependencies for all of them.

eg:

 angular.module("app", ["moduleB", "moduleC"]); angular.module("moduleB", ["moduleC"]); 

When I define module B without passing the same fingerprints to its parent module, then the stack does not overflow.

 angular.module("moduleB", []); 
+13
Dec 10 '14 at 10:54
source share

Our team just experienced this error and it was fixed by updating the Batarang extension in Chrome to the latest version.

+8
Dec 10 '14 at 19:21
source share

Update ... With the new Chrome update, the problem returned, so if someone experienced this error, go back to the previous version of Chrome. All assemblies are available here, do not select the first. http://www.slimjet.com/chrome/google-chrome-old-version.php Then it should work fine!

0
Sep 19 '16 at 15:34
source share



All Articles