[issue44091] traceback & inspect modules should verify that the .py source file matches the one that the running process is using

2021-09-02 Thread Gregory P. Smith
Gregory P. Smith added the comment: FWIW I don't remember the context that led me to just file the issue this year. The most serious frequent instances of this I remember happening were all many years ago when a less capable software distribution mechanism was in use. A scenario where I

[issue44091] traceback & inspect modules should verify that the .py source file matches the one that the running process is using

2021-09-01 Thread Guido van Rossum
Guido van Rossum added the comment: All legit cases, I agree, but are they worth the considerable work? -- ___ Python tracker ___

[issue44091] traceback & inspect modules should verify that the .py source file matches the one that the running process is using

2021-09-01 Thread Irit Katriel
Irit Katriel added the comment: It's not only a software updates issue - these kinds of problems show up for developers when they change the code on disk while a program is running and some traceback or pdb show code from the disk which is confusing. I also saw an issue about changing

[issue44091] traceback & inspect modules should verify that the .py source file matches the one that the running process is using

2021-09-01 Thread Guido van Rossum
Guido van Rossum added the comment: This sounds like a project requiring a considerable amount of plumbing to get the info from where it's available to where it's needed. For example, importlib reads the PYC file, checks the header, and then passes the rest of the file to marshal.loads(),

[issue44091] traceback & inspect modules should verify that the .py source file matches the one that the running process is using

2021-09-01 Thread Irit Katriel
Irit Katriel added the comment: While we're changing code objects, perhaps consider this as well? -- nosy: +gvanrossum, iritkatriel ___ Python tracker ___

[issue44091] traceback & inspect modules should verify that the .py source file matches the one that the running process is using

2021-05-09 Thread Gregory P. Smith
New submission from Gregory P. Smith : A long-standing wart in Python is that once a module is loaded, when rendering a traceback and including source lines, we do not verify if the source file we're loading is the same as the one representing the code we are running. It could have been