How to Solve NameError: name 'PeerChannel' is not defined -- telethon

Solution: Import the 'PeerChannel' module

To Solve the error, add the following line to the top of your code.

from telethon import PeerChannel

 

For more information:
Python telethon PeerChannel