Closed AyraHikari closed 6 years ago
The error here is that your database schema is outdated.
When you fetch new commits from upstream, always make sure to read the commit messages. Any changes to the database schema are referenced in the relevant commits.
Removing that line might stop this bug, but it'll break the clean welcome functionality.
I recommend you have a look at the commit messages for the commits which caused your issue: welcome fix youll also need this, its another database change
Join Support for more info on what's happening.
Also, I'd like to bring to your attention that GPL requires you to have ALL your source available and up to date. Your github repo definitely isn't, as there are NO commits from you.
Thanks bro. Now i know what to do.
Hello, i've clone your bot with some edited script (just edit language). I want to update the bot base on your script, all script is work, but this script look like has error. when i write this script, and then build the bot. Bot will error when save welcome message or load welcome message, it say :
[SQL: 'SELECT welcome_pref.chat_id AS welcome_pref_chat_id, welcome_pref.should_welcome AS welcome_pref_should_welcome, welcome_pref.should_goodbye AS welcome_pref_should_goodbye, welcome_pref.custom_welcome AS welcome_pref_custom_welcome, welcome_pref.welcome_type AS welcome_pref_welcome_type, welcome_pref.custom_leave AS welcome_pref_custom_leave, welcome_pref.leave_type AS welcome_pref_leave_type, welcome_pref.clean_welcome AS welcome_pref_clean_welcome \nFROM welcome_pref \nWHERE welcome_pref.chat_id = %(param_1)s'] [parameters: {'param_1': '-10011xxxxxxxx'}] (Background on this error at: http://sqlalche.me/e/f405)
I don't know what error, but i think database error at read or write it, when i delete that line, and build, my bot has work fine. And make new clean database fixed it, but some my group data is on old database. And same error at locks_sql.py on tgbot/tg_bot/modules/sql. Btw thanks to make perfect and open source bot 👍
https://github.com/PaulSonOfLars/tgbot/blob/275fa74a14e2c5691367a8d06db557c60b179541/tg_bot/modules/sql/welcome_sql.py#L36