21 questions
-1
votes
0
answers
39
views
binding.pry debugger not working on Windows 11
I'm running into issues with binding.pry on Windows 11. When I insert it into my Ruby script, the program reaches that line but either skips over it or pauses without accepting any input.
🧪 Problem:
...
0
votes
2
answers
2k
views
Binding.pry not showing the stopping point in console after ruby 3 upgrade
I am new to ruby, we have a ROR microservice(rails version 6.1) , recently i updated the ruby version on the service from 2.7 to 3.0 , after this since there were failures and i wanted to debug it, so ...
2
votes
1
answer
64
views
Unexplained pry behavior in Ruby
The bug on line 11 is put there on purpose. I am curious about how pry works in this example.
In the code below, when I enter pry, if I type name I get nil, which means that pry is outputting the ...
1
vote
1
answer
276
views
How to use helpers in pry-byebug?
In the rails console, we can prepend helper. to helpers to use them, like so:
helper.time_ago_in_words(Time.now - 60*60*2)
but this doesn't work in the server console during a pry-byebug debugging
...
0
votes
1
answer
919
views
Rspec binding.pry from method
I'm trying to use binding.pry on method and debug it.
A simplified example of what I'm trying to do.
hello.rb
class Hello
def self.hello
'Hello world!'
binding.pry
end
end
spec/hello_spec.rb
...
1
vote
0
answers
339
views
Rails pry-byebug not accessed
I am trying to debug my code using the pry-byebug tool, but when I launch "rails console" in my terminal and then call on the class method in which the debugger should come into action, nothing ...
0
votes
1
answer
223
views
Form submit button not hitting movies#create in Rails
I'm attempting to submit a form in Rails, and it's not creating into the db. I tried placing a binding.pry in the controller action but I'm not reaching it. Can you take a look at my form below and my ...
4
votes
2
answers
17k
views
Cannot load 'pry' - `require': cannot load such file -- pry (LoadError)
I'm trying to debug a simple ruby console script and am getting a load error when trying to require pry:
I'm using rbenv to management environment.
I'm using Ruby version:
2.3.1.
Trying to use Pry '~>...
3
votes
1
answer
790
views
Ruby (bundler) How to automatically require Pry
Given a Gemfile containing:
source 'https://rubygems.org'
gem 'pry'
And a ruby file containing:
require 'bundler/setup'
# NOT using this line:
# require 'pry'
binding.pry
I am getting this error: ...
0
votes
1
answer
2k
views
Pry Remote / ByeBug next goes into Teardown
So I've decided to split my last post since the bug is Related to ByeBug more than to Pry-Remote (I think). Last post URL: Pry-Remote not triggered Rails 4
Problem:
When typing Next in Pry-Remote, ...
1
vote
1
answer
144
views
Using Rails4.1.1 and Ruby 2.0.0, binding.pry's terminal output is sometimes empty
I'm trying to debug a Rails 4.1.1 app using binding.pry but more often than not when the execution breaks and I try to show the values of my variables it just returns an empty string, or nothing (hard ...