Issue #4375
closedRecursive copy doesn't solve rich dependencies correctly
Description
There are recursive and recursive_conservative flags which can be specified during copy.
When recursive_conservative flag is set to True, rich and weak dependencies are resolved properly.
When recursive flag is set to True, rich dependencies are NOT resolved properly, weak dependencies are resolved properly.
From the Cobbler
package from the fixtures repo:
<rpm:requires>
<rpm:entry name="(Scotch = 8-10 and contireau = 2-10 and tablespoon-sugar = 1-0)"/>
<rpm:entry name="icecubes"/>
</rpm:requires>
<rpm:recommends>
<rpm:entry name="(orange-bits if fruity)"/>
</rpm:recommends>
From the dependencies above it's clear that due to and
operator all the packages are required, but only Scotch
is copied and not contireau
and tablespoon-sugar
.
pulp-admin rpm repo create --repo-id foo --feed https://repos.fedorapeople.org/pulp/pulp/fixtures/rpm-richnweak-deps/
pulp-admin rpm repo sync run --repo-id foo
pulp-admin rpm repo create --repo-id bar
pulp-admin rpm repo copy rpm --from-repo-id foo --to-repo-id bar --str-eq name=Cobbler --recursive
This command may be exited via ctrl+c without affecting the request.
[\]
Running...
Copied:
Cobbler-1-0-noarch
Scotch-8-10-noarch
icecubes-2-3-noarch
orange-bits-2-3-noarch
Related issues
Updated by CodeHeeler almost 6 years ago
- Triaged changed from No to Yes
- Sprint set to Sprint 48
Updated by dalley almost 6 years ago
- Status changed from NEW to ASSIGNED
- Assignee set to dalley
Updated by dalley almost 6 years ago
- Status changed from ASSIGNED to POST
PR: https://github.com/pulp/pulp_rpm/pull/1261
(pulp) [vagrant@pulp2 devel]$ pulp-admin rpm repo copy rpm --from-repo-id deptest --to-repo-id empty2 --str-eq name=Cobbler --recursive
This command may be exited via ctrl+c without affecting the request.
[\]
Running...
Copied:
Cobbler-1-0-noarch
Scotch-8-10-noarch
contireau-2-10-noarch
icecubes-2-3-noarch
orange-bits-2-3-noarch
tablespoon-sugar-1-0-noarch
Added by dalley almost 6 years ago
Added by dalley almost 6 years ago
Revision 6b0bc828 | View on GitHub
Fix: Recursive copy doesn't solve rich dependencies
Updated by kersom almost 6 years ago
- Related to Task #4371: Document how to use the newly added recursive_conservative added
Updated by kersom almost 6 years ago
With the new build 2.18.1b1 that includes this patch. Copying chimpanzee from repo A to repo B, using recursive flag, is copying all its dependencies, even older ones such as: walrus-0.71-1-noarch
pulp-admin login -u admin -p admin
pulp-admin rpm repo create --repo-id zoo --feed https://repos.fedorapeople.org/pulp/pulp/fixtures/rpm-unsigned/
pulp-admin rpm repo sync run --repo-id zoo
pulp-admin rpm repo create --repo-id new
pulp-admin rpm repo copy rpm --from-repo-id zoo --to-repo-id new --str-eq name=chimpanzee --recursive
[root@localhost ~]# pulp-admin rpm repo copy rpm --from-repo-id zoo --to-repo-id new --str-eq name=chimpanzee --recursive
This command may be exited via ctrl+c without affecting the request.
[\]
Running...
Copied:
camel-0.1-1-noarch
chimpanzee-0.21-1-noarch
fox-1.1-2-noarch
shark-0.1-1-noarch
squirrel-0.1-1-noarch
stork-0.12-2-noarch
walrus-0.71-1-noarch
walrus-5.21-1-noarch
whale-0.2-1-noarc
2 tests are failing due to this.
rpm.cli.test_copy_units.CopyRecursiveTestCase.test
rpm.api_v2.test_copy.CopyConservativeTestCase.test
What is the expected behaviour here?
Updated by bherring almost 6 years ago
- Related to Test #4359: 2.18.1 Testing added
Updated by dalley almost 6 years ago
- Status changed from MODIFIED to POST
Added by dalley almost 6 years ago
Revision ec99ffa6 | View on GitHub
Fix recursive copy for rich deps, take 3
Added by dalley almost 6 years ago
Revision 1334b4cf | View on GitHub
Fix recursive copy for rich deps, take 3
Updated by dalley almost 6 years ago
Applied in changeset 226423b3c7f30f3d7ea2c59840fe90039ec8e439.
Updated by dalley almost 6 years ago
Applied in changeset 6b0bc8284b2b6d65d7511ede248c3653d005e1b2.
Updated by dalley almost 6 years ago
Applied in changeset ec99ffa621dfa493fa4ae917473b24a0ecdcc698.
Updated by dalley almost 6 years ago
Applied in changeset 1334b4cf693296139f2a0d4877aa639f5f10600e.
Updated by jortel@redhat.com almost 6 years ago
- Status changed from MODIFIED to 5
Updated by jortel@redhat.com almost 6 years ago
- Status changed from 5 to CLOSED - CURRENTRELEASE
Fix: Recursive copy doesn't solve rich dependencies
closes: #4375 https://pulp.plan.io/issues/4375