New submission from Marius Gedminas:

Steps to reproduce:

$ python -c 'from distutils.util import grok_environment_error as e; 
print(e(IOError("message")))'

What I expect to see:
error: message

What I get instead:
error: None

This is a problem because it hides the error message in a real-life use case: 
trying to use the latest setuptools in an ancient virtualenv (see [1]).  TL;DR 
version:
- sysconfig (in the standard library) raises IOError(msg),
- which is then caught and passed 
throughdistutils.util.grok_environment_error(),
- which then returns an unfriendly 'error: None'.

[1] 
https://bitbucket.org/pypa/setuptools/issue/89/easy_install-quits-with-error-none-in

----------
assignee: eric.araujo
components: Distutils
messages: 200785
nosy: eric.araujo, mgedmin, tarek
priority: normal
severity: normal
status: open
title: distutils.util.grok_environment_error loses the error message
type: behavior
versions: Python 2.7, Python 3.3

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

Reply via email to