"""Simplified hosts for pysyte"""

import getpass
import socket
from dataclasses import dataclass


@dataclass
class Host:
    hostname: str
    aliases: list
    addresses: list
    users: list


localhost = Host(
    *(list(socket.gethostbyname_ex(socket.gethostname())) + [getpass.getuser()])
)

"""Simplified hosts for pysyte"""

import getpass
import socket
from dataclasses import dataclass
from typing import List


@dataclass
class Host:
    hostname: str
    aliases: List[str]
    addresses: List[str]
    users: List[str]


def _read_localhost() -> Host:
    """Read host values for localhost"""
    host, aliases, addresses = socket.gethostbyname_ex(socket.gethostname())
    user = getpass.getuser()
    return Host(host, aliases, addresses, [user])

localhost = _read_localhost()

Add method to clarify localhost data
Add method to clarify localhost data
