100% CPU usage when viewing Glitch source code

I have just visited Glitch for the first time. When I viewed the source code of a Glitch (https://glitch.com/edit/#!/rollup-built-in-modules?path=views/index.njk.html:20:70) my browser’s CPU usage immediately jumped to 100% and stayed there.

From what I can see in the devtools, the problem is an infinite post-message loop between ng-validate.js and codemirror.js:

e.messageJumpContext (ng-validate.js:formatted:1404)
(anonymous) (ng-validate.js:formatted:249)
e.send (ng-validate.js:formatted:245)
h (ng-validate.js:formatted:1297)
l (ng-validate.js:formatted:1312)
(anonymous) (ng-validate.js:formatted:1321)
childList (async)
I (codemirror.js:63)
si (codemirror.js:4256)
(anonymous) (codemirror.js:3807)
(anonymous) (codemirror.js:3773)
(anonymous) (codemirror.js:2138)
zr (codemirror.js:3770)
(anonymous) (codemirror.js:3917)
refreshEditor (codemirror-shim.ts:308)
receivePostMessage (page-events.ts:129)
postMessage (async)
e.messageJumpContext (ng-validate.js:formatted:1404)
(anonymous) (ng-validate.js:formatted:249)
e.send (ng-validate.js:formatted:245)
h (ng-validate.js:formatted:1297)
l (ng-validate.js:formatted:1312)
(anonymous) (ng-validate.js:formatted:1321)
childList (async)
I (codemirror.js:63)
si (codemirror.js:4256)
(anonymous) (codemirror.js:3807)
(anonymous) (codemirror.js:3773)
(anonymous) (codemirror.js:2138)
zr (codemirror.js:3770)
(anonymous) (codemirror.js:3917)
refreshEditor (codemirror-shim.ts:308)
receivePostMessage (page-events.ts:129)
postMessage (async)
e.messageJumpContext (ng-validate.js:formatted:1404)
(anonymous) (ng-validate.js:formatted:249)
e.send (ng-validate.js:formatted:245)
h (ng-validate.js:formatted:1297)
l (ng-validate.js:formatted:1312)
(anonymous) (ng-validate.js:formatted:1321)
childList (async)
I (codemirror.js:63)
si (codemirror.js:4256)
(anonymous) (codemirror.js:3807)
(anonymous) (codemirror.js:3773)
(anonymous) (codemirror.js:2138)
zr (codemirror.js:3770)
(anonymous) (codemirror.js:3917)
refreshEditor (codemirror-shim.ts:308)
receivePostMessage (page-events.ts:129)

Hi @jonrimmer, welcome to the Glitch forum!

Thanks or the report. I’m not able to reproduce this; can you tell me what browser and os you’re using? Also, when you load the editor are you a project member, or a guest (can you edit the file, for instance, or view the Logs in the Tools pane in the lower left?

Hi Cori,

I’m using Chrome on macOS. I was browsing as a guest.

I think the problem may have been because I was using the Angular Augury development extension: https://chrome.google.com/webstore/detail/augury/elgalmkoelokbchhkhacckoklkejnhcd?utm_source=chrome-ntp-icon

When I unloaded the extension the problem went away.

2 Likes

Thanks for the info @jonrimmer; I’ll make a note of it. It seems pretty strongly correlated in my brief experimentation.