Though I primarily use vim, I got VSCodium so I could use it as a debugger since its much easier to set up. I am having alot of trouble getting any use out of it though, when I run the program the IDE gives me errors if I type in the debug console, and closes the terminal if I type in the integrated terminal. I've changed the config to allow integrated terminal, but nothing has changed.
Can anyone help me figure this out, or recommend an alternative tool for debugging a C# program?
Edit: I finally found my answer: https://discuss.cachyos.org/t/debugging-c-console-apps-on-linux-with-vs-codium-readline-input-not-working/16493
Unfortunately there is no FOSS way to debug a C# application in VSCodium. Might have to see what this lldb tool is.
10 Comments
nark3d@thelemmy.club · 6 pts · 83d
The limitation is the debug adapter, not VSCodium itself. The FOSS C# adapter, netcoredbg, can't feed stdin through the integrated terminal. Only Microsoft's vsdbg does that, and its licence ties it to official VS Code and Visual Studio. The way round it that's worked for me is to skip launch mode and attach instead: start the program yourself in a normal terminal, then use an attach configuration to hook netcoredbg onto the running process. You get breakpoints and inspection, and since it's a real terminal the stdin behaves. Not as smooth as launch, but it stays fully FOSS.
dr_robotBones@reddthat.com · 1 pts · 83d
Thank you, I'll have to research how to do that!
abbadon420@sh.itjust.works · 2 pts · 84d
I use jetbrains ide's, but I imagine you can set your run environment with parameters.
dr_robotBones@reddthat.com · 2 pts · 84d
It seems JetBrains or the proprietary version of VSCode are the only convenient options, but they're so intrusive...
xianjam@programming.dev · 1 pts · 76d
Hi, I'm not quite sure what you're asking, but .NET debugging is possible inside of VSCodium with the DotRush extension.
dr_robotBones@reddthat.com · 0 pts · 76d
Without Microsoft's proprietary debugger, it is not possible to get input from Console.ReadLine() in VSCodium's integrated terminal or debug console. That's the problem I was having. I'll have to debug using external txt files.
Feyd@programming.dev · 1 pts · 84d
https://code.visualstudio.com/docs/debugtest/debugging-configuration
dr_robotBones@reddthat.com · 3 pts · 84d
Yes that's how I set it to integratedTerminal
Edit: That probably is the solution on VSCode, but I found out the only debuggers available on VSCodium do not have anyway to connect to the terminal
Feyd@programming.dev · 4 pts · 84d
That could be. I think c# in vscode proper has some proprietary secret sauce :(
FizzyOrange@programming.dev · 0 pts · 83d
Depending on your program you could mock out your terminal input.