def METHOD_NAME(self):
    try:
        connections = psutil.net_connections()
    # You need to be root for OSX
    except psutil.AccessDenied:
        connections = None
    try:
        addrs = ["* {}: {}".format(key, val) for key, val in psutil.net_if_addrs().items()]
    except UnicodeDecodeError:
        addrs = ["INVALID ADDR WITH UNICODE CHARACTERS"]
    data = """Version: {version}