I running tg bot in docker image and got exception in log while sending command to the bot:
2024-01-10 13:02:20,514 - pyrogram.dispatcher - ERROR - Value 6XXXXXXXXX of attr Support.id is greater than the maximum allowed value 2147483647
Traceback (most recent call last):
File "/usr/local/lib/python3.11/site-packages/pyrogram/dispatcher.py", line 240, in handler_worker
await handler.callback(self.client, *args)
File "/app/src/bot/plugins/on_message.py", line 19, in on_text
action = db_management.read_support(message.from_user.id)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/app/src/db_management.py", line 25, in read_support
return Support[chat_id].Action
~~~~~~~^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/pony/orm/core.py", line 3991, in __getitem__
return entity._find_one_(kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/pony/orm/core.py", line 4105, in _find_one_
avdict[attr] = attr.validate(val, None, entity, from_db=False)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/pony/orm/core.py", line 2534, in validate
val = Attribute.validate(attr, val, obj, entity, from_db)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/pony/orm/core.py", line 2205, in validate
val = converter.validate(val, obj)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/pony/orm/dbapiprovider.py", line 546, in validate
throw(ValueError, 'Value %r of attr %s is greater than the maximum allowed value %r'
File "/usr/local/lib/python3.11/site-packages/pony/utils/utils.py", line 99, in throw
raise exc
ValueError: Value 6XXXXXXXXX of attr Support.id is greater than the maximum allowed value 2147483647
class Support(db.Entity):
id = PrimaryKey(int)
Action = Required(str, 255)
class Support(db.Entity):
id = PrimaryKey(int, size=64)
Action = Required(str, 255)