Bug 612403

Summary: TypeError importing daemon.pidlockfile after updating to python-lockfile-0.9
Product: [Fedora] Fedora Reporter: Sandro Bonazzola <sandro.bonazzola>
Component: python-daemonAssignee: kushaldas <mail>
Status: CLOSED NEXTRELEASE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: low    
Version: 13CC: mail, silas, tomspur
Target Milestone: ---Keywords: Reopened
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2011-07-24 19:54:01 EDT Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Description Sandro Bonazzola 2010-07-08 02:46:35 EDT
Description of problem:
TypeError: Error when calling the metaclass bases
    function() argument 1 must be code, not str


Version-Release number of selected component (if applicable):
$ rpm -q python-lockfile python-daemon
python-lockfile-0.9-1.fc13.noarch
python-daemon-1.5.2-1.fc13.noarch


How reproducible:
Always reproducible

Steps to Reproduce:
Open a python shell

import daemon.pidlockfile

TypeError: Error when calling the metaclass bases
    function() argument 1 must be code, not str

/usr/lib/python2.6/site-packages/daemon/pidlockfile.py in <module>()
     31 
     32 
---> 33 class PIDLockFile(LinkFileLock, object):
     34     """ Lockfile implemented as a Unix PID file.
     35 
  
Actual results:

TypeError: Error when calling the metaclass bases
    function() argument 1 must be code, not str

Expected results:
daemon.pidlockfile uses the new API of python-lockfile
Comment 1 Thomas Spura 2010-07-08 04:07:38 EDT
Thanks for testing python-lockfile :)

This also happens with the latest release by upstream, so I just mailed him, to update python-daemon to the new api.

I'll make a note in the update of python-lockfile, so this won't be pushed to stable (hopefully)...

https://admin.fedoraproject.org/updates/python-lockfile-0.9-1.fc13
Comment 2 Silas Sewell 2010-07-08 12:34:07 EDT
I won't push the update until this ticket is resolved.

I've also filed a ticket upstream in regards to the lockfile version.

http://code.google.com/p/pylockfile/issues/detail?id=4
Comment 3 Silas Sewell 2010-12-29 23:54:08 EST
We revoked version 0.9.1, feel free to reopen if something else needs to be fixed.
Comment 4 kushaldas@gmail.com 2011-07-15 02:59:54 EDT
I just did a rebuild of 0.9.1 and tested the latest python-daemon 1.6 with it as mentioned in 716183. The import worked well.

Can we rebuild and push 0.9.1 ?
Comment 5 Thomas Spura 2011-07-17 07:11:18 EDT
All tests of python-daemon 1.6 pass again with lockfile-0.9.1, so I think, it's ok to update it.
Comment 6 Silas Sewell 2011-07-24 19:54:01 EDT
Updated lockfile to 0.9.1 in devel.

http://koji.fedoraproject.org/koji/buildinfo?buildID=255279