[Python] Reconnect to a view (with buttons etc.) in discord.py

Discussão em 'Python' iniciado por Stack, Março 13, 2025.

  1. Stack

    Stack Membro Participativo

    I'm handling an attendance list with my discord.py bot. It's a simple view with 2 buttons. The view needs to run for 7 days straight, so its important that my bot doesn't bug/crash.

    Is there a way to reconnect to a view (containing buttons and so on) after you stopped your bot? The reason is that my bot is doing other tasks as well and sometimes they bug out and I have to restart the bot, but this leads to the attendance lists being dead..

    bot.run(config["TOKEN"], reconnect=True)


    ^ this is working fine for disconnects or me restarting my router, but I haven't found a solution to reconnect to the views after restarting the whole bot/script.

    Any ideas?

    Continue reading...

Compartilhe esta Página