Bug 581628
Summary: | createrepo -C leaves empty .repodata dir behind when nothing is done | ||||||
---|---|---|---|---|---|---|---|
Product: | [Fedora] Fedora | Reporter: | Ville Skyttä <ville.skytta> | ||||
Component: | createrepo | Assignee: | Luke Macken <lmacken> | ||||
Status: | CLOSED ERRATA | QA Contact: | Fedora Extras Quality Assurance <extras-qa> | ||||
Severity: | low | Docs Contact: | |||||
Priority: | low | ||||||
Version: | 14 | CC: | dafrito, james.antill, lmacken, paul, pfrields | ||||
Target Milestone: | --- | ||||||
Target Release: | --- | ||||||
Hardware: | All | ||||||
OS: | Linux | ||||||
Whiteboard: | |||||||
Fixed In Version: | createrepo-0.9.9-4.fc15 | Doc Type: | Bug Fix | ||||
Doc Text: | Story Points: | --- | |||||
Clone Of: | Environment: | ||||||
Last Closed: | 2011-07-28 21:05:37 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
Ville Skyttä
2010-04-12 20:18:15 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 14 development cycle. Changing version to '14'. More information and reason for this action is here: http://fedoraproject.org/wiki/BugZappers/HouseKeeping I ran into this bug today. It's minor, but it does dirty my rsync script a bit: Here's a quick demonstration: mkdir -p /tmp/dummyrepo cd /tmp/dummyrepo yumdownloader createrepo # or any other package you want createrepo . createrepo -C . [ -d .repodata ] && echo 'Temporary directory remains after createrepo exits' Looking at the source, the .repodata dir is created when createrepo.MetaDataGenerator is constructed. Ordinarily, this directory would replace the current repodata. However, the "-C" option causes createrepo to exit early, evading the replacement. As a result, the directory remains. Created attachment 490460 [details]
Remove .repodata when createrepo -C is used on a clean repository
Fixes the bug on my system. This code should probably live inside the object that created the tempdir, but I don't have the necessary expertise to know for sure.
I've applied a slightly different change upstream that handles this bug. IT is mostly just to put the cleanup code in the place where it is only handled once for cli and non-cli callers. thank you. createrepo-0.9.9-4.fc15 has been submitted as an update for Fedora 15. https://admin.fedoraproject.org/updates/createrepo-0.9.9-4.fc15 createrepo-0.9.9-4.fc15 has been pushed to the Fedora 15 stable repository. If problems still persist, please make note of it in this bug report. Now I seem to have empty "garbageid" directories left after running: createrepo --update . |