Rename chat and user arguments to chat_id and user_id
See original GitHub issueAfter discussion in aiogram_ru#80199 and #172 is planned to rename all chat and user arguments to chat_id and user_id and marking old arguments as deprecated until 3.0.
Affected:
- https://github.com/aiogram/aiogram/blob/c6923e331c1222b275aa87ce87ffabf17b185890/aiogram/dispatcher/dispatcher.py#L860-L862
- https://github.com/aiogram/aiogram/blob/c6923e331c1222b275aa87ce87ffabf17b185890/aiogram/dispatcher/dispatcher.py#L887
- https://github.com/aiogram/aiogram/blob/c6923e331c1222b275aa87ce87ffabf17b185890/aiogram/dispatcher/dispatcher.py#L964
Issue Analytics
- State:
- Created 4 years ago
- Comments:7 (6 by maintainers)
Top Results From Across the Web
Telegram CLI Commands - GitHub Gist
Sets channel about info. Sets channel username info. Prints info about chat (id, members, admin, etc.) Clears all data and exits.
Read more >How to obtain Telegram chat_id for a specific user?
To get group chat ID, first you have to add the bot to the group, then send /my_id in the group. Here's the...
Read more >telegram.Chat - python-telegram-bot v20.0b0
Chat(id, type, title=None, username=None, first_name=None, last_name=None, ... The following are now keyword-only arguments in Bot methods: location ...
Read more >Top 5 Pyrogram Code Examples - Snyk
Parameters : chat_id (``int`` | ``str``): Unique identifier (int) or username (str) of the target chat. Unique identifier for the target chat in...
Read more >Managing Users - React chat - GetStream.io
Unique Usernames Clients can set a username, by setting the name custom field. The field is optional and by default has no uniqueness...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

Hi @tohabyuraev. Thank you for your interest!
This issue affects all the modules in the framework, including
dispatcher.pyandstorage.py. I am not sure whether there is an effective technique to search, because we need to rename all usages in every module.I would recommend to do refactoring step by step: that’s not a task which is easy to be done in an evening. Consider opening a draft PR - this way you’ll get the feedback ASAP. Feel free to ping me for any further questions!
Additional affected lines, in storage.py:
https://github.com/aiogram/aiogram/blob/01f075d905798c8dde04e9ba86a9bb6917ba9e9a/aiogram/dispatcher/storage.py#L41-L43 https://github.com/aiogram/aiogram/blob/01f075d905798c8dde04e9ba86a9bb6917ba9e9a/aiogram/dispatcher/storage.py#L63-L66 https://github.com/aiogram/aiogram/blob/01f075d905798c8dde04e9ba86a9bb6917ba9e9a/aiogram/dispatcher/storage.py#L80-L83 https://github.com/aiogram/aiogram/blob/01f075d905798c8dde04e9ba86a9bb6917ba9e9a/aiogram/dispatcher/storage.py#L97-L100 https://github.com/aiogram/aiogram/blob/01f075d905798c8dde04e9ba86a9bb6917ba9e9a/aiogram/dispatcher/storage.py#L113-L116 https://github.com/aiogram/aiogram/blob/01f075d905798c8dde04e9ba86a9bb6917ba9e9a/aiogram/dispatcher/storage.py#L129-L133 https://github.com/aiogram/aiogram/blob/01f075d905798c8dde04e9ba86a9bb6917ba9e9a/aiogram/dispatcher/storage.py#L150-L152 https://github.com/aiogram/aiogram/blob/01f075d905798c8dde04e9ba86a9bb6917ba9e9a/aiogram/dispatcher/storage.py#L165-L168 https://github.com/aiogram/aiogram/blob/01f075d905798c8dde04e9ba86a9bb6917ba9e9a/aiogram/dispatcher/storage.py#L186-L188 https://github.com/aiogram/aiogram/blob/01f075d905798c8dde04e9ba86a9bb6917ba9e9a/aiogram/dispatcher/storage.py#L204-L207 https://github.com/aiogram/aiogram/blob/01f075d905798c8dde04e9ba86a9bb6917ba9e9a/aiogram/dispatcher/storage.py#L221-L224 https://github.com/aiogram/aiogram/blob/01f075d905798c8dde04e9ba86a9bb6917ba9e9a/aiogram/dispatcher/storage.py#L237-L241 https://github.com/aiogram/aiogram/blob/01f075d905798c8dde04e9ba86a9bb6917ba9e9a/aiogram/dispatcher/storage.py#L258-L260 https://github.com/aiogram/aiogram/blob/01f075d905798c8dde04e9ba86a9bb6917ba9e9a/aiogram/dispatcher/storage.py#L275-L277 https://github.com/aiogram/aiogram/blob/01f075d905798c8dde04e9ba86a9bb6917ba9e9a/aiogram/dispatcher/storage.py#L295 https://github.com/aiogram/aiogram/blob/01f075d905798c8dde04e9ba86a9bb6917ba9e9a/aiogram/dispatcher/storage.py#L298 https://github.com/aiogram/aiogram/blob/01f075d905798c8dde04e9ba86a9bb6917ba9e9a/aiogram/dispatcher/storage.py#L301 And a couple one after the last 2 lines, the same as them