Is your feature request related to a problem? Please describe.
Currently all the modules like telegram.{message, chat, user, …} look like they are public. However, we don't consider them to be part of the public API and they should not be treated as such by the user. The only thing that we guarantee to work is from telegram import Message, Chat, User, … and not from telegram.message import Message.
Describe the solution you'd like
Rename all the private modules with a leading underscore, i.e. all files that contain classes that are imported in the __init__.
This is in accordance with PEP8:
Even with __all__ set appropriately, internal interfaces (packages, modules, classes, functions, attributes or other names) should still be prefixed with a single leading underscore.
this should also be done for the telegram.ext package except for the module telegram.ext.filters. The packages telegram(.ext).utils should also be renamed to telegram(.ext)._utils and dropped from the documentation - unless this leads to pre-commit complaining about importing private packages. If it does, we'll have to re-evaluate.
Additional context
Is your feature request related to a problem? Please describe.
Currently all the modules like
telegram.{message, chat, user, …}look like they are public. However, we don't consider them to be part of the public API and they should not be treated as such by the user. The only thing that we guarantee to work isfrom telegram import Message, Chat, User, …and notfrom telegram.message import Message.Describe the solution you'd like
Rename all the private modules with a leading underscore, i.e. all files that contain classes that are imported in the
__init__.This is in accordance with PEP8:
this should also be done for the
telegram.extpackage except for the moduletelegram.ext.filters. The packagestelegram(.ext).utilsshould also be renamed totelegram(.ext)._utilsand dropped from the documentation - unless this leads to pre-commit complaining about importing private packages. If it does, we'll have to re-evaluate.Additional context