-
-
Notifications
You must be signed in to change notification settings - Fork 136
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
Threads run in the context of pry/byebug hang in >= 2.0.0 #51
Comments
More specifically, the above threads work on pry-byebug commit 5c72fb5, but not 2 commits later b0eba72 (I can't test the commit in the middle because I get exceptions). It appears to be that it's simply of a matter of whether Byebug.start has been called or not (in the earlier version, Byebug.start was not called initially). Even on the earlier version, once the user has entered a command such as |
Could you try to reproduce this using latest |
@deivid-rodriguez Unfortunately it seems that in pry-byebug master 917c365 and byebug master 99bd3269deb790 the problem still remains. |
You means the problem remains separately in |
@deivid-rodriguez Running both Basic setup I have is rspec with Capybara and capybara-webkit. Capybara.javascript_driver = :webkit
RSpec.configure do |config|
#...
config.around(:each, js: true) do |example|
Capybara.using_driver(:webkit, &example)
end
end In the spec itself: require 'spec_helper'
describe 'Something', js: true do
it 'does something' do
before do
binding.pry
end
end
end Running the spec, when the Pry session starts, any call to |
Are you able to reproduce using byebug master only? |
@deivid-rodriguez Yep. That's what I did originally. I had the last release of pry-byebug I think and byebug master. |
@olivierlacan Did you uninstall If that's the case, open an issue in |
@deivid-rodriguez I tested again with the latest (after 091cff) in byebug. With byebug alone the problem does not seem to exist. With pry-byebug the problem remains for me and thoughtbot/capybara-webkit#718 seems to still be an issue for me too. |
@travisp I guess this is because pry-byebug is not using latest byebug's master. This should be fixed in next release. @olivierlacan Sorry if my last sentence sounded rude, it's missing "could you".. :) |
Closing for lack of feedback. Feel free to reopen if still happening. |
@deivid-rodriguez on pry-byebug 3.1.0 and byebug 4.0, as well as pry-byebug |
I just tried this and also ran into this issue. So still seems like an issue. |
This seems like a duplicate of #69. Let's comment there. |
On pry-byebug 1.3.3:
[1] pry(#<RSpec::Core::ExampleGroup::Nested_1>)> x = Thread.new { sleep 0.1; print "x"; print "y"; print "z" } => #<Thread:0x007fbfbb0337c0@(pry):1 sleep> [2] pry(#<RSpec::Core::ExampleGroup::Nested_1>)> x.join xyz=> #<Thread:0x007fbfbb0337c0@(pry):1 dead>
On pry-byebug 2.0.0:
[1] pry(#<RSpec::Core::ExampleGroup::Nested_1>)> x = Thread.new { sleep 0.1; print "x"; print "y"; print "z" } => #<Thread:0x007f807dd83600@(pry):1 sleep> [2] pry(#<RSpec::Core::ExampleGroup::Nested_1>)> x.join
^^ hangs indefinitely
We noticed this while trying to access a connection in capybara-webkit, where threads are used in the connection code: thoughtbot/capybara-webkit#718
The text was updated successfully, but these errors were encountered: