Code Monkey home page Code Monkey logo

Comments (23)

MickeyNT avatar MickeyNT commented on June 13, 2024 2

Hi @HJLebbink,

today I had a little bit time to try out the solution using SecurityIdentifier instead of named groups for creating PipeAccessRule(s).
It seems it works well (I also see the communication between VS 2022 and AsmDude2.LSP.exe) so I would just share my changes here. In the files

\repos\asm-dude\VS\CSHARP\asm-dude2-vsix\AsmLanguageClient.cs and
\repos\asm-dude\VS\CSHARP\asm-dude2-ls\Worker.cs

create PipeAccessRule as follows:
SecurityIdentifier everyone = new SecurityIdentifier(WellKnownSidType.WorldSid, null); PipeAccessRule pipeAccessRule = new(everyone, PipeAccessRights.ReadWrite, System.Security.AccessControl.AccessControlType.Allow);
I had trouble with the preview version of the MS LanguageServer packages so I made my changes based on
2b897a0

Regards from Stuttgart

from asm-dude.

HJLebbink avatar HJLebbink commented on June 13, 2024 2

@MickeyNT, thanx this seems to have fixed the issue for my windows 10 setup, i hope this will also fix it for those other users out there. Great thanx! See https://github.com/HJLebbink/asm-dude/releases/tag/v2.0.1.0

from asm-dude.

ElDuderinoBerlin avatar ElDuderinoBerlin commented on June 13, 2024

I have Windows 11 and it doesn't work.


Microsoft Visual Studio

AsmDude2 Language Server Protocol (LSP) failed to activate.
System.Security.Principal.IdentityNotMappedException: Some or all identity references could not be translated.

at System.Security.Principal.NTAccount.Translate(IdentityReferenceCollection sourceAccounts, Type targetType, Boolean forceSuccess)

at System.Security.Principal.NTAccount.Translate(Type targetType)

at System.Security.AccessControl.CommonObjectSecurity.ModifyAccess(AccessControlModification modification, AccessRule rule, Boolean& modified)

at System.Security.AccessControl.CommonObjectSecurity.AddAccessRule(AccessRule rule)

at AsmDude2.AsmLanguageClient.d__23.MoveNext() in C:\Source\Github\asm-dude\VS\CSHARP\asm-dude2-vsix\AsmLanguageClient.cs:line 269

--- End of stack trace from previous location where exception was thrown ---

at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()

at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)

at Microsoft.VisualStudio.LanguageServer.Cl...

OK

from asm-dude.

LeonsCodeLab avatar LeonsCodeLab commented on June 13, 2024

Exactly the same for me.

from asm-dude.

HJLebbink avatar HJLebbink commented on June 13, 2024

Still no help from Microsoft on this, and I'm at a loss what can cause it. I can easily reproduce the issue on one of my development machines, wasted more than 30 hours on trying to fix it. I'm sorry, I'm only an assembly programmer... not an Windows 10 internals hacker...

from asm-dude.

MickeyNT avatar MickeyNT commented on June 13, 2024

Maybe this info helps you
The user group "Everyone" doesn't exist on my German Windows 11. So if I create the new group "Everyone" and add the "Jeder" group into it the above exception will be no more thrown. Unfortunately the syntax highlighting still doesn't work ..

from asm-dude.

HJLebbink avatar HJLebbink commented on June 13, 2024

The thing is, these security and authentication details have changed between 10 and windows 11 (it seems), and nobody seems to care to figure this out for old windows versions.

from asm-dude.

HJLebbink avatar HJLebbink commented on June 13, 2024

Thank you for your time; I'll look at it tonight straight away.

from asm-dude.

Nespelem-3000 avatar Nespelem-3000 commented on June 13, 2024

It works!
asm_dude_win_10_fixed

from asm-dude.

HJLebbink avatar HJLebbink commented on June 13, 2024

It works!

That is good news! TY for the update.

from asm-dude.

lstrsrt avatar lstrsrt commented on June 13, 2024

Unfortunately still having this issue on 21H2 (19044). This error always comes up after a couple of minutes. I'll install a 22H2 VM tomorrow and see if it works there.

Pwcf0XvEYu_cropped

from asm-dude.

HJLebbink avatar HJLebbink commented on June 13, 2024

@lstrsrt Please let me know if you keep having issues, or when you have solved this. I would like to understand what causes these issues.

from asm-dude.

Kule02 avatar Kule02 commented on June 13, 2024

It's also not working for me on Windows 10 Pro 22H2 OS build: 19045.3996. I'm not sure how to provide anything that could help narrow it down or fix it myself. I get the same message as lstrsrt along with this pop up in the bottom left.

Screenshot 2024-02-28 150801

from asm-dude.

bastiel avatar bastiel commented on June 13, 2024

@HJLebbink I noticed that the highlighting settings work for everything except the registers. If I edit the colors or enable the italicization for the regiters, I'll get an LSP failed to activate error, but mine is because the path to AsmDude's LSP.exe was denied.

I've ran VS Studio as an admin and even installed via the Github installer but the errors are the same. It seems to be inconsistent for me because it'll work randomly on different W10 machines while others give the error.

from asm-dude.

HJLebbink avatar HJLebbink commented on June 13, 2024

@Kule02

It's also not working for me on Windows 10 Pro 22H2 OS build: 19045.3996. I'm not sure how to provide anything that could help narrow it down or fix it myself. I get the same message as lstrsrt along with this pop up in the bottom left.

I didn't keep track of the windows versions that did not work for me (which would have been useful to understand the cause), but my working setup currently has 19045.4046. It must be some optional component that fixes or breaks this. Thus, you have the LSP running but connection to it times out?

from asm-dude.

HJLebbink avatar HJLebbink commented on June 13, 2024

@bastiel I think the error "LSP failed to activate" is because the LSP could not start. You say that it works on some W10 boxes but not on others, On the machines that it does not work, is the LSP running, if not, is it even installed?

Everybody thanx for helping out. This is a nice example of "Hidden Windows Costs..."

from asm-dude.

Kule02 avatar Kule02 commented on June 13, 2024

@HJLebbink I updated to 19045.4046 but still no luck. The syntax highlighting (mostly) works, like bastiel mentioned. I tried disabling the syntax highlighting to see if anything would happen and I got this error:

Screenshot 2024-02-29 115433

If I leave the extension to timeout, it displays these errors:

Screenshot 2024-02-29 121559

Screenshot 2024-02-29 121706

from asm-dude.

MickeyNT avatar MickeyNT commented on June 13, 2024

Hi,
On my old PC I have the German Windows 10 Home / 22H2 19045.4046. I have just installed VS 2022 and the current version of AsmDude2. The syntax highlighting works but after some time the above error message will be displayed. I can help to solve the issue however I could not find the LSP version 17.8.9-preview. How can I download it?
I would create a debug version and check the errors with it....

from asm-dude.

Sudsey avatar Sudsey commented on June 13, 2024

Chiming in. On version 2.0.1.0, I get syntax highlighting, but no help-on-hover or suggestions. After a few minutes I get the same "AsmDude2 Language Server Protocol (LSP) failed to activate. ..." error as reported above. Windows 11 Home 23H2 22631.3155. Happy to pull out any logs or perform troubleshooting requested.

edit: Partially resolved - this is a new installation and the LSP required the .NET 7 Desktop Runtime, which wasn't installed. @Kule02 's output log was the clue - I didn't get that message, but running that executable in a terminal window spat out the standard missing runtime error. Help-on-hover now works but still no code suggestions.

from asm-dude.

Yogurt4 avatar Yogurt4 commented on June 13, 2024

Still having this problem.
Windows 10 22H2 19045.4123, VS Community 2022 (64-bit) 17.9.1, Asmdude2.v2-0-1-0
(By the way, why still 2.0.0.4 is the "latest" here while you can download 2.0.1.0 from the VS Marketplace?)

The same error as for @Kule02.

from asm-dude.

bastiel avatar bastiel commented on June 13, 2024

@bastiel I think the error "LSP failed to activate" is because the LSP could not start. You say that it works on some W10 boxes but not on others, On the machines that it does not work, is the LSP running, if not, is it even installed?

Sorry for the late reply @HJLebbink. I wasn't able to check this, but I installed .NET 7 Desktop Runtime like @Sudsey. The error no longer pops up, and some features like code folding and register highlighting even work now - but like @Sudsey, code completion doesn't work.

Initially, after install .NET 7, everything but the code completion and register highlighting didn't work. I changed Assembly Flavour to "Auto Detect" from Intel MASM, and the register highlighting works now. But as previously mentioned, code completion does not.

from asm-dude.

 avatar commented on June 13, 2024

I installed .NET 9 Desktop and still getting the LSP failure. The MASM highlighting is working if I select both choices to MASM since I am writing that code x86-64.

** Is there a way to turn off the LSP so I just get the syntax highlight (for MASM)?? **

If you know how to turn off the constant LSP failure pop ups I would like to know that, thanks!

from asm-dude.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.