From b2925f82798726585ad73ff9116ca5f4a2894937 Mon Sep 17 00:00:00 2001 From: Lonami Exo Date: Wed, 14 Dec 2022 20:00:55 +0100 Subject: [PATCH] Update documentation and list of known errors --- readthedocs/examples/working-with-messages.rst | 3 ++- telethon_generator/data/errors.csv | 1 + telethon_generator/data/methods.csv | 2 +- 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/readthedocs/examples/working-with-messages.rst b/readthedocs/examples/working-with-messages.rst index dd123e94..ac8c6744 100644 --- a/readthedocs/examples/working-with-messages.rst +++ b/readthedocs/examples/working-with-messages.rst @@ -35,7 +35,8 @@ send yourself the very first sticker you have: stickers = await client(GetStickerSetRequest( stickerset=InputStickerSetID( id=sticker_set.id, access_hash=sticker_set.access_hash - ) + ), + hash=0 )) # Stickers are nothing more than files, so send that diff --git a/telethon_generator/data/errors.csv b/telethon_generator/data/errors.csv index 856bf98d..5ef03e8f 100644 --- a/telethon_generator/data/errors.csv +++ b/telethon_generator/data/errors.csv @@ -395,6 +395,7 @@ USERNAME_INVALID,400,"Nobody is using this username, or the username is unaccept USERNAME_NOT_MODIFIED,400,The username is not different from the current username USERNAME_NOT_OCCUPIED,400,The username is not in use by anyone else yet USERNAME_OCCUPIED,400,The username is already taken +USERNAME_PURCHASE_AVAILABLE,400, USERS_TOO_FEW,400,"Not enough users (to create a chat, for example)" USERS_TOO_MUCH,400,"The maximum number of users has been exceeded (to create a chat, for example)" USER_ADMIN_INVALID,400,Either you're not an admin or you tried to ban an admin that you didn't promote diff --git a/telethon_generator/data/methods.csv b/telethon_generator/data/methods.csv index e32f5a24..074a9ceb 100644 --- a/telethon_generator/data/methods.csv +++ b/telethon_generator/data/methods.csv @@ -123,7 +123,7 @@ channels.setStickers,both,CHANNEL_INVALID PARTICIPANTS_TOO_FEW STICKERSET_OWNER_ channels.togglePreHistoryHidden,user,CHAT_LINK_EXISTS channels.toggleSignatures,user,CHANNEL_INVALID channels.toggleSlowMode,user,SECONDS_INVALID -channels.updateUsername,user,CHANNELS_ADMIN_PUBLIC_TOO_MUCH CHANNEL_INVALID CHAT_ADMIN_REQUIRED USERNAME_INVALID USERNAME_OCCUPIED +channels.updateUsername,user,CHANNELS_ADMIN_PUBLIC_TOO_MUCH CHANNEL_INVALID CHAT_ADMIN_REQUIRED USERNAME_INVALID USERNAME_OCCUPIED USERNAME_PURCHASE_AVAILABLE channels.viewSponsoredMessage,user,UNKNOWN_ERROR contacts.acceptContact,user, contacts.addContact,user,CONTACT_NAME_EMPTY