[Distutils] setuptools: egg traceback seems not very informative

John Machin sjmachin at lexicon.net
Tue Sep 19 07:10:02 CEST 2006


Hello all,
Example below, with distutils setup of same package under Python 2.5 for 
comparison. Two problems:
(1) Path of source file is part only of the path from the *development* 
machine and gives no clue as to where the egg is located on the runtime 
machine nor what Python version nor what package version -- all of which 
is in the name of the egg!!!
(2) The source line is not shown.
Can I work around this? Is this recognised as a problem? Are there plans 
to enhance any of this?
Cheers,
John

| C:\xlrdtest>python
| Python 2.4.3 (#69, Mar 29 2006, 17:35:34) [MSC v.1310 32 bit (Intel)] 
on win32
| Type "help", "copyright", "credits" or "license" for more information.
| >>> import xlrd
| >>> xlrd.__VERSION__
| '0.6.0a3'
| >>> xlrd.__file__
| 
'c:\\python24\\lib\\site-packages\\xlrd-0.6.0a3-py2.4.egg\\xlrd\\__init__.pyc'
| >>> xlrd.open_workbook('nosuchfile')
| Traceback (most recent call last):
|   File "<stdin>", line 1, in ?
|   File "build\bdist.win32\egg\xlrd\__init__.py", line 173, in 
open_workbook
|   File "build\bdist.win32\egg\xlrd\__init__.py", line 444, in __init__
| IOError: [Errno 2] No such file or directory: 'nosuchfile'
| >>> ^Z
|
|
| C:\xlrdtest>\python25\python
| Python 2.5c2 (r25c2:51859, Sep 12 2006, 09:33:52) [MSC v.1310 32 bit 
(Intel)] on
|  win32
| Type "help", "copyright", "credits" or "license" for more information.
| >>> import xlrd
| >>> xlrd.__VERSION__
| '0.6.0a3'
| >>> xlrd.__file__
| 'C:\\python25\\lib\\site-packages\\xlrd\\__init__.pyc'
| >>> xlrd.open_workbook('nosuchfile')
| Traceback (most recent call last):
|   File "<stdin>", line 1, in <module>
|   File "C:\Python25\Lib\site-packages\xlrd\__init__.py", line 173, in 
open_workb
| ook
|     encoding_override=encoding_override,
|   File "C:\Python25\Lib\site-packages\xlrd\__init__.py", line 444, in 
__init__
|     f = open(filename, open_mode)
| IOError: [Errno 2] No such file or directory: 'nosuchfile'
| >>>
|


More information about the Distutils-SIG mailing list