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

Extension fails to activate if there are permissions errors reading folders in the open workspace #2917

Closed
UditSharma9999 opened this issue Oct 30, 2020 · 13 comments
Labels
Milestone

Comments

@UditSharma9999
Copy link

UditSharma9999 commented Oct 30, 2020

My flutter extension is not working...
All the features of flutter extension is not working in vscode

@DanTup
Copy link
Member

DanTup commented Oct 30, 2020

Do you see syntax highlighting/coloring when you open .dart file, or is that missing too?

Can you try clicking Help -> Toggle Developer Tools in VS Code, then clicking Console and see if there are any errors reported there? Thanks!

@DanTup DanTup added the awaiting info Requires more information from the customer to progress label Oct 30, 2020
@UditSharma9999
Copy link
Author

UditSharma9999 commented Oct 31, 2020

No, syntax highlighting/coloring of .dart file is working fine..

I got this on Toggle Developer Tools ( console ) in VS Code

Screenshot (110)

@DanTup
Copy link
Member

DanTup commented Oct 31, 2020

Could you try expanding the error that says Dart-Code failed to activate, to see if it has useful stack trace?

Thanks!

@DanTup DanTup added this to the v3.17.0 milestone Oct 31, 2020
@UditSharma9999
Copy link
Author

UditSharma9999 commented Nov 2, 2020

it still showing that error ..

@DanTup
Copy link
Member

DanTup commented Nov 2, 2020

@UditSharma123 can you click the small arrow to the left of "Activating extension Dart-Code.dart-code failed"? It should expand and show a little more detail.

Could you also try enabling the general extension log and reproducing the issue, to see whether that includes anything useful? Thanks!

@UditSharma9999
Copy link
Author

UditSharma9999 commented Nov 3, 2020

I got these error:

[object Object]]Cannot read property 'getRuleStack' of undefined
$onExtensionRuntimeError @ terminalInstanceService.ts:31
mainThreadExtensionService.ts:66 TypeError: Cannot read property 'getRuleStack' of undefined
	at DocumentDecoration.tokenizeLine (c:\Users\udits\.vscode\extensions\coenraads.bracket-pair-colorizer-2-0.2.0\out\src\documentDecoration.js:227:35)
	at DocumentDecoration.onDidChangeTextDocument (c:\Users\udits\.vscode\extensions\coenraads.bracket-pair-colorizer-2-0.2.0\out\src\documentDecoration.js:39:30)
	at DocumentDecorationManager.onDidChangeTextDocument (c:\Users\udits\.vscode\extensions\coenraads.bracket-pair-colorizer-2-0.2.0\out\src\documentDecorationManager.js:47:32)
	at c:\Users\udits\.vscode\extensions\coenraads.bracket-pair-colorizer-2-0.2.0\out\src\extension.js:30:39
	at l.fire (c:\Program Files\Microsoft VS Code\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:45:801)
	at t.ExtHostDocuments.$acceptModelChanged (c:\Program Files\Microsoft VS Code\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:715:675)
	at m._doInvokeHandler (c:\Program Files\Microsoft VS Code\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:870:464)
	at m._invokeHandler (c:\Program Files\Microsoft VS Code\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:870:156)
	at m._receiveRequest (c:\Program Files\Microsoft VS Code\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:868:817)
	at m._receiveOneMessage (c:\Program Files\Microsoft VS Code\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:867:623)
	at c:\Program Files\Microsoft VS Code\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:865:691
	at l.fire (c:\Program Files\Microsoft VS Code\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:45:801)
	at v.fire (c:\Program Files\Microsoft VS Code\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:256:381)
	at c:\Program Files\Microsoft VS Code\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:1059:179
	at l.fire (c:\Program Files\Microsoft VS Code\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:45:801)
	at v.fire (c:\Program Files\Microsoft VS Code\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:256:381)
	at t.PersistentProtocol._receiveMessage (c:\Program Files\Microsoft VS Code\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:261:451)
	at c:\Program Files\Microsoft VS Code\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:258:489
	at l.fire (c:\Program Files\Microsoft VS Code\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:45:801)
	at p.acceptChunk (c:\Program Files\Microsoft VS Code\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:253:851)
	at c:\Program Files\Microsoft VS Code\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:253:203
	at Socket.t (c:\Program Files\Microsoft VS Code\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:263:54)
	at Socket.emit (events.js:223:5)
	at addChunk (_stream_readable.js:309:12)
	at readableAddChunk (_stream_readable.js:290:11)
	at Socket.Readable.push (_stream_readable.js:224:10)
	at Pipe.onStreamRead (internal/stream_base_commons.js:181:23)
$onExtensionRuntimeError @ mainThreadExtensionService.ts:66

@DanTup
Copy link
Member

DanTup commented Nov 3, 2020

That appears to be a different error (that's an error in the coenraads.bracket-pair-colorizer-2-0 extension).

Could you try enabling the log file linked above to see if that captures the issue? Thanks!

@UditSharma9999
Copy link
Author

could you please tell me how to "enable the log file" . Thanks!

@DanTup
Copy link
Member

DanTup commented Nov 3, 2020

@UditSharma123 there are some instructions at the link above. You'll need to add it to your VS Code User Settings which you can access by running the Preferences: Open User Settings command in VS Code.

You should add something like this:

"dart.extensionLogFile": "C:\\Users\\Danny\\Desktop\\Logs\\dart-code-extension.txt",

Replacing the path with one to a valid folder on your machine (be sure to escape the backslashes so they're in pairs).

Then restart VS Code and reproduce the error, and take a copy of that log file.

Thanks!

@UditSharma9999
Copy link
Author

I did that and I got this in log file

!! PLEASE REVIEW THIS LOG FOR SENSITIVE INFORMATION BEFORE SHARING !!

Dart Code extension: 3.16.0
Flutter extension: 3.16.0 (not activated)

App: Visual Studio Code
Version: 1.50.1
Platform: win

HTTP_PROXY: undefined
NO_PROXY: undefined

Logging Categories:
General

Tue Nov 03 2020 [23:15:56 GMT+0530 (India Standard Time)] Log file started
[11:15:56 PM] [General] [Info] Searching for SDKs...
[11:15:56 PM] [General] [Info] Environment PATH:
[11:15:56 PM] [General] [Info] C:\Program Files (x86)\VMware\VMware Player\bin
[11:15:56 PM] [General] [Info] C:\Program Files (x86)\Common Files\Oracle\Java\javapath
[11:15:56 PM] [General] [Info] C:\Windows\system32
[11:15:56 PM] [General] [Info] C:\Windows
[11:15:56 PM] [General] [Info] C:\Windows\System32\Wbem
[11:15:56 PM] [General] [Info] C:\Windows\System32\WindowsPowerShell\v1.0
[11:15:56 PM] [General] [Info] C:\Windows\System32\OpenSSH
[11:15:56 PM] [General] [Info] C:\Program Files\nodejs
[11:15:56 PM] [General] [Info] C:\ProgramData\chocolatey\bin
[11:15:56 PM] [General] [Info] C:\Program Files\Microsoft SQL Server\Client SDK\ODBC\170\Tools\Binn
[11:15:56 PM] [General] [Info] C:\Program Files (x86)\Microsoft SQL Server\150\Tools\Binn
[11:15:56 PM] [General] [Info] C:\Program Files\Microsoft SQL Server\150\Tools\Binn
[11:15:56 PM] [General] [Info] C:\Program Files\Microsoft SQL Server\150\DTS\Binn
[11:15:56 PM] [General] [Info] C:\Program Files\Git\cmd
[11:15:56 PM] [General] [Info] C:\Program Files\dotnet
[11:15:56 PM] [General] [Info] C:\Windows\Microsoft.NET\Framework64\v4.0.30319
[11:15:56 PM] [General] [Info] C:\Program Files\Microsoft VS Code\bin
[11:15:56 PM] [General] [Info] C:\Program Files\VSCodium\bin
[11:15:56 PM] [General] [Info] C:\Users\udits\AppData\Local\Programs\Python\Python36\Scripts
[11:15:56 PM] [General] [Info] C:\Users\udits\AppData\Local\Programs\Python\Python36
[11:15:56 PM] [General] [Info] C:\Users\udits\AppData\Local\Microsoft\WindowsApps
[11:15:56 PM] [General] [Info] C:\Users\udits\AppData\Roaming\npm
[11:15:56 PM] [General] [Info] C:\Users\udits\AppData\Roaming\Pub\Cache\bin
[11:15:56 PM] [General] [Info] C:\Users\udits\AppData\Local\Android\Sdk
[11:15:56 PM] [General] [Info] C:\Users\udits\AppData\Local\Android\Sdk\platform-tools
[11:15:56 PM] [General] [Info] C:\MinGW\bin
[11:15:56 PM] [General] [Info] C:\tools\dart-sdk\bin
[11:15:56 PM] [General] [Info] C:\Users\udits.dotnet\tools
[11:15:56 PM] [General] [Info] C:\tools\flutter\bin
[11:15:56 PM] [General] [Info] C:\Program Files\JetBrains\IntelliJ IDEA Community Edition 2020.2.3\bin

Screenshot (113)

Thanks!

@DanTup
Copy link
Member

DanTup commented Nov 4, 2020

@UditSharma123 do you happen to have the root of the drive (E:\) open in VS Code? I think that might explain this - we're assuming there are no folder permission issues scanning all of the folders in the open workspace.

As a workaround you could just open a subfolder (E:\Apps) or similar, and I'll handle this for the next release. Thanks!

@DanTup DanTup changed the title flutter extension is not working on vscode Extension fails to activate if there are permissions errors reading folders in the open workspace Nov 4, 2020
@DanTup DanTup removed the awaiting info Requires more information from the customer to progress label Nov 4, 2020
@UditSharma9999 UditSharma9999 changed the title Extension fails to activate if there are permissions errors reading folders in the open workspace Extension fails to activate if there are permissions errors reading folders in the open workspace Nov 4, 2020
@UditSharma9999
Copy link
Author

Now it's working
Thanks!!

@DanTup
Copy link
Member

DanTup commented Nov 4, 2020

I'll keep this open as we should handle this better.

@DanTup DanTup reopened this Nov 4, 2020
@DanTup DanTup closed this as completed in 00f3c01 Nov 5, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants