Bug 187119

Summary: /usr/lib/anaconda/list-harddrives gives error
Product: [Fedora] Fedora Reporter: George Henson <george>
Component: anacondaAssignee: Anaconda Maintenance Team <anaconda-maint-list>
Status: CLOSED RAWHIDE QA Contact: Mike McLean <mikem>
Severity: medium Docs Contact:
Priority: medium    
Version: 5CC: wznoinsk
Target Milestone: ---   
Target Release: ---   
Hardware: i386   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2006-03-28 16:47:20 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description George Henson 2006-03-28 16:38:10 UTC
During a kickstart install list-harddrives exits with an error. This same error
can be created when running the list-harddrives-stub from an installed system.

I am using version: anaconda-11.0.5-1

# /usr/lib/anaconda/list-harddrives-stub
Traceback (most recent call last):
  File "/usr/lib/anaconda/list-harddrives-stub", line 16, in ?
    import partedUtils
  File "/usr/lib/anaconda/partedUtils.py", line 29, in ?
    import dmraid
  File "/usr/lib/anaconda/dmraid.py", line 29, in ?
    from anaconda_log import logger, logFile
  File "/usr/lib/anaconda/anaconda_log.py", line 93, in ?
    logger = AnacondaLog()
  File "/usr/lib/anaconda/anaconda_log.py", line 50, in __init__
    autoSetLevel=False, minLevel=logging.DEBUG)
  File "/usr/lib/anaconda/anaconda_log.py", line 74, in addFileHandler
    addToLogger.addHandler(logfileHandler, autoSetLevel=autoSetLevel)
TypeError: addHandler() got an unexpected keyword argument 'autoSetLevel'

If I apply the below patch, I do not get the error:

--- @anaconda_log.py    2006-03-28 16:17:53.000000000 -0500
+++ anaconda_log.py     2006-03-28 16:39:36.000000000 -0500
@@ -71,7 +71,7 @@

         logfileHandler.setLevel(minLevel)
         logfileHandler.setFormatter (logging.Formatter (fmtStr, "%H:%M:%S"))
-        addToLogger.addHandler(logfileHandler, autoSetLevel=autoSetLevel)
+        addToLogger.addHandler(logfileHandler)

     # Add another logger to the hierarchy.  For best results, make sure
     # name falls under anaconda in the tree.

Comment 1 Chris Lumens 2006-03-28 16:47:20 UTC
That'll break log levels in anaconda.  What I really want to do is import
anaconda_log early on in several of these stubs.  Fixed in Rawhide.

Comment 2 Waldemar Znoinski 2020-08-21 15:06:51 UTC
*** Bug 1871195 has been marked as a duplicate of this bug. ***