Open Rick21-bit opened 1 year ago
Same problem on Arch Linux
Same problem here on Arch
Same problem here. I personally don't get any errors, but the functionality still doesn't work. I use arch (maybe we are the problem? :smile: )
For me, permissions looks like this:
'permissions': {'@type': 'chatPermissions', 'can_send_basic_messages': True, 'can_send_audios': True, 'can_send_documents': True, 'can_send_photos': True, 'can_send_videos': True, 'can_send_video_notes': True, 'can_send_voice_notes': True, 'can_send_polls': True, 'can_send_other_messages': True, 'can_add_web_page_previews': True, 'can_change_info': False, 'can_invite_users': False, 'can_pin_messages': True, 'can_manage_topics': False},
There is no can_send_messages
. So I've just changed the line 489 in controllers.py from ["can_send_messages"]
to ["can_send_basic_messages"]
and it works.
Same problem on Arch and modifying controllers.py doesn't fix it for me
Same problem after update of libtd
[2023-11-26T22:56:53+0300] [ALPM] upgraded libtd (1.8.5-1 -> 1.8.16-1)
So I've just changed the line 489 in controllers.py from ["can_send_messages"] to ["can_send_basic_messages"] and it works.
it helps
changing can_send_messages to can_send_basic_messages fixed it for me
Where do I change these setting? I use tg installed from AUR on Arch. After some update I am unable to even write message (i,I,a,A all do Nothing).
Where do I change these setting? I use tg installed from AUR on Arch. After some update I am unable to even write message (i,I,a,A all do Nothing). You can check where package was installed and then change it manually in any editor or by sed
#Check where file controllers.py was installed: pacman -Ql telegram-tg | grep "controllers.py" #Check if line 489 contains what we need to change sed -n '489'p /path/to/controllers.py #Modify line 489 sed -i '489s/.*/ return chat["permissions"]["can_send_basic_messages"]/' /path/to/controllers.py
I installed tg recently on arch. It can do everything but write any type of message. 'i' or 'a' doesn't do anything
Here is the error.log ERROR [2023-09-30 14:03:41,761] controllers.py:776 - handle | Error happend in key handle loop Traceback (most recent call last): File "/usr/lib/python3.11/site-packages/tg/controllers.py", line 770, in handle res = fun(self, repeat_factor) # type: ignore ^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.11/site-packages/tg/controllers.py", line 56, in _no_repeat_factor return fun(self) ^^^^^^^^^ File "/usr/lib/python3.11/site-packages/tg/controllers.py", line 317, in write_short_msg if not self.can_send_msg() or chat_id is None: ^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.11/site-packages/tg/controllers.py", line 489, in can_send_msg return chat["permissions"]["can_send_messages"]