Bug 1208912 - mock with default dnf fails to install dependencies in rawhide
Summary: mock with default dnf fails to install dependencies in rawhide
Keywords:
Status: CLOSED DUPLICATE of bug 1211978
Alias: None
Product: Fedora
Classification: Fedora
Component: mock
Version: rawhide
Hardware: All
OS: All
low
low
Target Milestone: ---
Assignee: Clark Williams
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2015-04-03 21:20 UTC by Paulo Andrade
Modified: 2015-04-20 15:30 UTC (History)
6 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2015-04-20 15:30:20 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Paulo Andrade 2015-04-03 21:20:54 UTC
I had been using mock -o--yum for at least a month, but
now yum is just a wrapper to a script that execs dnf.

After some investigation, it works if running:

# echo "config_opts['dnf_builddep_command'] = '/usr/bin/dnf builddep'" >> /etc/mock/site-defaults.cfg

So, should either have that option for rawhide, or
internally handle it.

Test case is to simply run:

fedora-review -b <any-pending-review>

Comment 1 Michael Simacek 2015-04-07 12:06:52 UTC
(In reply to Paulo Andrade from comment #0)
> I had been using mock -o--yum for at least a month, but
> now yum is just a wrapper to a script that execs dnf.

Using mock with yum-as-wrapper-to-dnf is unfortunately not yet supported as we need to find a way to approach package manager that pretends to be something else.

> 
> After some investigation, it works if running:
> 
> # echo "config_opts['dnf_builddep_command'] = '/usr/bin/dnf builddep'" >>
> /etc/mock/site-defaults.cfg

msimacek ~/mock (master) $ git grep _builddep_command
etc/mock/site-defaults.cfg:# config_opts['yum_builddep_command'] = '/usr/bin/yum-builddep'
py/mockbuild/package_manager.py:        self.builddep_command = [config['yum_builddep_command']]
py/mockbuild/util.py:    config_opts['yum_builddep_command'] = '/usr/bin/yum-builddep'

There's no such option, yum_builddep_command option has no dnf counterpart. If this helped it was just some conincidence.

> 
> So, should either have that option for rawhide, or
> internally handle it.
> 
> Test case is to simply run:
> 
> fedora-review -b <any-pending-review>

Are you actually running rawhide or just building for rawhide? Do you have dnf-plugins-core installed on your system (not in mock)? Mock uses dnf and plugins from the system it's running on, not from the chroot target.
Can you post the versions of mock, dnf and dnf-plugins-core?

I didn't try reproducing it as yum's dependencies are broken in rawhide, therefore I cannot install mock in rawhide currently.

Comment 2 Paulo Andrade 2015-04-07 13:07:41 UTC
(In reply to Michael Simacek from comment #1)
> (In reply to Paulo Andrade from comment #0)
> > I had been using mock -o--yum for at least a month, but
> > now yum is just a wrapper to a script that execs dnf.
> 
> Using mock with yum-as-wrapper-to-dnf is unfortunately not yet supported as
> we need to find a way to approach package manager that pretends to be
> something else.

  I expect /usr/bin/yum-deprecated to work, so, for rawhide
it could be an option in the meantime.

> > After some investigation, it works if running:
> > 
> > # echo "config_opts['dnf_builddep_command'] = '/usr/bin/dnf builddep'" >>
> > /etc/mock/site-defaults.cfg
> 
> msimacek ~/mock (master) $ git grep _builddep_command
> etc/mock/site-defaults.cfg:# config_opts['yum_builddep_command'] =
> '/usr/bin/yum-builddep'
> py/mockbuild/package_manager.py:        self.builddep_command =
> [config['yum_builddep_command']]
> py/mockbuild/util.py:    config_opts['yum_builddep_command'] =
> '/usr/bin/yum-builddep'
> 
> There's no such option, yum_builddep_command option has no dnf counterpart.
> If this helped it was just some conincidence.

  I "fixed" dnf, that was not working for like 2 or more
months, with a message about builddep not found. The option
satisfy:

/usr/lib/python3.4/site-packages/mockbuild/package_manager.py:36
        if args[0] == 'builddep':
            args = args[1:]
            invocation += self.builddep_command
            common_opts = self.config[self.name + '_builddep_opts']

> > So, should either have that option for rawhide, or
> > internally handle it.
> > 
> > Test case is to simply run:
> > 
> > fedora-review -b <any-pending-review>
> 
> Are you actually running rawhide or just building for rawhide? Do you have

It is my desktop computer, I run rawhide on it for a few
years already, had some bad moments of system not booting,
no graphical interface, etc, but so far recovered every
time.

$ cat /etc/redhat-release 
Fedora release 23 (Rawhide)
$ uname -a
Linux localhost.localdomain 4.0.0-0.rc6.git0.1.fc23.x86_64 #1 SMP Mon Mar 30 13:35:06 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux

> dnf-plugins-core installed on your system (not in mock)? Mock uses dnf and
> plugins from the system it's running on, not from the chroot target.
> Can you post the versions of mock, dnf and dnf-plugins-core?

$ rpm -q mock dnf dnf-plugins-core
mock-1.2.7-1.fc23.noarch
dnf-0.6.5-1.fc23.noarch
dnf-plugins-core-0.1.6-2.fc23.noarch

> I didn't try reproducing it as yum's dependencies are broken in rawhide,
> therefore I cannot install mock in rawhide currently.

I think dnf needs a --skip-broken option, otherwise, using
rawhide may become a real nightmare. But if it is "truely"
broken, then I cannot help...

$ rpm -qa | grep yum
yum-utils-1.1.31-505.fc23.noarch
yum-metadata-parser-1.1.4-14.fc22.x86_64
yum-3.4.3-505.fc23.noarch
dnf-yum-0.6.5-1.fc23.noarch

Comment 3 Miroslav Suchý 2015-04-20 15:30:20 UTC

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


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