I’m trying to use Pry with spork and it doesn’t work for me. The issue
seems that reading from stdin does not block, so Pry does not block. Any
read from STDIN returns right away.
rspec -X console.rb
File follows:
require ‘spec_helper’
describe ‘console’ do
it ‘opens!’ do
Pry.config.input = STDIN
Pry.config.output = STDOUT
puts STDIN.closed? # returns false
binding.pry # returns right away, does not block
gets # returns right way, does not block
end
end
Do you guys have any idea on how I can go about debugging this? I want
to inspect what kind of file descriptor is STDIN, and it might be a
pipe, but I didn’t get much further than that.