You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi
First thanks for your great work. the bot work perfect on channel content.
I try to use this bot to save restricted post on Private Group in Telegram.
bot I got below Error. Is it any solution?
Thanks a lot
https://t.me/c/0000000000/1137
Telegram says: [400 CHANNEL_INVALID] - The channel parameter is invalid (caused
by "channels.GetChannels")
Traceback (most recent call last):
File "C:\python\lib\site-packages\pyrogram\methods\advanced\resolve_peer.py",
line 62, in resolve_peer
return await self.storage.get_peer_by_id(peer_id)
File "C:\python\lib\site-packages\pyrogram\storage\sqlite_storage.py", line 14
2, in get_peer_by_id
raise KeyError(f"ID not found: {peer_id}")
KeyError: 'ID not found: -0000000000'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "C:\python\lib\site-packages\pyrogram\dispatcher.py", line 242, in handle
r_worker
await self.loop.run_in_executor(
File "C:\python\lib\concurrent\futures\thread.py", line 57, in run
result = self.fn(*self.args, **self.kwargs)
File "main.py", line 113, in save
handle_private(message,chatid,msgid)
File "main.py", line 150, in handle_private
msg: pyrogram.types.messages_and_media.message.Message = acc.get_messages(ch
atid,msgid)
File "C:\python\lib\site-packages\pyrogram\sync.py", line 78, in async_to_sync
_wrap
return asyncio.run_coroutine_threadsafe(coroutine, main_loop).result()
File "C:\python\lib\concurrent\futures_base.py", line 439, in result
return self.__get_result()
File "C:\python\lib\concurrent\futures_base.py", line 388, in __get_result
raise self._exception
File "C:\python\lib\site-packages\pyrogram\methods\messages\get_messages.py",
line 101, in get_messages
peer = await self.resolve_peer(chat_id)
File "C:\python\lib\site-packages\pyrogram\methods\advanced\resolve_peer.py",
line 111, in resolve_peer
await self.invoke(
File "C:\python\lib\site-packages\pyrogram\methods\advanced\invoke.py", line 7
9, in invoke
r = await self.session.invoke(
File "C:\python\lib\site-packages\pyrogram\session\session.py", line 389, in i
nvoke
return await self.send(query, timeout=timeout)
File "C:\python\lib\site-packages\pyrogram\session\session.py", line 357, in s
end
RPCError.raise_it(result, type(data))
File "C:\python\lib\site-packages\pyrogram\errors\rpc_error.py", line 91, in r
aise_it
raise getattr(
pyrogram.errors.exceptions.bad_request_400.ChannelInvalid: Telegram says: [400 C
HANNEL_INVALID] - The channel parameter is invalid (caused by "channels.GetChannels")
The text was updated successfully, but these errors were encountered:
Hi
First thanks for your great work. the bot work perfect on channel content.
I try to use this bot to save restricted post on Private Group in Telegram.
bot I got below Error. Is it any solution?
Thanks a lot
https://t.me/c/0000000000/1137
Telegram says: [400 CHANNEL_INVALID] - The channel parameter is invalid (caused
by "channels.GetChannels")
Traceback (most recent call last):
File "C:\python\lib\site-packages\pyrogram\methods\advanced\resolve_peer.py",
line 62, in resolve_peer
return await self.storage.get_peer_by_id(peer_id)
File "C:\python\lib\site-packages\pyrogram\storage\sqlite_storage.py", line 14
2, in get_peer_by_id
raise KeyError(f"ID not found: {peer_id}")
KeyError: 'ID not found: -0000000000'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "C:\python\lib\site-packages\pyrogram\dispatcher.py", line 242, in handle
r_worker
await self.loop.run_in_executor(
File "C:\python\lib\concurrent\futures\thread.py", line 57, in run
result = self.fn(*self.args, **self.kwargs)
File "main.py", line 113, in save
handle_private(message,chatid,msgid)
File "main.py", line 150, in handle_private
msg: pyrogram.types.messages_and_media.message.Message = acc.get_messages(ch
atid,msgid)
File "C:\python\lib\site-packages\pyrogram\sync.py", line 78, in async_to_sync
_wrap
return asyncio.run_coroutine_threadsafe(coroutine, main_loop).result()
File "C:\python\lib\concurrent\futures_base.py", line 439, in result
return self.__get_result()
File "C:\python\lib\concurrent\futures_base.py", line 388, in __get_result
raise self._exception
File "C:\python\lib\site-packages\pyrogram\methods\messages\get_messages.py",
line 101, in get_messages
peer = await self.resolve_peer(chat_id)
File "C:\python\lib\site-packages\pyrogram\methods\advanced\resolve_peer.py",
line 111, in resolve_peer
await self.invoke(
File "C:\python\lib\site-packages\pyrogram\methods\advanced\invoke.py", line 7
9, in invoke
r = await self.session.invoke(
File "C:\python\lib\site-packages\pyrogram\session\session.py", line 389, in i
nvoke
return await self.send(query, timeout=timeout)
File "C:\python\lib\site-packages\pyrogram\session\session.py", line 357, in s
end
RPCError.raise_it(result, type(data))
File "C:\python\lib\site-packages\pyrogram\errors\rpc_error.py", line 91, in r
aise_it
raise getattr(
pyrogram.errors.exceptions.bad_request_400.ChannelInvalid: Telegram says: [400 C
HANNEL_INVALID] - The channel parameter is invalid (caused by "channels.GetChannels")
The text was updated successfully, but these errors were encountered: