Lou Pecora [EMAIL PROTECTED] wrote:
Impressive, but YIKES, there ought to be a simpler way to do this. I
think during the development phase editing and reloading would be very
common and you'd want everything updated.
Sorry I missed this thread...
This is what I use which is easy and
Alex Martelli wrote:
Michele Simionato [EMAIL PROTECTED] wrote:
You want this recipe from Michael Hudson:
http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/160164
automatically upgrade class instances on reload()
Note that the version in the printed Cookbook (2nd edition)
Peter Otten [EMAIL PROTECTED] wrote:
Alex Martelli wrote:
Michele Simionato [EMAIL PROTECTED] wrote:
You want this recipe from Michael Hudson:
http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/160164
automatically upgrade class instances on reload()
Note that
Thanks all for the responses. Extra kudos to Steve J and Michele S.
that cleared it up for me.
the context of my question comes from reading up on Lisp in Loving
Lisp - the Savy Programmer's Secret Weapon,
http://www.markwatson.com/opencontent/lisp_lic.htm, where the author
described building up
Lou Pecora enlightened us with:
Impressive, but YIKES, there ought to be a simpler way to do this.
I think during the development phase editing and reloading would be
very common and you'd want everything updated.
I hardly ever reload stuff manually during development. I write a
script, and
I am experimenting with the interactive interpreter environments of
Python and Ruby and I ran into what seems to be a fundamental
difference. However I may be doing something wrong in Python. Please
comment and correct me if I am wrong
In both languages, you can start up the interactive
dmh2000 wrote:
I am experimenting with the interactive interpreter environments of
Python and Ruby and I ran into what seems to be a fundamental
difference. However I may be doing something wrong in Python. Please
comment and correct me if I am wrong
In both languages, you can start up the
dmh2000 enlightened us with:
When you want to change something, you can edit those same source
files outside the environment and reload them from within the
interactive environment. But, here is the difference: with Python,
when you reload the source file (module in Python terms), it seems
dmh2000 wrote:
I am experimenting with the interactive interpreter environments of
Python and Ruby and I ran into what seems to be a fundamental
difference. However I may be doing something wrong in Python. Please
comment and correct me if I am wrong
In both languages, you can start up the
In both languages, you can start up the interactive interpreter
('python' and 'irb'), load source files and do stuff, like create
objects and call their methods. When you want to change something, you
can edit those same source files outside the environment and reload
them from within the
You want this recipe from Michael Hudson:
http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/160164
automatically upgrade class instances on reload()
--
http://mail.python.org/mailman/listinfo/python-list
I think reload should be preceded by import.
Example:
Online code modification: upon modifying and saving mytest.py issue on
the interactive shell:
import mytest
reload(mytest)
The shell should respond with module 'mytest' from
'/root/mytest.py' (NOT:mytest.pyc)
Note that
Michele Simionato [EMAIL PROTECTED] wrote:
You want this recipe from Michael Hudson:
http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/160164
automatically upgrade class instances on reload()
Note that the version in the printed Cookbook (2nd edition) was
substantially
In article [EMAIL PROTECTED],
Michele Simionato [EMAIL PROTECTED] wrote:
You want this recipe from Michael Hudson:
http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/160164
automatically upgrade class instances on reload()
Impressive, but YIKES, there ought to be a simpler
14 matches
Mail list logo