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

'Reveal in sidebar` does not work #68627

Closed
pustovalov opened this issue Feb 13, 2019 · 27 comments
Closed

'Reveal in sidebar` does not work #68627

pustovalov opened this issue Feb 13, 2019 · 27 comments
Assignees
Labels
bug Issue identified by VS Code Team member as probable bug file-explorer Explorer widget issues important Issue identified as high-priority info-needed Issue requires more information from poster regression Something that used to work is now broken release-notes Release notes issues verified Verification succeeded
Milestone

Comments

@pustovalov
Copy link

pustovalov commented Feb 13, 2019

Issue Type: Bug

  ERR Data tree node not found: [object Object]: Error: Data tree node not found: [object Object]
    at i.e.getDataNode (file:///Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/workbench.main.js:1037:175)
    at i.<anonymous> (file:///Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/workbench.main.js:1034:638)
    at file:///Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/workbench.main.js:33:935
    at Object.next (file:///Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/workbench.main.js:34:33)
    at file:///Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/workbench.main.js:33:160
    at new Promise (<anonymous>)
    at i (file:///Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/workbench.main.js:32:952)
    at i.e.expand (file:///Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/workbench.main.js:1034:277)
    at Array.<anonymous> (file:///Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/workbench.main.js:5626:80)
    at t (file:///Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/workbench.main.js:105:891)
log.ts:173   ERR An unknown error occurred. Please consult the log for more details.

Actual: file could not be found in the sidebar
Expected: active file shows in the sidebar

Notes: after reboot VS code reveal in sidebar works but after some time it stops working

VS Code version: Code 1.31.0 (7c66f58, 2019-02-05T22:32:14.164Z)
OS version: Darwin x64 18.2.0

System Info
Item Value
CPUs Intel(R) Core(TM) i5-8259U CPU @ 2.30GHz (8 x 2300)
GPU Status 2d_canvas: enabled
checker_imaging: disabled_off
flash_3d: enabled
flash_stage3d: enabled
flash_stage3d_baseline: enabled
gpu_compositing: enabled
multiple_raster_threads: enabled_on
native_gpu_memory_buffers: enabled
rasterization: enabled
surface_synchronization: enabled_on
video_decode: enabled
webgl: enabled
webgl2: enabled
Load (avg) 2, 2, 2
Memory (System) 16.00GB (0.72GB free)
Process Argv
Screen Reader no
VM 0%
Extensions (47)
Extension Author (truncated) Version
mithril-emmet Fal 0.7.1
vscode-javascript-snippet-pack aka 0.1.5
project-manager ale 10.3.2
solargraph cas 0.19.3
turbo-console-log Cha 1.2.13
path-intellisense chr 1.4.2
bracket-pair-colorizer Coe 1.0.61
cjsx cri 0.0.6
vscode-svgviewer css 1.4.7
vscode-faker dee 1.3.0
githistory don 0.4.6
gitlens eam 9.5.0
remotehub eam 0.2.0
EditorConfig Edi 0.12.8
prettier-vscode esb 1.8.1
nasc-touchbar fel 1.11.0
auto-close-tag for 0.5.6
auto-rename-tag for 0.0.15
vscode-flow-ide gca 1.2.0
vscode-pull-request-github Git 0.4.0
gc-excelviewer Gra 2.1.28
haml kar 1.1.0
ruby-syntax-replacer Kos 1.0.11
restructuredtext lex 103.0.0
atom-keybindings ms- 3.0.6
debugger-for-chrome msj 4.11.1
language-liquid nei 0.1.1
vetur oct 0.15.0
vscode-docker Pet 0.5.2
material-icon-theme PKi 3.6.3
vscode-css-peek pra 2.2.0
ruby reb 0.21.0
vscode-icons rob 8.1.0
sass-indented rob 1.5.1
code-settings-sync Sha 3.2.4
autoimport ste 1.5.3
code-spell-checker str 1.6.10
lodash-snippets tom 1.0.0
gitblame wad 2.6.3
vscode-wakatime Wak 1.2.5
quokka-vscode Wal 1.0.182
vscode-import-cost wix 2.12.0
change-case wma 1.0.0
JavaScriptSnippets xab 1.7.2
ReactSnippets xab 2.3.0
html-css-class-completion Zig 1.18.0
vscode-open-in-github ziy 1.3.6

(3 theme extensions excluded)

@vscodebot
Copy link

vscodebot bot commented Feb 13, 2019

@sroucheray
Copy link

sroucheray commented Feb 14, 2019

Same erratic behavior with latest 1.31.1.

@Hainesy
Copy link

Hainesy commented Feb 14, 2019

Same behaviour on Windows.

@pjjw
Copy link

pjjw commented Feb 15, 2019

same.

@isidorn
Copy link
Contributor

isidorn commented Feb 18, 2019

Can somebody please provide exact reproducable steps?
Also can you reproduce with latest vscode insiders https://code.visualstudio.com/insiders/

@isidorn isidorn added the info-needed Issue requires more information from poster label Feb 18, 2019
@pustovalov
Copy link
Author

pustovalov commented Feb 18, 2019

Steps for reproduce:

  • Open files in main branch
  • Switch to second branch where these files do not exist
  • Switch to main branch

sidebar died

Version 1.31.1 (1.31.1)

error:

ERR Data tree node not found: [object Object]: Error: Data tree node not found: [object Object] at i.e.getDataNode (file:///Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/workbench.main.js:1037:266) at i. (file:///Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/workbench.main.js:1034:703) at file:///Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/workbench.main.js:33:935 at Object.next (file:///Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/workbench.main.js:34:33) at file:///Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/workbench.main.js:33:160 at new Promise () at i (file:///Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/workbench.main.js:32:952) at i.e.expand (file:///Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/workbench.main.js:1034:342) at Array. (file:///Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/workbench.main.js:5627:417) at t (file:///Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/workbench.main.js:105:891) at process._tickCallback (internal/process/next_tick.js:68:7)

@pustovalov
Copy link
Author

Same behavior in vscode insiders:

  ERR Data tree node not found: [object Object]: Error: Data tree node not found: [object Object]
    at j.getDataNode (file:///Applications/Visual Studio Code - Insiders.app/Contents/Resources/app/out/vs/workbench/workbench.main.js:939:824)
    at j.<anonymous> (file:///Applications/Visual Studio Code - Insiders.app/Contents/Resources/app/out/vs/workbench/workbench.main.js:938:64)
    at Generator.next (<anonymous>)
    at file:///Applications/Visual Studio Code - Insiders.app/Contents/Resources/app/out/vs/workbench/workbench.main.js:30:939
    at new Promise (<anonymous>)
    at n (file:///Applications/Visual Studio Code - Insiders.app/Contents/Resources/app/out/vs/workbench/workbench.main.js:30:716)
    at j.expand (file:///Applications/Visual Studio Code - Insiders.app/Contents/Resources/app/out/vs/workbench/workbench.main.js:937:840)
    at Array.<anonymous> (file:///Applications/Visual Studio Code - Insiders.app/Contents/Resources/app/out/vs/workbench/workbench.main.js:5109:603)
    at t (file:///Applications/Visual Studio Code - Insiders.app/Contents/Resources/app/out/vs/workbench/workbench.main.js:93:734)
console.ts:134 [Extension Host] rejected promise not handled within 1 second: Could not find a .flowconfig in /javascript/components/sites/campaigns/campaign_show or any of its parent directories.
See "flow init --help" for more info

 (at define.then.t.onMessage.process.on.t.catch.t (/Applications/Visual Studio Code - Insiders.app/Contents/Resources/app/out/vs/workbench/services/extensions/node/extensionHostProcess.js:692:683))
t.log @ console.ts:134
$logExtensionHostMessage @ mainThreadConsole.ts:39
_doInvokeHandler @ rpcProtocol.ts:390
_invokeHandler @ rpcProtocol.ts:375
_receiveRequest @ rpcProtocol.ts:295
_receiveOneMessage @ rpcProtocol.ts:225
_protocol.onMessage.e @ rpcProtocol.ts:100
fire @ event.ts:567
r @ ipc.net.ts:295
e @ ipc.net.ts:302
fire @ event.ts:567
o @ ipc.net.ts:103
_socketDataListener.e @ ipc.net.ts:132
emit @ events.js:182
addChunk @ _stream_readable.js:279
readableAddChunk @ _stream_readable.js:264
Readable.push @ _stream_readable.js:219
onread @ net.js:636
log.ts:173   ERR Could not find a .flowconfig in /javascript/components/sites/campaigns/campaign_show or any of its parent directories.
See "flow init --help" for more info


console.ts:134 [Extension Host] rejected promise not handled within 1 second: Could not find a .flowconfig in . or any of its parent directories.
See "flow init --help" for more info

 (at define.then.t.onMessage.process.on.t.catch.t (/Applications/Visual Studio Code - Insiders.app/Contents/Resources/app/out/vs/workbench/services/extensions/node/extensionHostProcess.js:692:683))
t.log @ console.ts:134
$logExtensionHostMessage @ mainThreadConsole.ts:39
_doInvokeHandler @ rpcProtocol.ts:390
_invokeHandler @ rpcProtocol.ts:375
_receiveRequest @ rpcProtocol.ts:295
_receiveOneMessage @ rpcProtocol.ts:225
_protocol.onMessage.e @ rpcProtocol.ts:100
fire @ event.ts:567
r @ ipc.net.ts:295
e @ ipc.net.ts:302
fire @ event.ts:567
o @ ipc.net.ts:103
_socketDataListener.e @ ipc.net.ts:132
emit @ events.js:182
addChunk @ _stream_readable.js:279
readableAddChunk @ _stream_readable.js:264
Readable.push @ _stream_readable.js:219
onread @ net.js:636
log.ts:173   ERR Could not find a .flowconfig in . or any of its parent directories.
See "flow init --help" for more info

VS Code version: Code - Insiders 1.32.0-insider (bbe40c8, 2019-02-18T10:48:16.325Z)
OS version: Darwin x64 18.2.0

System Info
Item Value
CPUs Intel(R) Core(TM) i5-8259U CPU @ 2.30GHz (8 x 2300)
GPU Status 2d_canvas: enabled
checker_imaging: disabled_off
flash_3d: enabled
flash_stage3d: enabled
flash_stage3d_baseline: enabled
gpu_compositing: enabled
multiple_raster_threads: enabled_on
native_gpu_memory_buffers: enabled
rasterization: enabled
surface_synchronization: enabled_on
video_decode: enabled
webgl: enabled
webgl2: enabled
Load (avg) 2, 3, 3
Memory (System) 16.00GB (1.12GB free)
Process Argv
Screen Reader no
VM 0%
Extensions (34)
Extension Author (truncated) Version
project-manager ale 10.3.2
solargraph cas 0.19.3
path-intellisense chr 1.4.2
bracket-pair-colorizer Coe 1.0.61
cjsx cri 0.0.6
vscode-eslint dba 1.8.0
vscode-faker dee 1.3.0
githistory don 0.4.6
remotehub eam 0.2.0
EditorConfig Edi 0.13.0
prettier-vscode esb 1.8.1
auto-close-tag for 0.5.6
auto-rename-tag for 0.0.15
vscode-flow-ide gca 1.2.0
vscode-pull-request-github Git 0.4.0
gc-excelviewer Gra 2.1.29
haml kar 1.1.0
ruby-syntax-replacer Kos 1.0.11
atom-keybindings ms- 3.0.6
debugger-for-chrome msj 4.11.2
vscode-docker Pet 0.5.2
material-icon-theme PKi 3.6.3
vscode-css-peek pra 2.2.0
ruby reb 0.21.1
vscode-icons rob 8.2.0
sass-indented rob 1.5.1
code-settings-sync Sha 3.2.5
code-spell-checker str 1.6.10
lodash-snippets tom 1.0.0
gitblame wad 2.6.3
change-case wma 1.0.0
JavaScriptSnippets xab 1.7.2
ReactSnippets xab 2.3.0
vscode-open-in-github ziy 1.3.6

(2 theme extensions excluded)

@isidorn
Copy link
Contributor

isidorn commented Feb 19, 2019

@pustovalov thanks for steps and for trying with insiders, however I can not reproduce on my machine. Do you have some setting like explorer.autoReveal to false or something like that?

Looking at the errors stack my assumption is that the issue happens here when I try to expand an element which is not known to the tree.
I am not really sure in what corner case can that happen.
@joaomoreno I could put a tree.hasNode check before doing the expand. What do you think

@isidorn isidorn added this to the February 2019 milestone Feb 19, 2019
@joaomoreno
Copy link
Member

@isidorn If you had a tree.hasNode and that returned false, what would you do to reveal that file?

@isidorn
Copy link
Contributor

isidorn commented Feb 19, 2019

@joaomoreno if the tree does not have a node I would refresh the node's parent.
Did you try to repro this?

@isidorn isidorn added the file-explorer Explorer widget issues label Feb 19, 2019
@joaomoreno
Copy link
Member

joaomoreno commented Feb 19, 2019

Did not try to repro. This sounds like another argument for resolveTo.

@pustovalov
Copy link
Author

I have explorer.autoReveal: true

video:
https://monosnap.com/file/fBlMNzs4NF07vQXiVDVBSgppz8G7q5

repo:
https://github.com/pustovalov/test

@pustovalov
Copy link
Author

Seems like when I switch to second branch some method remove nodes from this.nodes and when I switch back to main branch these nodes not create again

success case:

failed case:

@eddiemf
Copy link

eddiemf commented Feb 20, 2019

It happens to me every time I run a script (probably because it's altering the tree).
The problem is temporarily fixed if I simply cmd + , and close it (probably because it refreshes something), until I run any script again (like my building process, so you can imagine this happens all the time and is very annoying hehe)

@levani
Copy link

levani commented Feb 20, 2019

I have the same problem with 1.31.1

ERR Data tree node not found: [object Object]: Error: Data tree node not found: [object Object]
  at i.e.getDataNode (file:///C:/Users/lm/AppData/Local/Programs/Microsoft VS Code/resources/app/out/vs/workbench/workbench.main.js:1037:266)
  at i.<anonymous> (file:///C:/Users/lm/AppData/Local/Programs/Microsoft VS Code/resources/app/out/vs/workbench/workbench.main.js:1034:703)
  at file:///C:/Users/lm/AppData/Local/Programs/Microsoft VS Code/resources/app/out/vs/workbench/workbench.main.js:33:935
  at Object.next (file:///C:/Users/lm/AppData/Local/Programs/Microsoft VS Code/resources/app/out/vs/workbench/workbench.main.js:34:33)
  at file:///C:/Users/lm/AppData/Local/Programs/Microsoft VS Code/resources/app/out/vs/workbench/workbench.main.js:33:160
  at new Promise (<anonymous>)
  at i (file:///C:/Users/lm/AppData/Local/Programs/Microsoft VS Code/resources/app/out/vs/workbench/workbench.main.js:32:952)
  at i.e.expand (file:///C:/Users/lm/AppData/Local/Programs/Microsoft VS Code/resources/app/out/vs/workbench/workbench.main.js:1034:342)
  at Array.<anonymous> (file:///C:/Users/lm/AppData/Local/Programs/Microsoft VS Code/resources/app/out/vs/workbench/workbench.main.js:5627:417)
  at t (file:///C:/Users/lm/AppData/Local/Programs/Microsoft VS Code/resources/app/out/vs/workbench/workbench.main.js:105:891)

@emileber
Copy link

I'm experiencing this as well, with the same error message in the console and it's back working after a reload.


VS Code version: Code 1.31.1 (1b8e830, 2019-02-12T02:20:54.427Z)
OS version: Windows_NT x64 10.0.17763

System Info
Item Value
CPUs Intel(R) Xeon(R) CPU E5-1650 v4 @ 3.60GHz (12 x 3592)
GPU Status 2d_canvas: enabled
checker_imaging: disabled_off
flash_3d: enabled
flash_stage3d: enabled
flash_stage3d_baseline: enabled
gpu_compositing: enabled
multiple_raster_threads: enabled_on
native_gpu_memory_buffers: disabled_software
rasterization: enabled
surface_synchronization: enabled_on
video_decode: enabled
webgl: enabled
webgl2: enabled
Memory (System) 63.90GB (39.49GB free)
Process Argv
Screen Reader no
VM 0%
Extensions (23)
Extension Author (truncated) Version
copy-relative-path ale 0.0.2
snapshot-tools asv 0.2.2
npm-intellisense chr 1.3.0
vscode-eslint dba 1.8.0
githistory don 0.4.6
vscode-babel-coloring dza 0.0.4
gitlens eam 9.5.1
vscode-npm-script eg2 0.3.5
vsc-material-theme Equ 2.7.0
prettier-vscode esb 1.8.1
gitlab-workflow fat 2.0.0
git-project-manager fel 1.7.1
code-eol jef 0.4.3
sublime-babel-vscode jos 0.2.10
vscode-styled-components jpo 0.0.25
dotenv mik 1.0.1
vscode-scss mrm 0.6.2
material-icon-theme PKi 3.6.3
polacode pnp 0.2.2
stylelint shi 0.48.0
gitconfig sid 2.0.0
reopenclosedtab uyi 1.1.0
vscode-import-cost wix 2.12.0

(4 theme extensions excluded)

@jrieken jrieken added important Issue identified as high-priority regression Something that used to work is now broken labels Feb 25, 2019
@joaomoreno joaomoreno added the bug Issue identified by VS Code Team member as probable bug label Feb 25, 2019
@NickHeiner
Copy link

reveal in sidebar broken 2

I am also experiencing this issue. Thanks for the screencast mode for to make that gif better!

I have not noticed any particular actions that trigger this. I reloaded the window with extensions disabled, and still saw the problem.

Interesting things to note:

  1. At one point in the gif, the keyboard shortcut failed, but the context menu click worked.
  2. One failure mode is to highlight the last file that was revealed in the sidebar instead of the one you clicked on.

@isidorn
Copy link
Contributor

isidorn commented Feb 26, 2019

@joaomoreno and me are having a hard time reproducing this issue, though we acknowledge there is an issue.
@pustovalov We have followed your steps carefully and still failed. Do you have time tomorrow so we do a live debugging session? We are in Central Europe Timezone, would something like 11am CET work for you?
Any other user that can consistently repro is more than welcome.
@jrieken do you also see this all the time, do you have repro steps?

@jrieken
Copy link
Member

jrieken commented Feb 26, 2019

@jrieken do you also see this all the time, do you have repro steps?

Not always, but when that the infamous Data tree node not found: error is printed

@eddiemf
Copy link

eddiemf commented Feb 26, 2019

@isidorn have you guys tried to run some kind of building process? Something like npm start in a React project, or any webpack configuration that changes files in the files tree. I'm pretty sure the problem happens because of that since there are reports of it happening on branch change too.

For me it happens 100% of the times I run a build script, one is using a custom script to build a Roku package, and the other is when running npm start or similar in a wordpress with sage theme. Also it always resolves the problem by just opening and closing the options tab.

@emileber
Copy link

Similar for me, running npm start on a Next.js project triggers the problem (error in dev tool console as well) as it's outputting files in a .next/ directory. Though opening the settings tab doesn't solve it for me, I need a full window reload.

@NickHeiner
Copy link

I have not yet been able to determine what triggers the problem. Reloading the window does not fix it.

@alonfai
Copy link

alonfai commented Feb 26, 2019

I'm experiencing this issue also. Restarting does fix it temporarily, but reoccurring again after a short time.
Meanwhile, I downgrade my version to 1.29 until it will be resolved

@isidorn
Copy link
Contributor

isidorn commented Feb 27, 2019

Ok here are the repro steps.

  1. Open vscode repo
  2. git co release/1.20
  3. Open debugService.ts
  4. git co release/1.25
  5. F1 > Reveal active file in sidebar -> error in consle

@isidorn
Copy link
Contributor

isidorn commented Feb 27, 2019

Tomorrow's vscode insiders will contain the fix. Try it out and let us know how it behaves for you.

The issue was that the explorer was trying to be smart and figure out which exact part of the tree to refresh on raw file event. Howeever since there can be many events sometimes it is better to just refresh the whole tree (which was the previous strategy). So I decided to go back to the old approach

@NickHeiner
Copy link

Awesome! Thanks.

How will I know when "tomorrow's VSCode Insiders" version is available? I didn't see on the download page page any indication of when the published version was created.

@valyakin
Copy link

valyakin commented Feb 28, 2019

While in waiting for fixes in next version or insider
This little dude is da real MVP, fixes your tree like a pro

screenshot from 2019-02-28 16-05-25

@isidorn isidorn added the release-notes Release notes issues label Mar 4, 2019
@vscodebot vscodebot bot locked and limited conversation to collaborators Apr 13, 2019
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 file-explorer Explorer widget issues important Issue identified as high-priority info-needed Issue requires more information from poster regression Something that used to work is now broken release-notes Release notes issues verified Verification succeeded
Projects
None yet
Development

No branches or pull requests