[Rpm-maint] rpm-python rpm.ts question
Mike Brady
mike.brady at devnull.net.nz
Tue Feb 27 22:29:16 UTC 2007
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
When doing package dependency checks in rpm-python I have the following
function.
def verifyDependencies(ts, header):
"""
Check package dependencies. Header is an rpm.hdr.
"""
ts.addInstall(header, 'Dep Check', 'u')
dep_errors = ts.check()
return dep_errors
The ts is shared, so the same one is being used every time this function
is being called. Which means that the ts just keeps getting more
elements added.
In the C code a rpmtsEmpty() is called before doing the addInstall(). I
assume that this clears out the ts. How do I do the same thing in
rpm-python? I tied ts.clean(), but that didn't do it.
Regards
Mike
- --
Mike Brady
GPG Key ID: 0x9C777DA4
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
iD8DBQFF5LC86xLAi5x3faQRApGgAJ99YhOE3UTh+lOZYkN37NRhdfiAjgCfeEdh
ZmDM5zxo5pLY8z3GIqXRjoM=
=rvxb
-----END PGP SIGNATURE-----
More information about the Rpm-maint
mailing list