def METHOD_NAME(
    stream: TextIO, cleaned: bool = True, max_line: int = MAX_LINE
) -> Optional[Any]:
    warn("read_entity() is deprecated.", DeprecationWarning, stacklevel=2)
    line = stream.readline(max_line)
    if not line:
        return None
    data = json.loads(line)
    for entity in _read_one(data, cleaned=cleaned):
        return entity
    return data