]> granicus.if.org Git - python/commit
#5258/#10642: print fn, line, traceback and continue when .pth file is broken
authorR. David Murray <rdmurray@bitdance.com>
Sun, 26 Dec 2010 19:54:29 +0000 (19:54 +0000)
committerR. David Murray <rdmurray@bitdance.com>
Sun, 26 Dec 2010 19:54:29 +0000 (19:54 +0000)
commitb4ca59b783d6d2047c34eb242d97272d81b94688
treeb2195b8992551247c8075615e139af818068bdc7
parente6f1e435d4e01d2fdb349610565e99b792ace1a8
#5258/#10642: print fn, line, traceback and continue when .pth file is broken

If a .pth file contained an error, it could cause a traceback in site.py,
terminating its processing.  In 2.7 and 3.2, the interpreter will then not
start.  Previously, a message would print saying to use -v to get the
traceback.  In either case, the traceback generated for a failed .pth file did
not include the .pth filename, making it difficult to debug the problem.  Now
site.py reports not only the .pth filename but also the line number causing the
error, and just skips the remainder of the file.
Lib/site.py
Lib/test/test_site.py
Misc/NEWS