[Python-bugs-list] [ python-Bugs-418369 ] Typo in distutils (1.5 and 2.1)

noreply@sourceforge.net noreply@sourceforge.net
Fri, 04 May 2001 07:41:01 -0700


Bugs item #418369, was updated on 2001-04-23 14:08
You can respond by visiting: 
http://sourceforge.net/tracker/?func=detail&atid=105470&aid=418369&group_id=5470

Category: Distutils
Group: None
Status: Open
Resolution: None
Priority: 5
Submitted By: Nobody/Anonymous (nobody)
Assigned to: A.M. Kuchling (akuchling)
Summary: Typo in distutils (1.5 and 2.1)

Initial Comment:
If README or README.txt are not specified in
doc_files, then bdist_rpm attempts to locate them. If
they exist, bdist_rpm adds them, erroneously, to
self.doc, instead of (correctly) to self.doc_files

self.doc does not exists, which then throws an
AttributeError

The offending code in Python 1.5 Distutils is
at or around line 192 of bdist_rpm.py

In Python 2.1 it is also at line 192 of bdist_rpm.py

Thanks!



----------------------------------------------------------------------

Comment By: Jon Nelson (jnelson)
Date: 2001-05-04 07:41

Message:
Logged In: YES 
user_id=8446

Here is a patch:

diff -u -r
Distutils-1.0.1.orig/distutils/command/bdist_rpm.py
Distutils-1.0.1/d
istutils/command/bdist_rpm.py
--- Distutils-1.0.1.orig/distutils/command/bdist_rpm.py Fri
May  4 09:25:32 2001
+++ Distutils-1.0.1/distutils/command/bdist_rpm.py      Fri
May  4 09:26:12 2001
@@ -189,7 +189,7 @@
         if type(self.doc_files) is ListType:
             for readme in ('README', 'README.txt'):
                 if os.path.exists(readme) and readme not in
self.doc_files:
-                    self.doc.append(readme)
+                    self.doc_files.append(readme)
 
         self.ensure_string('release', "1")
         self.ensure_string('serial')   # should it be an
int?


----------------------------------------------------------------------

You can respond by visiting: 
http://sourceforge.net/tracker/?func=detail&atid=105470&aid=418369&group_id=5470