Bug 1666648 - dnf download command downloads also a srpm
Summary: dnf download command downloads also a srpm
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: dnf-plugins-core
Version: rawhide
Hardware: Unspecified
OS: Unspecified
low
low
Target Milestone: ---
Assignee: Jaroslav Mracek
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2019-01-16 09:48 UTC by Daniel Mach
Modified: 2019-02-21 02:56 UTC (History)
6 users (show)

Fixed In Version: dnf-plugins-core-4.0.4-1.fc29
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2019-02-21 02:56:59 UTC


Attachments (Terms of Use)

Description Daniel Mach 2019-01-16 09:48:37 UTC
Reproducer:
$ dnf download --enablerepo=fedora-source filesystem
(1/2): filesystem-3.9-2.fc29.src.rpm
(2/2): filesystem-3.9-2.fc29.x86_64.rpm

Expected behavior:
filesystem-3.9-2.fc29.src.rpm is not downloaded

Additional info:
Downloading sources works as expected:
$ dnf download --enablerepo=fedora-source filesystem --source
filesystem-3.9-2.fc29.src.rpm
# no binary is dowloaded

Comment 1 Daniel Mach 2019-01-16 10:47:28 UTC
Maybe the behavior is correct, but the help is misleading:
  --source              download the src.rpm instead
  --debuginfo           download the -debuginfo package instead

If I understand it correctly, the provided packages on the command line are names of binary RPMs.
When --source is provided, **corresponding** src.rpm is downloaded (e.g. dnf download --source nss -> downloads glibc.src.rpm)
When --debuginfo is provided, **corresponding** debuginfo is downloaded (e.g. dnf download --debuginfo nss -> downloads glibc-debuginfo.*.rpm)
Please note debugsource is NOT downloaded.

Comment 2 Jaroslav Mracek 2019-01-16 13:39:00 UTC
The behavior of DNF differs to you. Yum did not downloaded src by default.

Comment 3 Jaroslav Mracek 2019-01-16 16:07:23 UTC
I created a patch (https://github.com/rpm-software-management/dnf-plugins-core/pull/319) that solves the issue. Please can you verify it?

Comment 4 Fedora Update System 2019-02-18 10:15:27 UTC
libcomps-0.1.10-2.fc29 libdnf-0.26.0-1.fc29 dnf-plugins-core-4.0.4-1.fc29 dnf-plugins-extras-4.0.2-1.fc29 dnf-4.1.0-1.fc29 librepo-1.9.4-1.fc29 createrepo_c-0.12.1-1.fc29 has been submitted as an update to Fedora 29. https://bodhi.fedoraproject.org/updates/FEDORA-2019-1fccede810

Comment 5 Fedora Update System 2019-02-19 06:27:26 UTC
createrepo_c-0.12.1-1.fc29, dnf-4.1.0-1.fc29, dnf-plugins-core-4.0.4-1.fc29, dnf-plugins-extras-4.0.2-1.fc29, libcomps-0.1.10-2.fc29, libdnf-0.26.0-1.fc29, librepo-1.9.4-1.fc29 has been pushed to the Fedora 29 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2019-1fccede810

Comment 6 Fedora Update System 2019-02-21 02:56:59 UTC
createrepo_c-0.12.1-1.fc29, dnf-4.1.0-1.fc29, dnf-plugins-core-4.0.4-1.fc29, dnf-plugins-extras-4.0.2-1.fc29, libcomps-0.1.10-2.fc29, libdnf-0.26.0-1.fc29, librepo-1.9.4-1.fc29 has been pushed to the Fedora 29 stable repository. If problems still persist, please make note of it in this bug report.


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