def METHOD_NAME(self, uid: int) -> dict[str, Any]:
    """
    Get group entry for gid
    """
    for e in self.group:
        if uid == e["gr_gid"]:
            return e
    raise KeyError("getgruid(): uid not found in group file: " + str(uid))