Bug 1394294 - DNF cannot download packages from Copr
Summary: DNF cannot download packages from Copr
Keywords:
Status: CLOSED DUPLICATE of bug 1257965
Alias: None
Product: Fedora
Classification: Fedora
Component: dnf
Version: 24
Hardware: Unspecified
OS: Unspecified
high
unspecified
Target Milestone: ---
Assignee: rpm-software-management
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-11-11 15:21 UTC by Michael Simacek
Modified: 2016-11-24 10:15 UTC (History)
8 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2016-11-24 10:15:04 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Michael Simacek 2016-11-11 15:21:08 UTC
Description of problem:
Copr build tries to use packages from builds that were already done within that copr project, even though I have createrepo disabled and I never run it, so it shouldn't see the packages at all. At least that's my understanding of the errors I'm observing.

All of the builds (except the first ones in given copr) fail with:
DEBUG util.py:421:  Running transaction check
DEBUG util.py:421:  [Errno 2] No such file or directory: 'http://copr-be-dev.cloud.fedoraproject.org/results/msimacek/koschei-1/custom-1-x86_64/00272111-jetty/jetty-start-9.4.0-0.2.M0.fc26.noarch.rpm'

Observed on copr-dev, using custom-1 chroot

Comment 1 clime 2016-11-11 17:47:14 UTC
I think there are actually two problems. One is that 'disable_createrepo' functionality is confusingly named. Repodata are still generated even with this option 'on' but they are created inside 'devel' subdirectory of a chroot. The devel data, which reference the latest versions of the packages, are employed during builds (the repo is added into yum.conf by mockchain) but end users will get only older (stable) versions of the packages because their yum configs contain url of the chroot and not url of the devel directory.

The 'No such file or directory' error is likely specific to dnf. I don't want to guess now what might be the problem but this pastebin shows that yum-deprecated can install the jetty-start package without problems: http://paste.fedoraproject.org/478017/14788862/.

Comment 2 Miroslav Suchý 2016-11-14 08:33:10 UTC
(In reply to clime from comment #1)
> functionality is confusingly named. Repodata are still generated even with
> this option 'on' but they are created inside 'devel' subdirectory of a
> chroot. The devel data, which reference the latest versions of the packages,
> are employed during builds (the repo is added into yum.conf by mockchain)
> but end users will get only older (stable) versions of the packages because
> their yum configs contain url of the chroot and not url of the devel
> directory.

Right. This is intended for largge projects (like GNOME) when you need to rebuild a lot of packages, but you want to hide the rebuilds for users till all packages are rebuild (which can take days or weeks).

Comment 3 Michael Simacek 2016-11-14 08:55:06 UTC
I need to have a possibility to rebuild packages without previous builds affecting them - either by disabling this createrepo or omitting the repo from chroot configuration. What about making custom-2 chroot which doesn't point to it's own (devel) repo, but only the user supplied repos?

Comment 4 Miroslav Suchý 2016-11-14 10:59:54 UTC
So this is bug in DNF.

Reproducer:
$ dnf install --disablerepo=* --enablerepo='msimacek-koschei-1' jetty-start 
...
[Errno 2] No such file or directory: 'http://copr-be-dev.cloud.fedoraproject.org/results/msimacek/koschei-1/custom-1-x86_64/00272111-jetty/jetty-start-9.4.0-0.2.M0.fc26.noarch.rpm'

$ yum-deprecated install --disablerepo=* --enablerepo='msimacek-koschei-1' jetty-start
...
Complete!

Comment 5 Michal Luscon 2016-11-18 09:16:13 UTC
Hi guys, 

I guess this discrepancy is caused by differed metadata in yum and dnf since repo at https://copr.fedorainfracloud.org/coprs/msimacek/koschei/ currently does not contain jetty-start in its metadata. Could you please confirm it?

Comment 6 Miroslav Suchý 2016-11-18 09:27:44 UTC
Handing to Michal

Comment 7 Michael Simacek 2016-11-18 10:05:31 UTC
That's a different repo. The one with the problem is: http://copr-be-dev.cloud.fedoraproject.org/results/msimacek/koschei-1/custom-1-x86_64/devel/repodata/

It contains jetty-start and the location tag points at the correct rpm. The URL in dnf output (in the bug description) also points at the correct RPM. Since it fails with ENONENT (and not with http error) I think the problem is that it tries to open it as local file.

Comment 8 Michal Luscon 2016-11-18 10:19:53 UTC
I've just successfully installed jetty-start from koschei-1. Please provide your dnf.conf, .repo file and version of DNF.

Comment 9 Michael Simacek 2016-11-18 10:31:47 UTC
It's in copr-dev, I don't know how to get the configuration myself. Requesting copr maintainers to provide it.

Comment 10 Miroslav Suchý 2016-11-18 12:54:15 UTC
@msimacek I suppose you are using this repo file:
http://copr-fe-dev.cloud.fedoraproject.org/coprs/msimacek/koschei-1/repo/custom-1/msimacek-koschei-1-custom-1.repo

Additionally Michal is asking for your /etc/dnf/dnf.conf and version of dnf.

Comment 11 Michael Simacek 2016-11-18 13:12:14 UTC
@msuchy I reported a bug on copr - that I get copr build failures with valid copr configuration. My own dnf version and configuration is irrelevant, I'm not doing the builds, copr is. We need configuration that copr uses, which clime used to reproduce the bug with plain dnf (in comment #1).

Comment 12 clime 2016-11-23 16:12:52 UTC
This is the repo file that was used in the paste (http://paste.fedoraproject.org/478017/14788862/):

[msimacek-koschei-1]
name=Copr repo for koschei-1 owned by msimacek
baseurl=http://copr-be-dev.cloud.fedoraproject.org/results/msimacek/koschei-1/custom-1-$basearch/devel/
type=rpm-md
skip_if_unavailable=True
gpgcheck=0
gpgkey=http://copr-be-dev.cloud.fedoraproject.org/results/msimacek/koschei-1/pubkey.gpg
repo_gpgcheck=0
enabled=1
enabled_metadata=1

This my dnf.conf:
[main]
gpgcheck=1
installonly_limit=3
clean_requirements_on_remove=True
#exclude=copr-backend* copr-dist-git* copr-mocks* copr-frontend*

Dnf version:
Version     : 1.1.9
Release     : 2.fc24

Comment 13 Michal Luscon 2016-11-24 10:15:04 UTC
Thank you for info. This is a duplicate of #1257965 fixed in dnf-1.1.10-1.

*** This bug has been marked as a duplicate of bug 1257965 ***


Note You need to log in before you can comment on or make changes to this bug.