|Summary:||Incorrect parsing of "--setopt" with repositories with dots|
|Product:||Red Hat Enterprise Linux 7||Reporter:||Brian J. Murrell <brian>|
|Component:||yum-utils||Assignee:||Packaging Maintenance Team <packaging-team-maint>|
|Status:||CLOSED NOTABUG||QA Contact:||BaseOS QE Security Team <qe-baseos-security>|
|Version:||7.6||CC:||emrakova, james.antill, jblazek, jrohel, kwalker, mdomonko, packaging-team-maint, wchadwic|
|Fixed In Version:||Doc Type:||If docs needed, set a value|
|Doc Text:||Story Points:||---|
|Last Closed:||2019-09-24 11:51:44 UTC||Type:||---|
|oVirt Team:||---||RHEL 7.3 requirements from Atomic Host:|
|Cloudforms Team:||---||Target Upstream Version:|
Description Brian J. Murrell 2019-09-18 16:10:14 UTC
I think this needs a backport for EL7 as setting options for repos added with yum-config-manager by url don't work, presumably because they have dots in the fqdn portion of the url they were created from. +++ This bug was initially created as a clone of Bug #1746349 +++ Description of problem: The "--setopt" have a problem with repositories with dots in id. The option parser uses first dot as a delimiter. Repository id may contain dots but option name can't. -> So, the last dot is delimiter and not the first one. Example: "--setopt=re.po.option=value " is parsed as repo id "re" and option "po.option". Correct result is repo id "re.po" and option "option". --- Additional comment from Jaroslav Rohel on 2019-08-28 09:09:24 UTC --- I made fix in upstream PR https://github.com/rpm-software-management/dnf/pull/1466 . --- Additional comment from Jaroslav Rohel on 2019-08-28 09:11:53 UTC --- The bug was catch during testing config-repo plugin https://bugzilla.redhat.com/show_bug.cgi?id=1702678 .
Comment 2 Eva Mrakova 2019-09-19 08:51:20 UTC
(In reply to Brian J. Murrell from comment #0) > I think this needs a backport for EL7 as setting options for repos added > with yum-config-manager by url don't work, presumably because they have dots > in the fqdn portion of the url they were created from. Brian, it's probably a different issue than in the bug 1746349. yum-config-manager works OK with repos containing dots in their IDs/names both on rhel7.7 - yum-utils-1.1.31-52.el7 and 7.6 - yum-utils-1.1.31-50.el7 # yum-config-manager --setopt='repo.with.dots.retries=5' --save # cat /etc/yum.repos.d/repo.with.dots.repo [repo.with.dots] name=repo.with.dots baseurl=file:///tmp/testpath/repo.with.dots enabled=0 gpgcheck=0 retries = 5 keepcache = 0 Could you please provide a reproducer for your issue?
Comment 3 Michal Domonkos 2019-09-24 11:51:44 UTC
Indeed, as Eva confirmed, yum *does* already parse such repoids correctly, see: https://github.com/rpm-software-management/yum/blob/098cf29f8d0329ebbf6f215426d41808c5881960/cli.py#L214 That being said, I'm closing this one as NOTABUG.
Comment 4 Michal Domonkos 2019-09-24 11:56:30 UTC
Original Fedora bug, for reference: https://bugzilla.redhat.com/show_bug.cgi?id=1023595