Skip to content
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

"Markdown" editor rendering issues #45735

Closed
senpos opened this issue Mar 14, 2018 · 2 comments
Closed

"Markdown" editor rendering issues #45735

senpos opened this issue Mar 14, 2018 · 2 comments
Assignees
Labels
bug Issue identified by VS Code Team member as probable bug editor-rendering Editor rendering issues important Issue identified as high-priority verified Verification succeeded
Milestone

Comments

@senpos
Copy link

senpos commented Mar 14, 2018

Issue Type: Bug

Setting up

  • Install Hack font
  • Turn on the font in settings
    "editor.fontFamily": "Hack, Consolas, 'Courier New', monospace",
  • Set this
    "editor.renderWhitespace": "boundary",

Doing things

  1. Clone this repository
  2. Open README.md (not the English one!)
  3. Probably it will lag already, try to scroll down and up

Short video demonstration

Error 1

  ERR Cannot read property 'type' of undefined: TypeError: Cannot read property 'type' of undefined
    at file:///C:/Program Files/Microsoft VS Code Insiders/resources/app/out/vs/workbench/workbench.main.js:669:752
    at file:///C:/Program Files/Microsoft VS Code Insiders/resources/app/out/vs/workbench/workbench.main.js:669:829
    at Object.o [as renderViewLine] (file:///C:/Program Files/Microsoft VS Code Insiders/resources/app/out/vs/workbench/workbench.main.js:671:98)
    at e.renderLine (file:///C:/Program Files/Microsoft VS Code Insiders/resources/app/out/vs/workbench/workbench.main.js:1651:989)
    at e._finishRendering (file:///C:/Program Files/Microsoft VS Code Insiders/resources/app/out/vs/workbench/workbench.main.js:478:275)
    at e.render (file:///C:/Program Files/Microsoft VS Code Insiders/resources/app/out/vs/workbench/workbench.main.js:476:14)
    at e.renderLines (file:///C:/Program Files/Microsoft VS Code Insiders/resources/app/out/vs/workbench/workbench.main.js:475:426)
    at t.renderText (file:///C:/Program Files/Microsoft VS Code Insiders/resources/app/out/vs/workbench/workbench.main.js:1699:360)
    at t._actualRender (file:///C:/Program Files/Microsoft VS Code Insiders/resources/app/out/vs/workbench/workbench.main.js:1770:123)
    at file:///C:/Program Files/Microsoft VS Code Insiders/resources/app/out/vs/workbench/workbench.main.js:1769:366
    at z (file:///C:/Program Files/Microsoft VS Code Insiders/resources/app/out/vs/workbench/workbench.main.js:1761:1015)
    at t._renderNow (file:///C:/Program Files/Microsoft VS Code Insiders/resources/app/out/vs/workbench/workbench.main.js:1769:344)
    at t._flushAccumulatedAndRenderNow (file:///C:/Program Files/Microsoft VS Code Insiders/resources/app/out/vs/workbench/workbench.main.js:1766:400)
    at t._onRenderScheduled (file:///C:/Program Files/Microsoft VS Code Insiders/resources/app/out/vs/workbench/workbench.main.js:1769:266)
    at e.execute (file:///C:/Program Files/Microsoft VS Code Insiders/resources/app/out/vs/workbench/workbench.main.js:195:972)
    at o (file:///C:/Program Files/Microsoft VS Code Insiders/resources/app/out/vs/workbench/workbench.main.js:196:169)

Error 2

ERR Failed to execute 'removeChild' on 'Node': The node to be removed is not a child of this node.: Error: Failed to execute 'removeChild' on 'Node': The node to be removed is not a child of this node.
    at e._removeLinesBefore (file:///C:/Program Files/Microsoft VS Code Insiders/resources/app/out/vs/workbench/workbench.main.js:477:207)
    at e.render (file:///C:/Program Files/Microsoft VS Code Insiders/resources/app/out/vs/workbench/workbench.main.js:476:389)
    at e.renderLines (file:///C:/Program Files/Microsoft VS Code Insiders/resources/app/out/vs/workbench/workbench.main.js:475:426)
    at t.renderText (file:///C:/Program Files/Microsoft VS Code Insiders/resources/app/out/vs/workbench/workbench.main.js:1699:360)
    at t._actualRender (file:///C:/Program Files/Microsoft VS Code Insiders/resources/app/out/vs/workbench/workbench.main.js:1770:123)
    at file:///C:/Program Files/Microsoft VS Code Insiders/resources/app/out/vs/workbench/workbench.main.js:1769:366
    at z (file:///C:/Program Files/Microsoft VS Code Insiders/resources/app/out/vs/workbench/workbench.main.js:1761:1015)
    at t._renderNow (file:///C:/Program Files/Microsoft VS Code Insiders/resources/app/out/vs/workbench/workbench.main.js:1769:344)
    at t._flushAccumulatedAndRenderNow (file:///C:/Program Files/Microsoft VS Code Insiders/resources/app/out/vs/workbench/workbench.main.js:1766:400)
    at t._onRenderScheduled (file:///C:/Program Files/Microsoft VS Code Insiders/resources/app/out/vs/workbench/workbench.main.js:1769:266)
    at e.execute (file:///C:/Program Files/Microsoft VS Code Insiders/resources/app/out/vs/workbench/workbench.main.js:195:972)
    at o (file:///C:/Program Files/Microsoft VS Code Insiders/resources/app/out/vs/workbench/workbench.main.js:196:169)

A lot of these errors in Developer Tools, while i'm on the problematic area of file.

Tried both in VS Code stable and Insiders.

Will try to reproduce this issue with other fonts.
Couldn't reproduce with Iosevka and Consolas.
Well, it is not clear for me when it fails. Sometimes it works with other fonts, sometimes not. Yikes.

VS Code version: Code - Insiders 1.22.0-insider (a716373, 2018-03-14T05:15:41.910Z)
OS version: Windows_NT x64 10.0.14393

System Info
Item Value
CPUs Intel(R) Core(TM) i5-4460 CPU @ 3.20GHz (4 x 3193)
Memory (System) 7.94GB (3.76GB free)
Process Argv C:\Program Files\Microsoft VS Code Insiders\Code - Insiders.exe
Screen Reader no
VM 0%
Extensions: none Reproduces without extensions
@vscodebot vscodebot bot added editor editor-core Editor basic functionality labels Mar 14, 2018
@mjbvz mjbvz assigned rebornix and alexdima and unassigned mjbvz Mar 14, 2018
@senpos
Copy link
Author

senpos commented Mar 16, 2018

Important update

After some time playing around with this issue, I've found that this bug can be easily reproduced with next steps:

  • put this into your settings "editor.renderWhitespace": "boundary",
  • resize VS Code window

Here is another video example (5MB video file is here, be careful)

  • 00:00 - 00:11 - without "editor.renderWhitespace": "boundary",, VS Code full screen
  • 00:11 - 00:18 - with "editor.renderWhitespace": "boundary",, VS Code full screen
  • 00:18 - 00:28 - with "editor.renderWhitespace": "boundary",, VS Code windowed, bug appeared (!)

@alexdima alexdima added editor-rendering Editor rendering issues bug Issue identified by VS Code Team member as probable bug important Issue identified as high-priority and removed editor editor-core Editor basic functionality labels Mar 28, 2018
@alexdima alexdima added this to the March 2018 milestone Mar 28, 2018
@alexdima
Copy link
Member

The root cause is 020afb7 , combined with a bug in the implementation for getLineCharCode, which would lead to the range being validated incorrectly.

@rebornix rebornix added the verified Verification succeeded label Mar 29, 2018
@vscodebot vscodebot bot locked and limited conversation to collaborators May 12, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Issue identified by VS Code Team member as probable bug editor-rendering Editor rendering issues important Issue identified as high-priority verified Verification succeeded
Projects
None yet
Development

No branches or pull requests

4 participants