[issue26587] Possible duplicate entries in sys.path if .pth files are used with zip's

SilentGhost report at bugs.python.org
Sun Mar 20 07:53:07 EDT 2016


SilentGhost added the comment:

Thanks for this, Mandeep. I don't think it is entirely the same issue that Wolfgang is describing. He's particularly concerned about the clash of .zip files from the sys.path with ones coming from .pth files for example. And while the proposed fix would resolve the issue, I don't feel it would be entirely correct. For the record, I'm not even sure sys.path is guaranteed to be contain no duplicates, at least I wasn't able to find a statement to that effect in the docs. In any case, I'm adding Brett here who was seemingly the last one to touch that bit of code.

I'm also attaching a path with what I think is a more appropriate and smaller fix.

----------
keywords: +patch
nosy: +brett.cannon
stage: test needed -> patch review
Added file: http://bugs.python.org/file42222/issue26587.diff

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue26587>
_______________________________________


More information about the Python-bugs-list mailing list