Skip to content

Commit

Permalink
Merge pull request #123 from mimi1vx/poo152098
Browse files Browse the repository at this point in the history
Better message for unknown product during reset
  • Loading branch information
mimi1vx authored Dec 21, 2023
2 parents 32c3fd7 + d5382cb commit 7854c32
Show file tree
Hide file tree
Showing 8 changed files with 5 additions and 9 deletions.
2 changes: 1 addition & 1 deletion repose/__init__.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
__version__ = "1.9.0"
__version__ = "1.9.1"
1 change: 0 additions & 1 deletion repose/command/_command.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,6 @@ def _init_repoq(self):
return Repoq(self._load_template())

def _report_target(self, target):

if self.targets[target].out[-1][3] == 0:
for line in self.targets[target].out[-1][1].splitlines():
logger.info(blue("{}".format(target)) + " - {}".format(line))
Expand Down
1 change: 0 additions & 1 deletion repose/command/list.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ class ListRepos(Command):
command = True

def run(self):

self.targets.read_repos()
self.targets.report_repos(self.display.list_update_repos)
self.targets.close()
Expand Down
1 change: 0 additions & 1 deletion repose/command/uninstall.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,6 @@ def _run(self, orepa, host):
self._report_target(host)

def run(self):

self.targets.read_repos()
self.targets.parse_repos()
orepa = []
Expand Down
1 change: 0 additions & 1 deletion repose/connection.py
Original file line number Diff line number Diff line change
Expand Up @@ -345,7 +345,6 @@ def readlink(self, path):
return link

def is_active(self):

return self.client._transport and self.client._transport.is_active()

def close(self):
Expand Down
1 change: 0 additions & 1 deletion repose/display.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@ def list_products(self, hostname, port, system):
self.println()

def list_update_repos(self, hostname, port, repos):

self.println(
"{} on {}:{}".format(green("Repositories"), blue(hostname), blue(str(port)))
)
Expand Down
1 change: 0 additions & 1 deletion repose/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@


def main():

parser = get_parser()
if len(sys.argv) < 1:
parser.print_help()
Expand Down
6 changes: 4 additions & 2 deletions repose/messages.py
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,8 @@ def __init__(self, product):
self.product = product

def __str__(self):
return "Unsupported product {} version {}".format(
self.product.name, self.product.version
message = (
f"Unknow product {self.product.name} version {self.product.version}.\n"
)
message += "Please update products.yaml file with product definition"
return message

0 comments on commit 7854c32

Please sign in to comment.