Lighthouse has a new layout. Prefer the old one? Return to the old layout, and switch back any time from the link at the top of each page.

This project is archived and is in readonly mode.

reload! does not reload environment

#1258

I am testing a new model with script/console. I have created instances and used Class.find to retrieve instances of my new model. Life is good.

I have just added a method "frobnicate" and it's not quite right.

I add to frobnicate the poor man's debug of 'puts "work damn you!"'.

I then go to the console and issue reload!

I then issue instance.frobnicate and the puts statement is not printed.

I exit script/console, restart it, get a new instance ( either with find or create ) and issue instance.frobnicate and, viola, i get the output.

If i issue load 'lib/class_containing_frobnicate' instead of 'reload!' all works properly without requiring a drop to the shell.

Reported by sgharms · October 23rd, 2008 @ 06:52 AM

State: wontfix
Milestone: 2.x
Assigned to: nobody
Importance: none

Activity

  1. sgharms
    sgharms

    Relevant versions:

    bash-3.2$ rails --version Rails 2.1.1 bash-3.2$ ruby --version ruby 1.8.6 (2007-09-23 patchlevel 110) [i686-darwin9.1.0] bash-3.2$ psql --version psql (PostgreSQL) 8.2.5 contains support for command-line editing bash-3.2$

    October 23rd, 2008 @ 01:26 PM

  2. sgharms
    sgharms

    I plead ignorance, this need not be considered.

    October 30th, 2008 @ 10:56 PM

  3. josh
    josh
    • State changed from new to wontfix

    December 3rd, 2008 @ 03:45 PM