# \[1.9/12928\] problem with -r debug

**URL:** <https://www.ruby-forum.com/t/1-9-12928-problem-with-r-debug/112014>\
**Category:** Ruby\
**Created:** [August 14, 2007, 10:11am UTC](https://www.ruby-forum.com/t/1-9-12928-problem-with-r-debug/112014 "2007-08-14T10:11:24Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![keltia](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/k/da6949/32.png) [@keltia](https://www.ruby-forum.com/u/keltia)\
**Post date:** [August 14, 2007, 10:11am UTC](https://www.ruby-forum.com/t/1-9-12928-problem-with-r-debug/112014/1 "2007-08-14T10:11:24Z")

</div>

Hello,

I’m running 1.9 from svn (revision 12928) on OS X. I appreciate that  
the hooks for the debugger have been put in place but trying to run a  
program in it leads to this as soon as I hit “s” on some lines:

321 [9:40] roberto@roberto-al:HG/raw-scripts\> /usr/local/bin/ruby -r  
debug find-photos.rb ~/Documents  
Debug.rb  
Emacs support available.

find-photos.rb:20:$KCODE = “u”  
(rdb:1) b main  
Set breakpoint 1 at find-photos.rb:main  
(rdb:1) c  
0: ArgumentError

or

find-photos.rb:181: def keys  
(rdb:1)  
s  
find-photos.rb:187: def   
(rdb:1)  
s  
find-photos.rb:195:def main(argv)  
(rdb:1)  
s  
find-photos.rb:216:if $0 == **FILE** then  
(rdb:1)  
s  
find-photos.rb:217: exit(main(ARGV) || 1)  
(rdb:1)  
s  
0: ArgumentError

code fragment is

…  
if $0 == **FILE** then  
exit(main(ARGV) || 1)  
end

Any idea?
