Skip to content

Commit

Permalink
style checks
Browse files Browse the repository at this point in the history
  • Loading branch information
eyalkaspi-delphix committed Nov 5, 2024
1 parent 0835970 commit 5ccc328
Showing 1 changed file with 6 additions and 7 deletions.
13 changes: 6 additions & 7 deletions files/common/usr/bin/delphix-startup-screen
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/usr/bin/python3
#
# Copyright 2020 Delphix
# Copyright 2020, 2024 Delphix
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -131,7 +131,7 @@ def load_header(stdscr) -> Any:
stdout=subprocess.PIPE,
universal_newlines=True,
check=True)
version = cp.stdout
version: str = cp.stdout
if not version:
# Use the packaged app version when available
# fallback to the appliance version
Expand All @@ -140,7 +140,7 @@ def load_header(stdscr) -> Any:
stdout=subprocess.PIPE,
universal_newlines=True,
check=True)
version: str = cp.stdout
version = cp.stdout

stdscr.clear()
stdscr.addstr(1, 2, LOGO + str(version), curses.A_BOLD)
Expand Down Expand Up @@ -228,17 +228,16 @@ def get_network_status() -> Tuple[str, str]:

ipaddrs = []
for interface in interfaces():
if (interface == "lo" or
interface == "docker0" or
interface.startswith("br-")):
if (interface == "lo" or interface == "docker0" or
interface.startswith("br-")):
continue
for link in ifaddresses(interface).get(AF_INET, []):
ipaddrs.append(link['addr'])
hostname = os.uname()[1]
return (hostname, ", ".join(ipaddrs))


# pylint: disable-msg=too-many-locals
# pylint: disable-msg=too-many-locals, too-many-statements
def display_status(stdscr, win):
"""
Main display and input function. This function will display
Expand Down

0 comments on commit 5ccc328

Please sign in to comment.