alfem/telegram-download-daemon

Could not find the input entity for PeerChannel

Closed this issue · 3 comments

Hello, I'm sure the problem is on my end I just don't know how to solve it. I researched it of course but here we are.
I replaced my details with asterisks (the number of asterisks does not represent the actual length of the string), but do let me know if I need to provide actual data.

# python telegram-download-daemon.py --api-id ****** --api-hash ****** --channel ****** --dest /***/*** --temp /***/***/***
Please enter your phone (or bot token): +******
Please enter the code you received: ******
Signed in successfully as ******
Traceback (most recent call last):
  File "telegram-download-daemon.py", line 277, in <module>
    client.loop.run_until_complete(start())
  File "/usr/local/lib/python3.6/asyncio/base_events.py", line 488, in run_until_complete
    return future.result()
  File "telegram-download-daemon.py", line 271, in start
    await sendHelloMessage(client, peerChannel)
  File "telegram-download-daemon.py", line 112, in sendHelloMessage
    entity = await client.get_entity(peerChannel)
  File "/usr/local/lib/python3.6/site-packages/telethon/client/users.py", line 292, in get_entity
    inputs.append(await self.get_input_entity(x))
  File "/usr/local/lib/python3.6/site-packages/telethon/client/users.py", line 470, in get_input_entity
    .format(peer, type(peer).__name__)
ValueError: Could not find the input entity for PeerChannel(channel_id=******) (PeerChannel). Please read https://docs.telethon.dev/en/latest/concepts/entities.html to find out more details.
[ERROR/2022-02-21 07:34:14,499]asyncio:Task was destroyed but it is pending!
task: <Task pending coro=<worker() running at telegram-download-daemon.py:228> wait_for=<Future pending cb=[<TaskWakeupMethWrapper object at 0x7f26f4006d08>()]>>
[ERROR/2022-02-21 07:34:14,499]asyncio:Task was destroyed but it is pending!
task: <Task pending coro=<worker() running at telegram-download-daemon.py:228> wait_for=<Future pending cb=[<TaskWakeupMethWrapper object at 0x7f26f4006d68>()]>>
[ERROR/2022-02-21 07:34:14,500]asyncio:Task was destroyed but it is pending!
task: <Task pending coro=<worker() running at telegram-download-daemon.py:228> wait_for=<Future pending cb=[<TaskWakeupMethWrapper object at 0x7f26f4006dc8>()]>>
[ERROR/2022-02-21 07:34:14,500]asyncio:Task was destroyed but it is pending!
task: <Task pending coro=<worker() running at telegram-download-daemon.py:228> wait_for=<Future pending cb=[<TaskWakeupMethWrapper object at 0x7f26f4006e28>()]>>
alfem commented

It seems you are not using the real channel id.

Please, check #45 #48 or #73

Thanks @alfem, I thought so too so I tried multiple sources and double checked, I think it's the correct one... anything else I can try to verify?

I cannot freakin' believe it! the dash ("-") is a part of the channel ID?! OMG, I've been trying to solve this for hours.....