6

I have a Rails application using Better Errors, but the error pages won't load the binding_of_caller interactive shell (REPL). Instead, it still just shows:

Tip: add gem "binding_of_caller" to your Gemfile to enable the REPL and local/instance variable inspection.

My Gemfile has:

group :development, :test do
    gem 'debugger'
    gem 'better_errors'
    gem 'binding_of_caller' #, :platforms=>[:mri_19, :mri_20, :rbx]

The last part I've tried either commented or uncommented. When attempting "require 'binding_of_caller'" in a Rails console it returns false rather than erroring, implying it has been loaded properly. The Gemfile.lock shows the following versions:

rails (4.1.0.rc2)
better_errors (1.1.0)
  coderay (>= 1.0.0)
  erubis (>= 2.6.6)
binding_of_caller (0.7.2)
  debug_inspector (>= 0.0.1)

What might be wrong? What other code should I provide to find clues as to what went wrong?

Kiara Grouwstra
  • 5,723
  • 4
  • 21
  • 36
  • 1
    `better_errors` is not dependent on `binding_of_caller`. I'm running it without it. it must be a bug – Wally Ali May 25 '14 at 05:27
  • Thank you for your reply. Yes, better_errors itself is functioning properly, though the added functionality of live debugging would be much welcomed. Perhaps you're right, maybe I should file a bug report on Github... – Kiara Grouwstra May 25 '14 at 06:07
  • the REPL (live shell) is also working for me. all I had to do was:`gem 'better_errors'` generate a new project with scaffold. then add better_errs gem to see if you get similar results. – Wally Ali May 25 '14 at 06:18
  • already reported https://github.com/charliesome/better_errors/issues/243 – matanco May 25 '14 at 06:22
  • @matanco: that issue appears to be about better_errors not working at all; for me better_errors itself does. – Kiara Grouwstra May 25 '14 at 07:10
  • @Tycho ever figure out this issue? – you786 May 11 '16 at 15:13
  • @you786: sorry, I don't even recall :(, I stopped doing Ruby quite a while ago. – Kiara Grouwstra May 14 '16 at 06:43

1 Answers1

0

Check to see if:

config.consider_all_requests_local = true

is set in your config/environments/development.rb

Also, if you are using a sublime editor,you can add:

BetterErrors.editor = :sublime if defined? BetterErrors

in your config/initializers folder by naming a file "better_errors.rb"

Let me know if this helps?

gkstr1
  • 51
  • 3