Ruby seems to be passing over a breakpoint in a class initialize
function. “Got grid” is the only break that occurs before the program
hits a bug. What is Grid.new doing, and how come the “Grid initialized”
breakpoint wasn’t found or didn’t work?
Ruby seems to be passing over a breakpoint in a class initialize
function. “Got grid” is the only break that occurs before the
program hits a bug. What is Grid.new doing, and how come the “Grid
initialized” breakpoint wasn’t found or didn’t work?
Is this perhaps an issue of inheriting from a core class? I know
there are lots
of gotcha’s when you do this because the normal method dispatch tends
to be bypassed.
Maybe try delegating to Array instead.
Well I’m not sure what else is in your real code, but I just tried
this, and it works.
Does it work in a Rails app? Breakpoints in the controller file work,
and everything else works from the command line, but other than
breakpoints in the controller file, I haven’t gotten anything to work
from Rails:
breakpoints
printing to standard output
printing to a log file
made the class free-standing, not derived from anything
require ‘breakpoint’
require ‘rubygems’; require_gem ‘ruby-breakpoint’
Nothing. Not one single thing has worked outside the controller file.
And there’s not even a useful error message, just an “Internal Server
Error” on the client. I have no idea what I’m missing. Is there some
special place the files have to be? I have them in a subdirectory of
controllers.
Ruby seems to be passing over a breakpoint …
Okay, it looks like require doesn’t look for a new copy of a file when
you edit it. load seems to work, but is there a way to make sure you
only load once, other than C-style tricks?
This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.