Skip to content

Commit

Permalink
Request filelists metadata for plugins needing that
Browse files Browse the repository at this point in the history
Prepare for switching to not loading filelists metadata by default. Explicitly request the metadata by plugins that need them.
  • Loading branch information
jan-kolarik authored and kontura committed Feb 8, 2024
1 parent 620fccc commit baf02cc
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 0 deletions.
3 changes: 3 additions & 0 deletions plugins/download.py
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,9 @@ def configure(self):
else:
self.base.conf.destdir = dnf.i18n.ucd(os.getcwd())

if dnf.util._is_file_pattern_present(self.opts.packages):
self.base.conf.optional_metadata_types += ["filelists"]

def run(self):
"""Execute the util action here."""

Expand Down
1 change: 1 addition & 0 deletions plugins/needs_restarting.py
Original file line number Diff line number Diff line change
Expand Up @@ -268,6 +268,7 @@ def set_argparser(parser):
def configure(self):
demands = self.cli.demands
demands.sack_activation = True
self.base.conf.optional_metadata_types += ["filelists"]

def run(self):
process_start = ProcessStart()
Expand Down
1 change: 1 addition & 0 deletions plugins/repoclosure.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ def configure(self):
demands = self.cli.demands
demands.sack_activation = True
demands.available_repos = True
self.base.conf.optional_metadata_types += ["filelists"]
if self.opts.repo:
for repo in self.base.repos.all():
if repo.id not in self.opts.repo and repo.id not in self.opts.check:
Expand Down

0 comments on commit baf02cc

Please sign in to comment.