Bug 927496
Summary: | repoquery downloads metadata even if --offline is provided in command line | ||
---|---|---|---|
Product: | [Fedora] Fedora | Reporter: | Ankur Sinha (FranciscoD) <sanjay.ankur> |
Component: | mock | Assignee: | Clark Williams <williams> |
Status: | CLOSED CURRENTRELEASE | QA Contact: | Fedora Extras Quality Assurance <extras-qa> |
Severity: | high | Docs Contact: | |
Priority: | unspecified | ||
Version: | 20 | CC: | bochecha, mebrown, williams |
Target Milestone: | --- | ||
Target Release: | --- | ||
Hardware: | All | ||
OS: | Linux | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | Bug Fix | |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2014-02-21 15:40:48 UTC | Type: | Bug |
Regression: | --- | Mount Type: | --- |
Documentation: | --- | CRM: | |
Verified Versions: | Category: | --- | |
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
Cloudforms Team: | --- | Target Upstream Version: | |
Embargoed: |
Description
Ankur Sinha (FranciscoD)
2013-03-26 04:51:59 UTC
[ankur@dhcppc1 temp_repo]$ rpm -q mock mock-1.1.29-1.fc18.noarch Also, is a list of all available packages really needed for normal running? Is it for debugging purposes? Can a switch be provided to turn this on/off? Thanks, Ankur (In reply to comment #2) > Also, is a list of all available packages really needed for normal running? > Is it for debugging purposes? Can a switch be provided to turn this on/off? > > Thanks, > Ankur It's part of the package_state plugin, which is used to verify the environment in which a package is built. You can disable it with --disable-plugin=package_state Regardless, the plugin shouldn't run repoquery when --offline is specified. Here's something I'm testing now, which should turn off the package_state callbacks when --offline is specified: diff --git a/py/mockbuild/plugins/package_state.py b/py/mockbuild/plugins/package_state.py index 59385b1..13fff31 100644 --- a/py/mockbuild/plugins/package_state.py +++ b/py/mockbuild/plugins/package_state.py @@ -36,12 +36,13 @@ class PackageState(object): self.rootObj = rootObj self.avail_done = False self.inst_done = False + self.online = rootObj.online rootObj.addHook("postyum", self._availablePostYumHook) rootObj.addHook("prebuild", self._installedPreBuildHook) decorate(traceLog()) def _availablePostYumHook(self): - if not self.avail_done: + if self.online and not self.avail_done: self.rootObj.start("Outputting list of available packages") out_file = self.rootObj.resultdir + '/available_pkgs' cmd = "/usr/bin/repoquery -c %s/etc/yum.conf %s > %s" % ( @@ -52,7 +53,7 @@ class PackageState(object): decorate(traceLog()) def _installedPreBuildHook(self): - if not self.inst_done: + if self.online and not self.inst_done: self.rootObj.start("Outputting list of installed packages") fd, fn = tempfile.mkstemp() fo = os.fdopen(fd, 'w') I'm testing now and if it doesn't break the world, I'll include it in the next release (1.1.30). This message is a reminder that Fedora 18 is nearing its end of life. Approximately 4 (four) weeks from now Fedora will stop maintaining and issuing updates for Fedora 18. It is Fedora's policy to close all bug reports from releases that are no longer maintained. At that time this bug will be closed as WONTFIX if it remains open with a Fedora 'version' of '18'. 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 prior to Fedora 18's end of life. Thank you for reporting this issue and we are sorry that we may not be able to fix it before Fedora 18 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 to Fedora 18's end of life. 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. Don't know how this got missed but it's been fixed since 1.1.30 |