Giter VIP home page Giter VIP logo

telegram-sentinel's People

Contributors

kelvinxuande avatar

Watchers

 avatar

telegram-sentinel's Issues

Forwarder not forwarding from groups unless I am admin

Hi. Your setup is very clever with a two bot system, but the Telethon component does not seem to be able to capture messages from groups unless I am the admin of the group.

I.e. if I create a group "test", and add that group to "input_channel_names", then the bot works fine. But if I add some other group to "input_channel_names" which I did not create myself, then nothing happens. It does not detect a single message from any other groups.

I even put a debug print in forwarding_handler and it is never called. Any idea why that is? Something seems to be wrong with the initial setup.

I can see in the Telethon debug output that it's receiving updates from these other groups, but in the code the forwarding handler is never triggered.

Issue: (for instance, bots cannot start conversations) (caused by ForwardMessagesRequest)

Hey Kelvin,

Clueless about python. I do a bit of PowerShell for my work but that is it. I ran the first python run_bot.py with no issue, and I do see 'message' as I type the messaged but on the secondary window I am seeing below error. Any ideas to where I might be going wrong?

C:\Program Files\Spyder\telegram-sentinel-master\telegram-sentinel-master\forward_msg>python main.py config.yml
Entity-check successful!
Listening on 2 channels. Forwarding messages to chatSentinel_bot.
Unhandled exception on forwarding_handler
Traceback (most recent call last):
File "C:\Users\Test\AppData\Roaming\Python\Python310\site-packages\telethon\client\updates.py", line 454, in _dispatch_update
await callback(event)
File "C:\Program Files\Spyder\telegram-sentinel-master\telegram-sentinel-master\forward_msg\main.py", line 69, in forwarding_handler
await client.forward_messages(output_channel_entity, event.message)
File "C:\Users\Test\AppData\Roaming\Python\Python310\site-packages\telethon\client\messages.py", line 985, in forward_messages
result = await self(req)
File "C:\Users\Test\AppData\Roaming\Python\Python310\site-packages\telethon\client\users.py", line 30, in call
return await self._call(self._sender, request, ordered=ordered)
File "C:\Users\Test\AppData\Roaming\Python\Python310\site-packages\telethon\client\users.py", line 79, in _call
result = await future
telethon.errors.rpcerrorlist.PeerIdInvalidError: An invalid Peer was used. Make sure to pass the right peer type and that the value is valid (for instance, bots cannot start conversations) (caused by ForwardMessagesRequest)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.