-
Notifications
You must be signed in to change notification settings - Fork 93
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
ng-inspector for AngularJS makes my angular app crashes on latest Chrome version #95
Comments
Hey @davidpelayo, apologies for the troubles. Do you have a link to a publicly accessible version of your app for us to attempt to replicate with? If not, would it be possible for you to attempt to build a plnkr that we can use to replicate? |
Additionally, what version of ng-inspector are you running? |
Hey, just wanted to report I encountered the same issue straight away this morning. Looks like this extension was updated yesterday, 0.5.9. Deactivating the plugin fixes the issue. My app isn't public. For what it's worth, it's using Angular 1.3.8 with RequireJS. Chrome version Version 42.0.2311.90 m |
@pherrmann could you please paste the error message you got in the console? |
For reference: https://docs.angularjs.org/error/$injector/itkn |
Sure, there's many instances of the following error for different directives on a particular screen. Here's a couple... Error: [$injector:itkn] Incorrect injection token! Expected service name as string, got function () Error: [$injector:itkn] Incorrect injection token! Expected service name as string, got function globalToolbar($window){ |
@pherrmann thanks a lot! Would it be possible for you to paste the code for one of the directives? You can remove all the controller code if it's sensitive to your client/company, and would be a great help for us to solve this bug and write a test to avoid regressions in the future. |
A stackoverflow user had the same problem, and tracked down the issue: http://stackoverflow.com/questions/29653779/angular-itkn-error-caused-by-directives-defined-with-function-outside-array/29666410#29666410 Working on this now. |
I rolled back on the directive factory annotation bit from With this rollback, this issue should be fixed in v0.5.10, which I just published to the Chrome store. Edit: Actually, it won't break the extension, see this comment. |
Using Chrome 45.0.2454.101 and the latest ng-inspector. My app simply stops, no errors. Memory usage crepps up to the point where the Chrome error message puts and simply says "Something went wrong with displaying this webpage." Similar error on Firefox 41.0.1. |
I have the same issue as tedohio. No errors but if I open ng-inspector, my app crashes. |
I can confirm this issue as well. I can replicate it by opening ng-inspector when I have a directive on the page - see angular-ui/angular-google-maps. As soon as I comment out the gmap, the issue resolves itself. Feels like it might be an infinite recursion happening when its loading the model context. Hope this helps |
After upgrading my Google Chrome stable channel today, my AngularJS application (1.4.x) crashed due to have this plugin activated.
Directives weren't wrongly evaluated when injected to the module core of Angular, throwing the following error:
Error: [$injector:itkn] Incorrect injection token! Expected service name as string, got function () http://errors.angularjs.org/1.4.0-beta.5/$injector/itkn?p0=function%20() at REGEX_STRING_REGEXP (angular.js:68) at Object.invoke (angular.js:4245) at angular.js:6600 at forEach (angular.js:328) at Object.<anonymous> (angular.js:6598) at Object.invoke (angular.js:4260) at Object.enforcedReturnValue [as $get] (angular.js:4113) at Object.invoke (angular.js:4260) at angular.js:4078 at Object.getService [as get] (angular.js:4219)
Confirmed after deactivating the plugin my app bootstrapped again without any other issues.
The text was updated successfully, but these errors were encountered: