Xrumet

Results 15 comments of Xrumet

Thanks for so quick response, Here is solution file - https://github.com/Xrumet/PowerShellTools/tree/main/Draft Startup.ps1 - https://github.com/Xrumet/PowerShellTools/blob/main/Draft/ConsoleApp2/startup.ps1 Program.cs ->Main - https://github.com/Xrumet/PowerShellTools/blob/main/Draft/ConsoleApp2/Program.cs It is dirty a bit, but still the issue is on line...

> Hmm could you elaborate on this? That's what I see if pause application: ![image](https://user-images.githubusercontent.com/72695570/145230323-f53a841a-a927-4190-aa3e-139d0c594972.png) And also when I switched pipe from duplex mode to separate in and out pipes,...

I only guessing, maybe I do something wrong there by passing -HostProfileId 'myclient' ?...

So, should I try to run Start-EditorServices.ps1 directly? And I guess still with "startInfo.Verb = "runAs";" ?

Noup, didn't help, Will try to switch back to separate in\out pipes to see exact error and share it.

Yeap, that's it: ![image](https://user-images.githubusercontent.com/72695570/145234143-0512e497-1eb2-44e9-a295-518b5eabd14f.png) May it be because of: ``` - Profile paths: + AllUsersAllHosts: C:\Windows\System32\WindowsPowerShell\v1.0\profile.ps1 + AllUsersCurrentHost: C:\Windows\System32\WindowsPowerShell\v1.0\myclient_profile.ps1 + CurrentUserAllHosts: C:\Users\xrumet\Documents\WindowsPowerShell\profile.ps1 + CurrentUserCurrentHost: C:\Users\xrumet\Documents\WindowsPowerShell\myclient_profile.ps1 ``` I guess System32 folder...

From other hand input pipe connected successfully... CanRead and CanWrite properties have correct values, Maybe the issue that "ConnectAsync" is used but "IsAsync = false"? Have pushed all changes.

Added System.IO.Pipes.PipeOptions.Asynchronous to make it async - didn't help :(

I have added this line: [-SplitInOutPipes](https://github.com/Xrumet/PowerShellTools/blob/74e1998e16742f71b7273b7174dcd68ad38c2b8d/Draft/ConsoleApp2/startup.ps1#L15) to startup.ps1, so session looks like that for me: ``` { "status": "started", "languageServiceTransport": "NamedPipeSimplex", "languageServiceReadPipeName": "\\\\.\\pipe\\in_PSES_xqriwnay.d1o", "languageServiceWritePipeName": "\\\\.\\pipe\\out_PSES_xqriwnay.d1o", "debugServiceTransport": "NamedPipeSimplex", "debugServiceReadPipeName": "\\\\.\\pipe\\in_PSES_w2ufkaig.dfj", "debugServiceWritePipeName":...

Wonder if Visual Studio debugging process have limited permissions so tried to run app manually with admin console: ![image](https://user-images.githubusercontent.com/72695570/145239704-175f3e82-023e-4140-b0f7-162f9f34ce87.png) no luck yet :(