You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Horizontal lines of removed chunks never go away #1715
Once you remove a code chunk the horizontal lines delimiting it stay.
Then I remove the # %% line:
Then I remove everything:
Also, can you add an option to completely remove those lines? They are quite invasive, specially the thick one above. Moreover, even when the cursor is not inside a chunk, the last selected one keeps being surrounded by those lines, which is very misleading.
To Reproduce
I think it's clear from the description above.
Can you fix this issue by yourself? (We appreciate the help)
For code cells in .R files, the current highlightCurrentChunk() sets the top/bottom border decorations when a current chunk exists, but does not clear those decorations when no current chunk is found. Removing a chunk marker or moving outside a chunk can therefore leave the previous borders visible.
That mechanism remains in main. Keeping this open for clearing stale decorations and the requested option to disable the borders.
Activity
ThomasSoeiro commentedon Sep 22, 2026
Edit: I can reproduce with
vscode-r 3.0.0-rc.0.The issue is about code cells in .R files (specifics in #662 and #1455). See also e.g. https://code.visualstudio.com/docs/python/jupyter-support-py#_jupyter-code-cells, https://docs.spyder-ide.org/current/panes/editor.html?highlight=code+cells, or https://positron.posit.co/code-cells.html for documentation in other IDEs. This is different from code chunk in .Rmd files.
I can't reproduce withvscode-r 3.0.0-rc.0.1. open a new file (CTRL+N)2. choose rmd (CTRL+K M and choose Rmd)3. add a code chunk, e.g.:4. no borders are added and the chunk collapse when its content is removed@memeplex Please provide the exact steps, code (not screenshot only), and list of extension.@eitsupi Can you please add the "need info" tag?renkun-ken commentedon Oct 6, 2026
For code cells in
.Rfiles, the current highlightCurrentChunk() sets the top/bottom border decorations when a current chunk exists, but does not clear those decorations when no current chunk is found. Removing a chunk marker or moving outside a chunk can therefore leave the previous borders visible.That mechanism remains in
main. Keeping this open for clearing stale decorations and the requested option to disable the borders.fix: clear stale R code-cell borders and allow disabling them (REdito…