Maximum call stack size exceeded when opening PR diff
This is a bug that I never had before, and until now I have it only with this particular file, on this PR. The bug can be reproduced consistently, but only with this file.
What happens
For this particular file, and this particular diff, when I try to open it from the PR Details view of atlascode or from the PR sidebar, I get a “Maximum call stack size exceeded” from VSCode. When this happens, any opened editor disappears and trying to open any other file or “editor view” (extension page, settings page, diff view, …) will result in the same “Maximum call stack size exceeded” error. The only solution is to close the IDE and open it again. From there, the bug can be repeated.
The linked video shows the bug, together with the “Log (Window)” view.
Opening other files or diffs, even through atlascode, works fine.
Opening the problematic diff view from another mean (e.g. Git Graph) works flawlessly.
Content of the log window
[2020-12-09 07:55:18.614] [renderer1] [error] RST extension got invalid file name: /file.rst
[2020-12-09 07:55:27.672] [renderer1] [error] RST extension got invalid file name: /TST/index.rst
[2020-12-09 07:55:31.432] [renderer1] [error] Maximum call stack size exceeded: RangeError: Maximum call stack size exceeded
at file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:325:279
at Object.t.multibyteAwareBtoa (file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:325:321)
at e.toDiffEditorViewStateResource (file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:3882:828)
at e.doSaveOrClearTextDiffEditorViewState (file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:3881:989)
at e.onWillCloseEditorInGroup (file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:3878:865)
at e.onWillCloseEditor (file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:3876:60)
at file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:3875:968
at c.fire (file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:99:67)
at e.handleOnDidCloseEditor (file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:6880:888)
at file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:6880:53
at c.fire (file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:99:67)
at e.closeEditor (file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:3165:920)
at e.doCloseActiveEditor (file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:6889:733)
at e.doCloseEditor (file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:6889:329)
at e.doHandleOpenEditorError (file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:6887:837)
at file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:6886:789
at async e.openEditor (file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:6885:66)
at async B.openEditor (file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:6656:391)
at async file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:6486:572
[2020-12-09 07:55:31.548] [renderer1] [error] Cannot read property 'uri' of null: TypeError: Cannot read property 'uri' of null
at e.createNewCommentNode (file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:4909:818)
at e.display (file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:4904:14)
at O.displayCommentThread (file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:4924:380)
at file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:4927:839
at Array.forEach (<anonymous>)
at file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:4927:725
at Array.forEach (<anonymous>)
at O.setComments (file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:4927:617)
at file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:4920:349
[2020-12-09 07:55:32.546] [renderer1] [error] RST extension got invalid file name: /TST/SMALL_NEED.rst
[2020-12-09 07:55:49.767] [renderer1] [error] Maximum call stack size exceeded: RangeError: Maximum call stack size exceeded
at file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:325:279
at Object.t.multibyteAwareBtoa (file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:325:321)
at e.toDiffEditorViewStateResource (file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:3882:828)
at e.doSaveOrClearTextDiffEditorViewState (file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:3881:989)
at e.saveState (file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:3881:825)
at file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:3177:291
at c.fire (file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:99:67)
at e.flush (file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:3057:356)
at file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:7036:185
at c.fire (file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:99:67)
at file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:94:782
at file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:95:542
at c.fire (file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:99:67)
at file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:94:636
at c.fire (file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:99:67)
at file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:94:782
at c.fire (file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:99:67)
at file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:464:634
at x.onResponse (file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:465:570)
at x.onBuffer (file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:465:406)
at file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:463:161
at c.fire (file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:99:67)
at EventEmitter.n (file:///usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:96:450)
at EventEmitter.emit (events.js:223:5)
at Object.onMessage (electron/js2c/renderer_init.js:139:873)
Versions
OS: Fedora 33
VSCode:
Version: 1.51.1
Commit: e5a624b788d92b8d34d1392e4c4d9789406efe8f
Date: 2020-11-10T23:31:29.624Z
Electron: 9.3.3
Chrome: 83.0.4103.122
Node.js: 12.14.1
V8: 8.3.110.13-electron.0
OS: Linux x64 5.9.11-200.fc33.x86_64
Atlascode: v2.8.5
Comments (5)
-
Account Deactivated reporter -
Account Deactivated reporter It seems that the only difference is that I switched to Fedora 33. Did they reduce the call stack size of JS? I could not find such a thing yet.
-
Account Deactivated I’m having the same issue with one file in one PR, so far anyway. I’m using extension v2.8.5 in VS code 1.52.1. A colleague tried the same PR & file on the same extension version but in VS code 1.48.2 and it worked fine. So this could be more of an issue with VS Code itself than the extension.
[2021-01-15 08:46:04.653] [renderer1] [error] Maximum call stack size exceeded: RangeError: Maximum call stack size exceeded at file:///Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:363:477 at Object.t.multibyteAwareBtoa (file:///Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:363:519) at e.toDiffEditorViewStateResource (file:///Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:5596:748) at e.doSaveOrClearTextDiffEditorViewState (file:///Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:5595:850) at e.onWillCloseEditorInGroup (file:///Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:5592:571) at e.onWillCloseEditor (file:///Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:3826:433) at file:///Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:3826:324 at c.fire (file:///Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:99:696) at e.handleOnDidCloseEditor (file:///Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:6996:888) at file:///Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:6996:53 at c.fire (file:///Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:99:696) at e.closeEditor (file:///Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:3834:180) at e.doCloseActiveEditor (file:///Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:7005:733) at e.doCloseEditor (file:///Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:7005:329) at e.doHandleOpenEditorError (file:///Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:7003:837) at file:///Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:7002:789 at async e.openEditor (file:///Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:7001:66) at async F.openEditor (file:///Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:6769:31) at async file:///Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:5608:939
Versions
Version: 1.52.1 Commit: ea3859d4ba2f3e577a159bc91e3074c5d85c0523 Date: 2020-12-16T16:30:02.420Z Electron: 9.3.5 Chrome: 83.0.4103.122 Node.js: 12.14.1 V8: 8.3.110.13-electron.0 OS: Darwin x64 19.6.0 Jira and Bitbucket extension 2.8.5
-
Account Deactivated reporter It happens also with files that I was able to open before. Maybe this is related to the number of comments on a diff? Also, I changed the distribution and the issue is still here. So this is not related to Fedora 33 but rather the version of VSCode it run on.
I also tried to completely wipe the VSCode installation, but the same files produce the same issue.
Version: 1.52.1 Commit: ea3859d4ba2f3e577a159bc91e3074c5d85c0523 Date: 2020-12-16T16:32:10.090Z Electron: 9.3.5 Chrome: 83.0.4103.122 Node.js: 12.14.1 V8: 8.3.110.13-electron.0 OS: Linux x64 5.10.6-arch1-1 Atlascode: v2.8.5
-
@{5f290fc22aa2500028b98384} I back your suggestion that it’s related to the number of comments. I was able to view a certain file in a PR diff, then I ran into this same issue after adding more comments to the same file. No other changes were made to the PR or the file in between when it worked and now when it fails to open.
- Log in to comment
Okay, now there are other files that have this issue too. And specifically files that could be opened not so long ago. I’ll check what could have changed in my setup between then and now.
(New file found is a Lua file, so it doesn’t seem related to the file type.)