Open tculbert opened 2 years ago
That way invokes debugging using UNIX domain sockets. Since there is no documentation or know-how for using UNIX domain sockets on Windows, I thought it would be hard to expect any future modification to work on Windows.
Debugging using a remote connection via TCP/IP is available instead.
1. Suppose that the debug target folder is open in VS Code.
2. Start debugging with the following in the console: rdbg --open --port 1234 script_to_debug.rb
3. With VS Code's Active Bar selected, select Attach with rdbg and press Start Debugging.
@tculbert, could you try @golirev 's steps?
I'm running the launch.json in vs 1.71.2 from within vs in the run and debug area. rspec - 3.11 ffi - 1.15 debug 1.6 rdbg 1.6.2
ruby -v
:rdbg -v
:Describe the bug Error output: C:/Ruby31-x64/lib/ruby/gems/3.1.0/gems/debug-1.6.2/lib/debug/config.rb:415:in
check_dir_authority': C:/Users/tculbert/AppData/Local/Temp/ruby-debug-sock-0's mode is 40755 (should be 040700) (RuntimeError) from C:/Ruby31-x64/lib/ruby/gems/3.1.0/gems/debug-1.6.2/lib/debug/config.rb:432:in
unix_domain_socket_tmpdir' from C:/Ruby31-x64/lib/ruby/gems/3.1.0/gems/debug-1.6.2/lib/debug/config.rb:452:inunix_domain_socket_dir' from C:/Ruby31-x64/lib/ruby/gems/3.1.0/gems/debug-1.6.2/lib/debug/config.rb:466:in
create_unix_domain_socket_name' from C:/Ruby31-x64/lib/ruby/gems/3.1.0/gems/debug-1.6.2/lib/debug/client.rb:20:inutil' from C:/Ruby31-x64/lib/ruby/gems/3.1.0/gems/debug-1.6.2/lib/debug/config.rb:368:in
block (2 levels) in parse_argv'Error: exit code is 1 Make sure to install rdbg command (
gem install debug
). If you are using bundler, writegem 'debug'
in your Gemfile. [Start session] {"_debugServiceProxy":{},"_id":"549c291c-e660-4a33-b942-da6e53d04476","_type":"rdbg","_name":"Debug current file with rdbg","_workspaceFolder":{"uri":{"$mid":1,"fsPath":"c:\Users\tculbert\Documents\Selenium Class\Ex_Files_Learning_Selenium\Exercise Files","_sep":1,"external":"file:///c%3A/Users/tculbert/Documents/Selenium%20Class/Ex_Files_Learning_Selenium/Exercise%20Files","path":"/C:/Users/tculbert/Documents/Selenium Class/Ex_Files_Learning_Selenium/Exercise Files","scheme":"file"},"name":"Exercise Files","index":0},"_configuration":{"type":"rdbg","name":"Debug current file with rdbg","request":"launch","command":"rspec","script":"blog-test.rb","args":[],"askParameters":true,"__configurationTarget":6}} my launch file: { // Use IntelliSense to learn about possible attributes. // Hover to view descriptions of existing attributes. // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387 "version": "0.2.0", "configurations": [ { "name": "RSpec - all", "type": "Ruby", "request": "launch", "program": "${workspaceRoot}/bin/rspec", "args": [ "-I", "${workspaceRoot}" ] },} To Reproduce
Expected behavior I'm expecting not to get the error and have my code run
Additional context I've looked at the other 2 related bugs and have added the debugport, but that hasn't fixed the issue.