Note: This is a beta release of Red Hat Bugzilla 5.0. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Also email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback here.

Bug 159638

Summary: rpmtsCheck() returns 0 (No Problems) when dependencies don't match
Product: Red Hat Enterprise Linux 3 Reporter: James Olin Oden <james.oden>
Component: rpmAssignee: Panu Matilainen <pmatilai>
Status: CLOSED WONTFIX QA Contact: Mike McLean <mikem>
Severity: medium Docs Contact:
Priority: medium    
Version: 3.0   
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2007-10-11 10:51:57 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description James Olin Oden 2005-06-06 13:48:23 UTC
Description of problem:
In rpmts.h, rpmtsCheck() has the following doxygen:

    * Check that all dependencies can be resolved.
    * @param ts        transaction set
    * @return      0 on success
   int rpmtsCheck(rpmts ts)

The part germain to this discussion is that it should return 0 on success and 
I assume non-zero on failure.   When I run rpmtsCheck on a transaction with 
missing dependencies, though I get a problem set returned (via the transaction)
rpmtsCheck() always returns 0.

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
1.  Create some packages with unmet dependencies.
2.  Either write enough code to create the transaction and run rpmtsCheck()
    or add some debug code to rpm that printes the return value of rpmtsCheck().
3.  Now this transaction through your program or the patched rpm.
Actual results:
rpmtsCheck() == 0

Expected results:
rpmtsCheck != 0

Additional info:
I realize this may not be a bug if you mean by success that it actually could 
check dependencies.  If some clarification needs to be done to the doxygen.

Comment 1 Jeff Johnson 2006-04-04 12:03:45 UTC
rpmtsCheck() returns 0 meaning that resolution was successfully
attempted for all dependencies. The result you want, that no dependencies
were unmatched, is in the problem set that is computed by rpmtsCheck().

Comment 2 Panu Matilainen 2007-10-11 10:51:57 UTC
rpmtsCheck() documentation clarified in upstream, but WONTFIX for RHEL3.