|
|
|
|
|
by S4M
2755 days ago
|
|
> But in Python you're limited to working on the context of a single module. If you modify a module that was imported then you have to restart the REPL because you can't reload modules. It just doesn't work. This is so frustrating, the Python REPL does some kind of module caching, and I haven't found how to disable it. When I asked on IRC a few years ago, I was told that I was using the REPL for the wrong purpose. |
|
Here is the option I have in my profile file. You can run this command inside the ipython session as well:
%autoreload 2
The times I have seen auto-reload fail is when there is lot of class creation magic going on or while dealing with global connection objects which sql alchemy might be creating. But, other than that it works very nicely.