Please sign in to comment.
Switch auto reload implementation to use reload()
Auto reloading python code is notoriously tricky. With this change the logic switches from direct manipulation of sys.modules (with regex filters for protection) to calling python's reload() function. A stale check is added, to avoid reloading things that haven't changed. This is still a very basic implementation that will undoubtedly fail to reload code in some cases, and easily could load code problematically in other cases. Just a little reading on mod_python, mod_wsgi, and django will provide some insight into how challenging this task can be.
- Loading branch information...