def can_access_stream_user_ids(stream: Stream) -> Set[int]:
    if stream.is_public():
        return public_stream_user_ids(stream)
    else:
        return (private_stream_user_ids(stream.id) | {user.id for user in stream.realm.get_admin_users_and_bots()})
def can_access_stream_user_ids(stream: Stream) -> Set[int]:
    if stream.is_public():
        return public_stream_user_ids(stream)
    else:
        return (private_stream_user_ids(stream.id) | {user.id for user in stream.realm.get_admin_users_and_bots()})