Open GodFatherClover opened 5 months ago
for attr in message.sticker.attributes: if isinstance(attr, types.DocumentAttributeSticker): if type(attr.stickerset) is InputStickerSetID: sticker_id = attr.stickerset.id sticker_access_hash = attr.stickerset.access_hash result = await client(functions.stickers.AddStickerToSetRequest( stickerset=types.InputStickerSetID( id=sticker_id, access_hash=sticker_access_hash, ), sticker=types.InputStickerSetItem( document=types.InputDocument( id=message.sticker.id, access_hash=message.sticker.access_hash, file_reference=message.sticker.file_reference ), emoji='some string here', ) )) print(result.stringify())
AddStickerToSetRequest success
The provided sticker set is invalid (caused by AddStickerToSetRequest)
No response
1.35
3.11
windows 11
pip install -U https://github.com/LonamiWebs/Telethon/archive/v1.zip
the message.sticker is above picture show
Code that causes the issue
Expected behavior
AddStickerToSetRequest success
Actual behavior
The provided sticker set is invalid (caused by AddStickerToSetRequest)
Traceback
No response
Telethon version
1.35
Python version
3.11
Operating system (including distribution name and version)
windows 11
Other details
No response
Checklist
pip install -U https://github.com/LonamiWebs/Telethon/archive/v1.zip
and triggered the bug in the latest version.