Bug 988140

Summary: [abrt] yum-utils-1.1.31-15.fc19: repos.py:172:add:DuplicateRepoError: Repository updates-testing is listed more than once in the configuration
Product: [Fedora] Fedora Reporter: Steve Tyler <stephent98>
Component: yum-utilsAssignee: Packaging Maintenance Team <packaging-team-maint>
Status: CLOSED EOL QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 19CC: admiller, jzeleny, packaging-team-maint, stephent98, tim.lauridsen
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Unspecified   
Whiteboard: abrt_hash:68c869d265edf3389265939535b9a62ef8fc0ef4
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2015-02-18 14:02:16 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
File: backtrace
none
File: core_backtrace
none
File: environ none

Description Steve Tyler 2013-07-24 20:23:01 UTC
Description of problem:


Version-Release number of selected component:
yum-utils-1.1.31-15.fc19

Additional info:
reporter:       libreport-2.1.5
cmdline:        /usr/bin/python -tt /bin/repoquery dosfstools --repofrompath=updates-testing,http://mirrors.kernel.org/fedora/updates/testing/19/x86_64/ --location --show-dupes
dso_list:       yum-3.4.3-102.fc19.noarch
executable:     /bin/repoquery
kernel:         3.9.9-302.fc19.x86_64
runlevel:       N 5
uid:            0

Truncated backtrace:
repos.py:172:add:DuplicateRepoError: Repository updates-testing is listed more than once in the configuration

Traceback (most recent call last):
  File "/bin/repoquery", line 1535, in <module>
    main(sys.argv)
  File "/bin/repoquery", line 1442, in main
    timestamp_check=False)
  File "/usr/lib/python2.7/site-packages/yum/__init__.py", line 6546, in add_enable_repo
    self.repos.add(newrepo)
  File "/usr/lib/python2.7/site-packages/yum/repos.py", line 172, in add
    raise Errors.DuplicateRepoError, 'Repository %s is listed more than once in the configuration' % (repoobj.id)
DuplicateRepoError: Repository updates-testing is listed more than once in the configuration

Local variables in innermost frame:
self: <yum.repos.RepoStorage instance at 0x2cfcdd0>
repoobj: <yum.yumRepo.YumRepository object at 0x2cfed50>

Comment 1 Steve Tyler 2013-07-24 20:23:05 UTC
Created attachment 777984 [details]
File: backtrace

Comment 2 Steve Tyler 2013-07-24 20:23:08 UTC
Created attachment 777985 [details]
File: core_backtrace

Comment 3 Steve Tyler 2013-07-24 20:23:12 UTC
Created attachment 777986 [details]
File: environ

Comment 4 Steve Tyler 2013-07-24 20:30:22 UTC
$ sudo yum repolist all
Loaded plugins: langpacks, refresh-packagekit
repo id                             repo name   status
fedora/19/x86_64                    Fedora 19 - enabled: 36,253
fedora-debuginfo/19/x86_64          Fedora 19 - disabled
fedora-source/19/x86_64             Fedora 19 - disabled
updates/19/x86_64                   Fedora 19 - enabled:  9,267
updates-debuginfo/19/x86_64         Fedora 19 - disabled
updates-source/19/x86_64            Fedora 19 - disabled
updates-testing/19/x86_64           Fedora 19 - disabled
updates-testing-debuginfo/19/x86_64 Fedora 19 - disabled
updates-testing-source/19/x86_64    Fedora 19 - disabled
repolist: 45,520

Comment 6 Zdeněk Pavlas 2013-07-25 07:07:38 UTC
Not a bug, but repoquery should print just the error message, not a traceback.

Comment 7 Steve Tyler 2013-07-28 14:14:51 UTC
OK, but now the user gets an error message that is easy to overlook and a package string. AIUI, the package can never be from updates-testing because of the error, but the user may not realize that.

ISTM, that this should be a fatal error with no package string displayed.

Also, the error message would be more useful if it suggested trying a different repoid: "You could try using a different repoid."

$ sudo repoquery man-pages-de --repofrompath=updates-testing,http://mirrors.kernel.org/fedora/updates/testing/19/x86_64/
Repository updates-testing is listed more than once in the configuration
man-pages-de-0:0.5-8.fc19.noarch
$ echo $?
0

$ sudo repoquery man-pages-de --repofrompath=updates-testing,http://mirrors.kernel.org/fedora/updates/testing/19/x86_64/ --location --show-dupes
Repository updates-testing is listed more than once in the configuration
http://ftp.linux.ncsu.edu/pub/fedora/linux/releases/19/Everything/x86_64/os/Packages/m/man-pages-de-0.5-8.fc19.noarch.rpm
$ echo $?
0

There is indeed a package in updates-testing:
$ sudo repoquery man-pages-de --repoid=updates-testing
man-pages-de-0:0.5-10.fc19.noarch

Tested with:
$ rpm -q yum-utils
yum-utils-1.1.31-16.fc19.noarch

Comment 8 Steve Tyler 2013-07-28 14:34:37 UTC
This is a sentence, so it should end with a period:
"Repository updates-testing is listed more than once in the configuration"
                                                                         ^

Comment 9 Zdeněk Pavlas 2013-07-29 07:33:44 UTC
(In reply to Steve Tyler from comment #7)

> ISTM, that this should be a fatal error with no package string displayed.

Maybe.. the package string is of course not part of the error message, and comes from some other enabled repository.  Now that I think of it more, it should be a fatal error.

> Also, the error message would be more useful if it suggested trying a
> different repoid: "You could try using a different repoid."

Isn't that obvious?

> This is a sentence, so it should end with a period:
> "Repository updates-testing is listed more than once in the configuration"

Thanks, fixed.

Comment 10 Steve Tyler 2013-07-29 15:54:03 UTC
Definitely not obvious ... :-)

I thought updates-testing would be reused, since it is disabled. It was only after I *guessed* that I needed to use a different repoid, and *looked* at what was in /var/cache/yum/, that I *understood* what was going on:

$ ls -1d /var/cache/yum/x86_64/19/updates-testing*
/var/cache/yum/x86_64/19/updates-testing
/var/cache/yum/x86_64/19/updates-testing-1
/var/cache/yum/x86_64/19/updates-testing-debuginfo
/var/cache/yum/x86_64/19/updates-testing-source

For the record, I regard this syntax as hopelessly arcane, but since I now believe --repofrompath should be viewed as an advanced feature of repoquery, I won't ask for any changes ... :-)

--repofrompath=updates-testing,http://mirrors.kernel.org/fedora/updates/testing/19/x86_64/

Comment 11 Steve Tyler 2013-07-29 16:52:38 UTC
(In reply to Steve Tyler from comment #7)
...
> Also, the error message would be more useful if it suggested trying a
> different repoid: "You could try using a different repoid."
...

Maybe this would be better done by adding a sentence to the --repofrompath documentation:

"repoid must be different from any other repoid in the configuration, whether enabled or disabled."

If the word "unique" could be included, somehow, that might be even better ... :-)

Comment 12 Fedora End Of Life 2015-01-09 22:13:26 UTC
This message is a notice that Fedora 19 is now at end of life. Fedora 
has stopped maintaining and issuing updates for Fedora 19. It is 
Fedora's policy to close all bug reports from releases that are no 
longer maintained. Approximately 4 (four) weeks from now this bug will
be closed as EOL if it remains open with a Fedora 'version' of '19'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version.

Thank you for reporting this issue and we are sorry that we were not 
able to fix it before Fedora 19 is end of life. If you would still like 
to see this bug fixed and are able to reproduce it against a later version 
of Fedora, you are encouraged  change the 'version' to a later Fedora 
version prior this bug is closed as described in the policy above.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events. Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

Comment 13 Fedora End Of Life 2015-02-18 14:02:16 UTC
Fedora 19 changed to end-of-life (EOL) status on 2015-01-06. Fedora 19 is
no longer maintained, which means that it will not receive any further
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of
Fedora please feel free to reopen this bug against that version. If you
are unable to reopen this bug, please file a new report against the
current release. If you experience problems, please add a comment to this
bug.

Thank you for reporting this bug and we are sorry it could not be fixed.