Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Getting user limited by Telegram for DM sends - guidelines? #397

Closed
dsldsl opened this issue Oct 31, 2017 · 8 comments
Closed

Getting user limited by Telegram for DM sends - guidelines? #397

dsldsl opened this issue Oct 31, 2017 · 8 comments
Labels
question Question about strange Telegram's API

Comments

@dsldsl
Copy link

dsldsl commented Oct 31, 2017

I'm having a different-but-similar issue as issue 297 -- it's more of a Telegram API / spam block issue. I'm unsure how to get support from them, so wanted to ask this community.

(Is there a good place to get Telegram support for questions around how to stay within guidelines and not get user limited for sending DMs?)

I am an admin in a large superchat room. We’re working to help protect our users from fraud by having our team members reach out 1:1 to make sure they know to watch out for scammers. We’re using the Telethon to help id and DM message users we think may be at risk. I've followed different patterns with a few different admins and all get limited after around 50 DMs. I think that we’re just hitting some automated spam filter or rate limit (vs user reporting) because the users we message all seem very engaged and appreciative.

Specifically, the error is:

telethon.errors.rpc_errors.RPCError: PEER_FLOOD (code 400)

Thank you for any tips or directional guidance!

@Lonami
Copy link
Member

Lonami commented Oct 31, 2017

Is there a good place to get Telegram support for questions around how to stay within guidelines and not get user limited for sending DMs

The rules are mostly simple: don't talk to strangers as they can report you, and don't add strangers to groups or channels as they can report you too.

We’re using the Telethon to help id and DM message users we think may be at risk.

That itself may be risky. Perhaps the best option would just be to mention them in the group to warn them, after all, they should have the mention button to jump to the mention and see your warning, without risking them to block whatever account you're using.

I think that we’re just hitting some automated spam filter or rate limit (vs user reporting)

Hm, I have no idea about that so perhaps it could be that way. But if it exists, I'm unaware of it.

telethon.errors.rpc_errors.RPCError: PEER_FLOOD (code 400)

Consider upgrading, the error should now be PeerFloodError.

@Lonami Lonami added the question Question about strange Telegram's API label Oct 31, 2017
@Lonami Lonami changed the title Getting user limited by Telegram for DM sends - guidelines? [Telegram issue] Getting user limited by Telegram for DM sends - guidelines? Oct 31, 2017
@ghost
Copy link

ghost commented Nov 5, 2017

please suggest, how to except the error and go on with the program?

Exception in thread Thread-1: Traceback (most recent call last): File "/usr/lib/python3.5/threading.py", line 914, in _bootstrap_inner self.run() File "/usr/lib/python3.5/threading.py", line 862, in run self._target(*self._args, **self._kwargs) File "main.py", line 67, in monitorandsend result = client.send_message(adtarget,tgmessage) File "/home/kali/.local/lib/python3.5/site-packages/telethon/telegram_client.py", line 369, in send_message result = self(request) File "/home/kali/.local/lib/python3.5/site-packages/telethon/telegram_bare_client.py", line 461, in __call__ sender, call_receive, update_state, *requests File "/home/kali/.local/lib/python3.5/site-packages/telethon/telegram_bare_client.py", line 518, in _invoke raise next(x.rpc_error for x in requests if x.rpc_error) telethon.errors.rpc_error_list.PeerFloodError

@Lonami
Copy link
Member

Lonami commented Nov 5, 2017

Well currently there's no way to globally capture the errors unless you define your custom function and use that instead. You see, the library can't know your control flow or what you would want to do in certain cases so I can't just "go on with the program". I'm open for suggestions though.

@ghost
Copy link

ghost commented Nov 5, 2017

kk thx figured it

from telethon.errors.rpc_error_list import PeerFloodError

except PeerFloodError:
	print('EXCEPTION')

@Lonami
Copy link
Member

Lonami commented Jan 16, 2018

@Lonami Lonami closed this as completed Jul 29, 2018
@ogcrypto
Copy link

Sorry, you can only send messages to mutual contacts at the moment. More info »
Click for technical details

please help me i keep on getting this issue even when the time i was promise my account will be release

@jjhesk
Copy link

jjhesk commented Oct 16, 2019

how to avoid this error?

@Lonami
Copy link
Member

Lonami commented Oct 16, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Question about strange Telegram's API
Projects
None yet
Development

No branches or pull requests

4 participants