pry on 1.9.2-p290 gives #<LoadError: no such file to load -- coderay/tokens_proxy> #6

banister opened this Issue Sep 26, 2011 · 2 comments


None yet

2 participants


Hi, a few people running are complaining about this, see here: pry/pry#280

any idea?

@korny korny added a commit that referenced this issue Sep 26, 2011
@korny korny possible fix to issue #6 4782aae
korny commented Sep 26, 2011

It seems Rails is preventing autoload by removing the gem's load path from $:. I see two available options:

  1. load everything in advance
  2. set up autloading with absolute paths

I don't want to go 1. because autloading saves memory and time, especially when running CodeRay from the command line.

A version of 2. is in the above commit, in the autoload-fix branch. It fixes the pry issue on my system, but it's defining a Module#coderay_autoload method to do this. Any ideas how to avoid this?

korny commented Oct 15, 2011

Perhaps we can use autoloading just for the executable version; it seems it's not a good idea to use autoload in libraries.

@korny korny added a commit that referenced this issue Dec 27, 2011
@korny korny add test for #6 (pry autoload issue) b3807c5
@korny korny closed this Dec 27, 2011
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment