On Wed, 30 Jan 2019 at 16:34, Alex Walters <[email protected]> wrote:
> > > > -----Original Message----- > > From: Python-ideas <python-ideas-bounces+tritium- > > [email protected]> On Behalf Of Jonathan Fine > > Sent: Wednesday, January 30, 2019 6:40 AM > > To: python-ideas <[email protected]> > > Subject: Re: [Python-ideas] Stack traces ought to flag when a module has > > been changed on disk > > > > I think Steve's suggestion fails in this situation. Suppose wibble.py > > contains a function fn. Now do > > import wibble > > fn = wibble.fn > > # Modify and save wibble.py > > reload(wibble) > > fn() > > > > I think using reload should raise warnings, since it doesn't work, and the > reload case shouldn't be the killer of this really good idea. > > Reload isn't the issue here. Even without the reload the call to `fun()` will no longer match the file on disk. reload was moved to the imp module for exactly that reason. Michael > > I've posted a message to this effect in the original bug > > https://bugs.python.org/msg334553 > > > > Please note that the original poster, after the cause has been > > explained, is happy for the bug to be closed. > > https://bugs.python.org/msg334551 > > > > Perhaps move discussion back to https://bugs.python.org/issue35857. > > -- > > Jonathan > > _______________________________________________ > > Python-ideas mailing list > > [email protected] > > https://mail.python.org/mailman/listinfo/python-ideas > > Code of Conduct: http://python.org/psf/codeofconduct/ > > _______________________________________________ > Python-ideas mailing list > [email protected] > https://mail.python.org/mailman/listinfo/python-ideas > Code of Conduct: http://python.org/psf/codeofconduct/ > -- http://www.michaelfoord.co.uk/ May you do good and not evil May you find forgiveness for yourself and forgive others May you share freely, never taking more than you give. -- the sqlite blessing http://www.sqlite.org/different.html
_______________________________________________ Python-ideas mailing list [email protected] https://mail.python.org/mailman/listinfo/python-ideas Code of Conduct: http://python.org/psf/codeofconduct/
