From 1852592152f8879d93e66030c75f68eba3d0115a Mon Sep 17 00:00:00 2001 From: Lenka Segura Date: Jan 18 2023 11:52:47 +0000 Subject: Pass distgit_token and distgit_url to the retire function Signed-off-by: Lenka Segura --- diff --git a/fedpkg/cli.py b/fedpkg/cli.py index 5dd69b6..219fd4b 100644 --- a/fedpkg/cli.py +++ b/fedpkg/cli.py @@ -1513,15 +1513,17 @@ class fedpkgClient(cliClient): Runs the rpkg retire command after check. Check includes reading the state of Fedora release. """ + distgit_section = '{0}.distgit'.format(self.name) + distgit_token = config_get_safely(self.config, distgit_section, 'token') + distgit_url = config_get_safely(self.config, distgit_section, 'apibaseurl') # Allow retiring in epel if is_epel(self.cmd.branch_merge): - super(fedpkgClient, self).retire() + super(fedpkgClient, self).retire(distgit_url, distgit_token) else: state = get_fedora_release_state(self.config, self.name, self.cmd.branch_merge) - # Allow retiring in Rawhide and Branched until Final Freeze if state is None or state == 'pending': - super(fedpkgClient, self).retire() + super(fedpkgClient, self).retire(distgit_url, distgit_token) else: self.log.error("Fedora release (%s) is in state '%s' - retire operation " "is not allowed." % (self.cmd.branch_merge, state))