Chris Caron <lead2g...@gmail.com> added the comment:

I'm not doing anything unusual.

Just to recap, I installed Python27 (in Windows 7 in my case- but this problem 
happens in Windows 10 too).

I did use `pip` to install packages as you'll see in the screenshot.  But even 
if i rename the `C:\Python27\Lib\site-packages\backports` to 
`ignoreme-backports`.  When i change the PYTHONPATH (from within 
sys.path.insert(0, 'new_path/that/has/a/backports/dir/in/it');

import backports
print backports.__path__
# always prints: C:\Python27\Lib\site-packages\backports

The problem arises because the following code won't work in my program:

from import import ssl_match_hostname

^^ That throws an exception that the package doesn't exist.  It's debugging it 
to the __path__ being incorrect that caused me to create this ticket.

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue31741>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to