Telethon icon indicating copy to clipboard operation
Telethon copied to clipboard

Message Sending Failure with arabic symbols

Open yarodevuci opened this issue 1 week ago • 1 comments

Code that causes the issue

await bot.send_message(chat_id, message=message, link_preview=False)

Failed message: " گندم را دزدیدند صدای اعتراض هابلند شد، نان بین مردم پخش کردند اعتراض هاخاموش شد، این جماعت فقط به دنبالسیر کردن شکم خود هستند نه گرفتن حقشان! "نویسنده: برتولت برشت____________________@__hijran

Error: Exception Type: EntityBoundsInvalidError. Some of provided entities have invalid bounds (length is zero or out of the boundaries of the string) (caused by SendMessageRequest)

Expected behavior

sending without issues

Actual behavior

Error: Exception Type: EntityBoundsInvalidError. Some of provided entities have invalid bounds (length is zero or out of the boundaries of the string) (caused by SendMessageRequest)

Traceback

No response

Telethon version

1.36.0

Python version

3.10

Operating system (including distribution name and version)

Ubuntu

Other details

No response

Checklist

  • [X] The error is in the library's code, and not in my own.
  • [X] I have searched for this issue before posting it and there isn't an open duplicate.
  • [X] I ran pip install -U https://github.com/LonamiWebs/Telethon/archive/v1.zip and triggered the bug in the latest version.

yarodevuci avatar Jun 29 '24 21:06 yarodevuci