kramcat/CharacterAI

How to deal with TimeoutError when calling client.connect()

Opened this issue · 0 comments

I got TimeoutError when I call client.connect()....

    client = aiocai.Client(TOKEN)
    me = await client.get_me()
    async with await client.connect() as chat:
        new, answer = await chat.new_chat(
            char, me.id
        )

        print(f'{answer.name}: {answer.text}')

        while True:
            text = input('YOU: ')

            message = await chat.send_message(
                char, new.chat_id, text
            )

            print(f'{message.name}: {message.text}')

How to deal with this issue..