Bug 1476215 - repoquery --location sometimes prints invalid URL
repoquery --location sometimes prints invalid URL
Status: CLOSED ERRATA
Product: Fedora
Classification: Fedora
Component: dnf (Show other bugs)
26
Unspecified Unspecified
unspecified Severity low
: ---
: ---
Assigned To: Jaroslav Mracek
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2017-07-28 06:16 EDT by Ian Collier
Modified: 2017-08-09 11:59 EDT (History)
6 users (show)

See Also:
Fixed In Version: dnf-2.6.3-1.fc26
Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2017-08-09 11:59:32 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Ian Collier 2017-07-28 06:16:05 EDT
If the baseurl of a repository lacks a trailing slash in the repo file,
"dnf repoquery --location" and "dnf download --url" print a URL that is
missing a slash and therefore doesn't work:

$ cat /etc/yum.repos.d/google-chrome.repo
[google-chrome]
name=google-chrome
baseurl=http://dl.google.com/linux/chrome/rpm/stable/x86_64
enabled=1
gpgcheck=1
$ dnf repoquery --location google-chrome-stable
Last metadata expiration check: 0:31:32 ago on Fri Jul 28 10:20:51 2017.
http://dl.google.com/linux/chrome/rpm/stable/x86_64google-chrome-stable-60.0.3112.78-1.x86_64.rpm

But dnf has no problem in installing from this repo, and "dnf download" has
no problem in downloading the package.  Moreover, "yumdownloader --url" also
prints the correct URL.  So the trailing slash does not seem to be mandatory
(and is not documented as being so).
Comment 1 Jaroslav Mracek 2017-08-01 12:56:26 EDT
I created a patch that should fix the issue (https://github.com/rpm-software-management/dnf/pull/879).
Comment 2 Fedora Update System 2017-08-07 08:50:00 EDT
dnf-2.6.3-1.fc26 dnf-plugins-extras-2.0.2-1.fc26 has been submitted as an update to Fedora 26. https://bodhi.fedoraproject.org/updates/FEDORA-2017-4813633f96
Comment 3 Fedora Update System 2017-08-07 21:24:09 EDT
dnf-2.6.3-1.fc26, dnf-plugins-extras-2.0.2-1.fc26 has been pushed to the Fedora 26 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-2017-4813633f96
Comment 4 Fedora Update System 2017-08-09 11:59:32 EDT
dnf-2.6.3-1.fc26, dnf-plugins-extras-2.0.2-1.fc26 has been pushed to the Fedora 26 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.