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

Debugger terminates #87

Open
tomaszwojcik opened this issue Aug 13, 2013 · 10 comments
Open

Debugger terminates #87

tomaszwojcik opened this issue Aug 13, 2013 · 10 comments

Comments

@tomaszwojcik
Copy link

Every time I run :Rdebugger I get message Command terminated.
Tested with ruby 2.0 and 1.9.3 and mvim 7.4.

Any ideas why it happens?

@tomaszwojcik
Copy link
Author

Log file contents (I noticed the rails part, however I want to run debugger for non-rails projects as well):

Vim plugin, 15:28:08: Executing :Rdebugger...
Vim plugin, 15:28:08: Initializing Server object
Vim plugin, 15:28:08: Stopping, pid is:
Vim plugin, 15:28:08: Starting Server, command: "'/Users/twojcik/playground/script/rails' server"
Vim plugin, 15:28:08: Executing command: rdebug-vim --file /Users/twojcik/.vim/bundle/vim-ruby-debugger/tmp/ruby_debugger --output /Users/twojcik/.vim/bundle/vim-ruby-debugger/tmp/ruby_debugger_output --socket /var/folders/ky/bzrkq4v1661c7wpbvjxj7h4w0000gn/T/vkenQjL/6 --logger_file /Users/twojcik/.vim/bundle/vim-ruby-debugger/tmp/ruby_debugger_log --debug_mode 1 --vim_executable mvim --vim_servername --separator ++vim-ruby-debugger-separator++ -- '/Users/twojcik/playground/script/rails' server
Vim plugin, 15:28:09: PID:
Vim plugin, 15:28:09: Waiting for starting debugger...

@astashov
Copy link
Owner

Weird. Try to run this command from your logs just from console:

rdebug-vim --file /Users/twojcik/.vim/bundle/vim-ruby-debugger/tmp/ruby_debugger --output /Users/twojcik/.vim/bundle/vim-ruby-debugger/tmp/ruby_debugger_output --socket /var/folders/ky/bzrkq4v1661c7wpbvjxj7h4w0000gn/T/vkenQjL/6 --logger_file /Users/twojcik/.vim/bundle/vim-ruby-debugger/tmp/ruby_debugger_log --debug_mode 1 --vim_executable mvim --vim_servername --separator ++vim-ruby-debugger-separator++ -- '/Users/twojcik/playground/script/rails' server

@tomaszwojcik
Copy link
Author

I got no output at all in the console. Maybe it's something with a hanging debugger (it keeps waiting at the end of log)?

@astashov
Copy link
Owner

Hmm, you should get the PID after executing this command...
And you use Rails >= 3.0, right?

@tomaszwojcik
Copy link
Author

Yes, I have tested following scenarios, both for ruby 1.9.3 and 2.0 and rails 4.0:

  1. Open vim in dir with file.rb (then do :Rdebugger)
  2. Open vim in rails app dir (and run :Rdebugger)

Both scenarios give me no pid. I launch vim using mvim -v command in the console.

@astashov
Copy link
Owner

Hmm, and if you just run script/rails server from console, it starts the server correctly?

@tomaszwojcik
Copy link
Author

Yes, no problems at all. I also double checked my .vimrc and installation instructions.

@astashov
Copy link
Owner

That sucks. :( The only thing I could recommend to do - debug rdebug-vim, which is part of 'debugger-xml' gem, and figure out why the PID is not printed as it should (here - https://github.com/astashov/debugger-xml/blob/master/lib/debugger/xml/extensions/vim_server.rb#L42) The problem is somewhere there, not inside vim-ruby-debugger itself.

@tomaszwojcik
Copy link
Author

Aww :( I will try to debug that gem (and report if succeed). Thanks for help!

@astashov
Copy link
Owner

No problem. :) Feel free to create the Pull Request there, if you find the source of the issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants