mirror of
https://github.com/python-telegram-bot/python-telegram-bot.git
synced 2026-06-19 15:45:13 +00:00
Compare commits
173 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| e982a5a567 | |||
| cf4d3cae01 | |||
| 8531a7a40c | |||
| fce7cc903c | |||
| 5da1dd7ce9 | |||
| 46cdeb495a | |||
| 653691fafb | |||
| 92ff6a8e2b | |||
| cc43aef64b | |||
| e2c6d60721 | |||
| 8bf88c3231 | |||
| 1572c61063 | |||
| 5ff3b76e18 | |||
| cd69f69b28 | |||
| 8b0d2e5f75 | |||
| 7d0fb85c8c | |||
| 08ba7c7793 | |||
| 9737b1d3c7 | |||
| 94a9b7f983 | |||
| bae57c7f8f | |||
| b20265819b | |||
| 3938a57542 | |||
| 4645d0e32a | |||
| 7e554584b1 | |||
| b6a6d7f872 | |||
| 3b92901892 | |||
| b63877b1f2 | |||
| 9d93417d9a | |||
| 9949b44560 | |||
| 7abacb000b | |||
| 43f5aeaff3 | |||
| 9e08fa30b6 | |||
| ccedd3a87d | |||
| 0bb4be55ac | |||
| 21ded420e2 | |||
| 7d893fd04b | |||
| 7015f8dedc | |||
| ac02bce109 | |||
| 3a9a0ab96d | |||
| aba17cb997 | |||
| 038a3b4452 | |||
| b03ebc5a65 | |||
| e9c01c7772 | |||
| 552298595c | |||
| 2a4a0d0ccd | |||
| eb993db473 | |||
| c77ef7eef3 | |||
| a34f0b9bee | |||
| eee8921598 | |||
| 1902c0ac36 | |||
| 544a3fbf48 | |||
| 36d49ea9cd | |||
| 25506f131d | |||
| 70aba136e4 | |||
| 40995b19fe | |||
| 32da6d6fce | |||
| f31787a8ef | |||
| b43a599e53 | |||
| 7a3fd83570 | |||
| 9ada2a7cca | |||
| be54cf4ece | |||
| 0c9915243d | |||
| 9930725e2a | |||
| ffd675daec | |||
| 6a831f926b | |||
| 6903d58142 | |||
| 07b6ee69d2 | |||
| c8a3c31dcc | |||
| 91e0271e4c | |||
| 9ddb361f76 | |||
| 89c522d883 | |||
| 2effff8254 | |||
| 2788191657 | |||
| aec6d3bada | |||
| 80b34811ab | |||
| 2d7a974b8f | |||
| ef703d19e9 | |||
| 77a8c64f6c | |||
| 786762bb73 | |||
| e0dbb99b08 | |||
| 73b0e29a30 | |||
| d27d1ea4d5 | |||
| ca04daf782 | |||
| ae9ce60b55 | |||
| 1cd3a0a156 | |||
| 58b9882021 | |||
| df6d5f0840 | |||
| 425716f966 | |||
| 8d9bb26cca | |||
| d1438a9b23 | |||
| 27b03edc59 | |||
| ac449deb5d | |||
| 3b9187ed5a | |||
| 9831458e22 | |||
| a0cd6e8fef | |||
| 8e7c0d6976 | |||
| 92b9370c23 | |||
| 237e73bfb4 | |||
| ff3fd34f08 | |||
| 83791d34e7 | |||
| 02cd7b642f | |||
| 165a24e13d | |||
| 88440079e3 | |||
| 9be4c7563b | |||
| b554f1a85d | |||
| 3b4559dd95 | |||
| 9ae48fecfe | |||
| 6af6648509 | |||
| 264b2c9c72 | |||
| 8efb05290a | |||
| 83a8874bb5 | |||
| bf68942c91 | |||
| 5fd7606084 | |||
| 103b115486 | |||
| b07e42ef33 | |||
| 3842846b2d | |||
| 7daddfb54d | |||
| 2d4d48b89d | |||
| 2381724b7c | |||
| 19a4f9e53a | |||
| 3930072659 | |||
| 5555582b72 | |||
| e67b995e64 | |||
| 0d419ed6b4 | |||
| 97adcdf538 | |||
| 2989108e95 | |||
| 897a20d758 | |||
| ed3a9b64e2 | |||
| 49c0c9e4d1 | |||
| bb34c79909 | |||
| a0720b9ac6 | |||
| faa93fbf75 | |||
| da452df07d | |||
| 3304cc5c90 | |||
| 9105d83d37 | |||
| b6b42b2043 | |||
| f857e1c23b | |||
| fc5844c13d | |||
| dea24bcb7c | |||
| 2789fd2bff | |||
| d6f8077a50 | |||
| 0189442525 | |||
| fd0325fbe5 | |||
| ff4bb15fef | |||
| 9288e4f2e4 | |||
| e60318166e | |||
| 15268acb27 | |||
| 927502e588 | |||
| 0af5cc2db8 | |||
| 6005861f46 | |||
| 8406889179 | |||
| a4e78f6183 | |||
| 8c6cb44a85 | |||
| ac7cc7fe5e | |||
| a42b68933c | |||
| c2d91c752f | |||
| 5057825586 | |||
| 613175b2c4 | |||
| 1330696259 | |||
| 5898e1fe7a | |||
| b6dec118c1 | |||
| 186fd1b418 | |||
| 284786fdb8 | |||
| c7c56ad24e | |||
| ae17ce977e | |||
| 7e231183c4 | |||
| 8427346a0d | |||
| 632b989d90 | |||
| 76567ba635 | |||
| 2bd3f2a65a | |||
| 26a5006bf1 | |||
| 110e2df443 | |||
| 57546795c5 |
@@ -0,0 +1,20 @@
|
||||
version = 1
|
||||
|
||||
test_patterns = ["tests/**"]
|
||||
|
||||
exclude_patterns = [
|
||||
"tests/**",
|
||||
"docs/**",
|
||||
"telegram/vendor/**",
|
||||
"setup.py",
|
||||
"setup-raw.py"
|
||||
]
|
||||
|
||||
[[analyzers]]
|
||||
name = "python"
|
||||
enabled = true
|
||||
|
||||
[analyzers.meta]
|
||||
runtime_version = "3.x.x"
|
||||
max_line_length = 99
|
||||
skip_doc_coverage = ["module", "magic", "init", "nonpublic"]
|
||||
+26
-24
@@ -41,15 +41,17 @@ If you already know what you'd like to work on, you can skip this section.
|
||||
|
||||
If you have an idea for something to do, first check if it's already been filed on the `issue tracker`_. If so, add a comment to the issue saying you'd like to work on it, and we'll help you get started! Otherwise, please file a new issue and assign yourself to it.
|
||||
|
||||
Another great way to start contributing is by writing tests. Tests are really important because they help prevent developers from accidentally breaking existing code, allowing them to build cool things faster. If you're interested in helping out, let the development team know by posting to the `developers' mailing list`_, and we'll help you get started.
|
||||
Another great way to start contributing is by writing tests. Tests are really important because they help prevent developers from accidentally breaking existing code, allowing them to build cool things faster. If you're interested in helping out, let the development team know by posting to the `Telegram group`_ (use `@admins` to mention the maintainers), and we'll help you get started.
|
||||
|
||||
That being said, we want to mention that we are very hesistant about adding new requirements to our projects. If you intend to do this, please state this in an issue and get a verification from one of the maintainers.
|
||||
That being said, we want to mention that we are very hesitant about adding new requirements to our projects. If you intend to do this, please state this in an issue and get a verification from one of the maintainers.
|
||||
|
||||
Instructions for making a code change
|
||||
#####################################
|
||||
|
||||
The central development branch is ``master``, which should be clean and ready for release at any time. In general, all changes should be done as feature branches based off of ``master``.
|
||||
|
||||
If you want to do solely documentation changes, base them and PR to the branch ``doc-fixes``. This branch also has its own `RTD build`_.
|
||||
|
||||
Here's how to make a one-off code change.
|
||||
|
||||
1. **Choose a descriptive branch name.** It should be lowercase, hyphen-separated, and a noun describing the change (so, ``fuzzy-rules``, but not ``implement-fuzzy-rules``). Also, it shouldn't start with ``hotfix`` or ``release``.
|
||||
@@ -68,7 +70,9 @@ Here's how to make a one-off code change.
|
||||
- You can refer to relevant issues in the commit message by writing, e.g., "#105".
|
||||
|
||||
- Your code should adhere to the `PEP 8 Style Guide`_, with the exception that we have a maximum line length of 99.
|
||||
|
||||
|
||||
- Provide static typing with signature annotations. The documentation of `MyPy`_ will be a good start, the cheat sheet is `here`_. We also have some custom type aliases in ``telegram.utils.helpers.typing``.
|
||||
|
||||
- Document your code. This project uses `sphinx`_ to generate static HTML docs. To build them, first make sure you have the required dependencies:
|
||||
|
||||
.. code-block:: bash
|
||||
@@ -89,12 +93,16 @@ Here's how to make a one-off code change.
|
||||
|
||||
Once the process terminates, you can view the built documentation by opening ``docs/build/html/index.html`` with a browser.
|
||||
|
||||
- For consistency, please conform to `Google Python Style Guide`_ and `Google Python Style Docstrings`_. In addition, code should be formatted consistently with other code around it.
|
||||
- Add ``.. versionadded:: version``, ``.. versionchanged:: version`` or ``.. deprecated:: version`` to the associated documentation of your changes, depending on what kind of change you made. This only applies if the change you made is visible to an end user. The directives should be added to class/method descriptions if their general behaviour changed and to the description of all arguments & attributes that changed.
|
||||
|
||||
- For consistency, please conform to `Google Python Style Guide`_ and `Google Python Style Docstrings`_.
|
||||
|
||||
- The following exceptions to the above (Google's) style guides applies:
|
||||
|
||||
- Documenting types of global variables and complex types of class members can be done using the Sphinx docstring convention.
|
||||
|
||||
- In addition, PTB uses the `Black`_ coder formatting. Plugins for Black exist for some `popular editors`_. You can use those instead of manually formatting everything.
|
||||
|
||||
- Please ensure that the code you write is well-tested.
|
||||
|
||||
- Don’t break backward compatibility.
|
||||
@@ -103,12 +111,6 @@ Here's how to make a one-off code change.
|
||||
|
||||
- Before making a commit ensure that all automated tests still pass:
|
||||
|
||||
.. code-block::
|
||||
|
||||
$ make test
|
||||
|
||||
If you don't have ``make``, do:
|
||||
|
||||
.. code-block::
|
||||
|
||||
$ pytest -v
|
||||
@@ -121,18 +123,18 @@ Here's how to make a one-off code change.
|
||||
|
||||
prior to running the tests.
|
||||
|
||||
- To actually make the commit (this will trigger tests for yapf, lint and pep8 automatically):
|
||||
- If you want run style & type checks before committing run
|
||||
|
||||
.. code-block::
|
||||
|
||||
$ pre-commit run -a
|
||||
|
||||
- To actually make the commit (this will trigger tests style & type checks automatically):
|
||||
|
||||
.. code-block:: bash
|
||||
|
||||
$ git add your-file-changed.py
|
||||
|
||||
- yapf may change code formatting, make sure to re-add them to your commit.
|
||||
|
||||
.. code-block:: bash
|
||||
|
||||
$ git commit -a -m "your-commit-message-here"
|
||||
|
||||
- Finally, push it to your GitHub fork, run:
|
||||
|
||||
.. code-block:: bash
|
||||
@@ -187,15 +189,10 @@ Here's how to make a one-off code change.
|
||||
Style commandments
|
||||
------------------
|
||||
|
||||
Specific commandments
|
||||
#####################
|
||||
|
||||
- Avoid using "double quotes" where you can reasonably use 'single quotes'.
|
||||
|
||||
Assert comparison order
|
||||
#######################
|
||||
|
||||
- assert statements should compare in **actual** == **expected** order.
|
||||
Assert statements should compare in **actual** == **expected** order.
|
||||
For example (assuming ``test_call`` is the thing being tested):
|
||||
|
||||
.. code-block:: python
|
||||
@@ -245,9 +242,14 @@ break the API classes. For example:
|
||||
|
||||
.. _`Code of Conduct`: https://www.python.org/psf/codeofconduct/
|
||||
.. _`issue tracker`: https://github.com/python-telegram-bot/python-telegram-bot/issues
|
||||
.. _`developers' mailing list`: mailto:devs@python-telegram-bot.org
|
||||
.. _`Telegram group`: https://telegram.me/pythontelegrambotgroup
|
||||
.. _`PEP 8 Style Guide`: https://www.python.org/dev/peps/pep-0008/
|
||||
.. _`sphinx`: http://sphinx-doc.org
|
||||
.. _`Google Python Style Guide`: http://google.github.io/styleguide/pyguide.html
|
||||
.. _`Google Python Style Docstrings`: https://sphinxcontrib-napoleon.readthedocs.io/en/latest/example_google.html
|
||||
.. _AUTHORS.rst: ../AUTHORS.rst
|
||||
.. _`MyPy`: https://mypy.readthedocs.io/en/stable/index.html
|
||||
.. _`here`: https://mypy.readthedocs.io/en/stable/cheat_sheet_py3.html
|
||||
.. _`Black`: https://black.readthedocs.io/en/stable/index.html
|
||||
.. _`popular editors`: https://black.readthedocs.io/en/stable/editor_integration.html
|
||||
.. _`RTD build`: https://python-telegram-bot.readthedocs.io/en/doc-fixes
|
||||
|
||||
@@ -3,6 +3,6 @@ contact_links:
|
||||
- name: Telegram Group
|
||||
url: https://telegram.me/pythontelegrambotgroup
|
||||
about: Questions asked on the group usually get answered faster.
|
||||
- name: IRC Channel
|
||||
url: https://webchat.freenode.net/?channels=##python-telegram-bot
|
||||
about: In case you are unable to join our group due to Telegram restrictions, you can use our IRC channel
|
||||
- name: GitHub Discussions
|
||||
url: https://github.com/python-telegram-bot/python-telegram-bot/discussions
|
||||
about: For getting answers to usage on GitHub, Discussions is even better than this bug tracker :)
|
||||
|
||||
@@ -10,9 +10,9 @@ assignees: ''
|
||||
<!--
|
||||
Hey there, you have a question? We are happy to answer. Please make sure no similar question was opened already.
|
||||
|
||||
The following template is a suggestion how you can report an issue you run into whilst using our library. If you just want to ask a question, feel free to delete everything; just make sure you have a describing title :)
|
||||
To make it easier for us to help you, please read this article https://git.io/JURJO and try to follow the template below as closely as possible.
|
||||
|
||||
Please mind that there is also a users' Telegram group at https://t.me/pythontelegrambotgroup for questions about the library. Questions asked there might be answered quicker than here. In case you are unable to join our group due to Telegram restrictions, you can use our IRC channel at https://webchat.freenode.net/?channels=##python-telegram-bot to participate in the group.
|
||||
Please mind that there is also a users' Telegram group at https://t.me/pythontelegrambotgroup for questions about the library. Questions asked there might be answered quicker than here. Moreover, GitHub Discussions at https://git.io/JG3rk offer a slightly better format to discuss usage questions.
|
||||
-->
|
||||
|
||||
### Issue I am facing
|
||||
|
||||
@@ -0,0 +1,31 @@
|
||||
<!--
|
||||
Hey! You're PRing? Cool! Please have a look at the below checklist. It's here to help both you and the maintainers to remember some aspects. Make sure to check out our contribution guide (https://github.com/python-telegram-bot/python-telegram-bot/blob/master/.github/CONTRIBUTING.rst).
|
||||
-->
|
||||
|
||||
### Checklist for PRs
|
||||
|
||||
- [ ] Added `.. versionadded:: version`, `.. versionchanged:: version` or `.. deprecated:: version` to the docstrings for user facing changes (for methods/class descriptions, arguments and attributes)
|
||||
- [ ] Created new or adapted existing unit tests
|
||||
- [ ] Added myself alphabetically to `AUTHORS.rst` (optional)
|
||||
|
||||
|
||||
### If the PR contains API changes (otherwise, you can delete this passage)
|
||||
|
||||
* New classes:
|
||||
- [ ] Added `self._id_attrs` and corresponding documentation
|
||||
- [ ] `__init__` accepts `**_kwargs`
|
||||
|
||||
* Added new shortcuts:
|
||||
- [ ] In `Chat` & `User` for all methods that accept `chat/user_id`
|
||||
- [ ] In `Message` for all methods that accept `chat_id` and `message_id`
|
||||
- [ ] For new `Message` shortcuts: Added `quote` argument if methods accepts `reply_to_message_id`
|
||||
- [ ] In `CallbackQuery` for all methods that accept either `chat_id` and `message_id` or `inline_message_id`
|
||||
|
||||
* If relevant:
|
||||
|
||||
- [ ] Added new constants at `telegram.constants` and shortcuts to them as class variables
|
||||
- [ ] Added new handlers for new update types
|
||||
- [ ] Added new filters for new message (sub)types
|
||||
- [ ] Added or updated documentation for the changed class(es) and/or method(s)
|
||||
- [ ] Updated the Bot API version number in all places: `README.rst` and `README_RAW.rst` (including the badge), as well as `telegram.constants.BOT_API_VERSION`
|
||||
- [ ] Added logic for arbitrary callback data in `tg.ext.Bot` for new methods that either accept a `reply_markup` in some form or have a return type that is/contains `telegram.Message`
|
||||
+1
-1
@@ -1,5 +1,5 @@
|
||||
# Number of days of inactivity before an issue becomes stale
|
||||
daysUntilStale: 5
|
||||
daysUntilStale: 3
|
||||
# Number of days of inactivity before a stale issue is closed
|
||||
daysUntilClose: 2
|
||||
# Only issues or pull requests with all of these labels are check if stale. Defaults to `[]` (disabled)
|
||||
|
||||
@@ -0,0 +1,18 @@
|
||||
name: 'Lock Closed Threads'
|
||||
|
||||
on:
|
||||
schedule:
|
||||
- cron: '8 4 * * *'
|
||||
- cron: '42 17 * * *'
|
||||
|
||||
jobs:
|
||||
lock:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: dessant/lock-threads@v2.0.1
|
||||
with:
|
||||
github-token: ${{ github.token }}
|
||||
issue-lock-inactive-days: '1'
|
||||
issue-lock-reason: ''
|
||||
pr-lock-inactive-days: '1'
|
||||
pr-lock-reason: ''
|
||||
@@ -0,0 +1,17 @@
|
||||
name: Warning maintainers
|
||||
on:
|
||||
pull_request:
|
||||
paths:
|
||||
- requirements.txt
|
||||
- requirements-dev.txt
|
||||
- .pre-commit-config.yaml
|
||||
jobs:
|
||||
job:
|
||||
runs-on: ubuntu-latest
|
||||
name: about pre-commit and dependency change
|
||||
steps:
|
||||
- name: running the check
|
||||
uses: Poolitzer/notifier-action@master
|
||||
with:
|
||||
notify-message: Hey! Looks like you edited the (dev) requirements or the pre-commit hooks. I'm just a friendly reminder to keep the pre-commit hook versions in sync with the dev requirements and the additional dependencies for the hooks in sync with the requirements :)
|
||||
repo-token: ${{ secrets.GITHUB_TOKEN }}
|
||||
@@ -0,0 +1,16 @@
|
||||
name: Warning maintainers
|
||||
on:
|
||||
pull_request:
|
||||
paths:
|
||||
- README.rst
|
||||
- README_RAW.rst
|
||||
jobs:
|
||||
job:
|
||||
runs-on: ubuntu-latest
|
||||
name: about readme change
|
||||
steps:
|
||||
- name: running the check
|
||||
uses: Poolitzer/notifier-action@master
|
||||
with:
|
||||
notify-message: Hey! Looks like you edited README.rst or README_RAW.rst. I'm just a friendly reminder to apply relevant changes to both of those files :)
|
||||
repo-token: ${{ secrets.GITHUB_TOKEN }}
|
||||
+30
-29
@@ -3,8 +3,6 @@ on:
|
||||
pull_request:
|
||||
branches:
|
||||
- master
|
||||
schedule:
|
||||
- cron: 7 3 * * *
|
||||
push:
|
||||
branches:
|
||||
- master
|
||||
@@ -15,15 +13,8 @@ jobs:
|
||||
runs-on: ${{matrix.os}}
|
||||
strategy:
|
||||
matrix:
|
||||
python-version: [3.5, 3.6, 3.7, 3.8]
|
||||
os: [ubuntu-latest, windows-latest]
|
||||
include:
|
||||
- os: ubuntu-latest
|
||||
python-version: 3.7
|
||||
test-build: True
|
||||
- os: windows-latest
|
||||
python-version: 3.7
|
||||
test-build: True
|
||||
python-version: [3.6, 3.7, 3.8, 3.9]
|
||||
os: [ubuntu-latest, windows-latest, macos-latest]
|
||||
fail-fast: False
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
@@ -31,7 +22,7 @@ jobs:
|
||||
run:
|
||||
git submodule update --init --recursive
|
||||
- name: Set up Python ${{ matrix.python-version }}
|
||||
uses: actions/setup-python@v1
|
||||
uses: actions/setup-python@v2
|
||||
with:
|
||||
python-version: ${{ matrix.python-version }}
|
||||
- name: Install dependencies
|
||||
@@ -42,28 +33,38 @@ jobs:
|
||||
python -W ignore -m pip install -r requirements-dev.txt
|
||||
|
||||
- name: Test with pytest
|
||||
# We run 3 different suites here
|
||||
# 1. Test just utils.helpers.py without pytz being installed
|
||||
# 2. Test just test_no_passport.py without passport dependencies being installed
|
||||
# 3. Test everything else
|
||||
# The first & second one are achieved by mocking the corresponding import
|
||||
# See test_helpers.py & test_no_passport.py for details
|
||||
run: |
|
||||
pytest -v -m nocoverage
|
||||
nocov_exit=$?
|
||||
pytest -v -m "not nocoverage" --cov
|
||||
cov_exit=$?
|
||||
global_exit=$(( nocov_exit > cov_exit ? nocov_exit : cov_exit ))
|
||||
pytest -v --cov -k test_no_passport.py
|
||||
no_passport_exit=$?
|
||||
export TEST_NO_PASSPORT='false'
|
||||
pytest -v --cov --cov-append -k test_helpers.py
|
||||
no_pytz_exit=$?
|
||||
export TEST_NO_PYTZ='false'
|
||||
pytest -v --cov --cov-append
|
||||
full_exit=$?
|
||||
special_exit=$(( no_pytz_exit > no_passport_exit ? no_pytz_exit : no_passport_exit ))
|
||||
global_exit=$(( special_exit > full_exit ? special_exit : full_exit ))
|
||||
exit ${global_exit}
|
||||
env:
|
||||
JOB_INDEX: ${{ strategy.job-index }}
|
||||
BOTS: W3sidG9rZW4iOiAiNjk2MTg4NzMyOkFBR1Z3RUtmSEhsTmpzY3hFRE5LQXdraEdzdFpfa28xbUMwIiwgInBheW1lbnRfcHJvdmlkZXJfdG9rZW4iOiAiMjg0Njg1MDYzOlRFU1Q6WldGaU1UUmxNbVF5TnpNeSIsICJib3RfbmFtZSI6ICJQVEIgdGVzdHMgb24gVHJhdmlzIHVzaW5nIENQeXRob24gMi43IiwgImJvdF91c2VybmFtZSI6ICJAcHRiX3RyYXZpc19jcHl0aG9uXzI3X2JvdCJ9LCB7InRva2VuIjogIjY3MTQ2ODg4NjpBQUdQR2ZjaVJJQlVORmU4MjR1SVZkcTdKZTNfWW5BVE5HdyIsICJwYXltZW50X3Byb3ZpZGVyX3Rva2VuIjogIjI4NDY4NTA2MzpURVNUOlpHWXdPVGxrTXpNeE4yWTIiLCAiYm90X25hbWUiOiAiUFRCIHRlc3RzIG9uIFRyYXZpcyB1c2luZyBDUHl0aG9uIDMuNCIsICJib3RfdXNlcm5hbWUiOiAiQHB0Yl90cmF2aXNfY3B5dGhvbl8zNF9ib3QifSwgeyJ0b2tlbiI6ICI2MjkzMjY1Mzg6QUFGUnJaSnJCN29CM211ekdzR0pYVXZHRTVDUXpNNUNVNG8iLCAicGF5bWVudF9wcm92aWRlcl90b2tlbiI6ICIyODQ2ODUwNjM6VEVTVDpNbU01WVdKaFl6a3hNMlUxIiwgImJvdF9uYW1lIjogIlBUQi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X2dyb3VwX2lkIjogIi0xMDAxNDAyMjU1MDcwIiwgInVzZXJuYW1lIjogInB0Yl8yX2JvdCJ9XQ==
|
||||
TEST_NO_PYTZ : "true"
|
||||
TEST_NO_PASSPORT: "true"
|
||||
TEST_BUILD: "true"
|
||||
shell: bash --noprofile --norc {0}
|
||||
|
||||
- name: Submit coverage
|
||||
run: |
|
||||
if [ "$CODECOV_TOKEN" != "" ]; then
|
||||
codecov -F github -t $CODECOV_TOKEN --name "${{ matrix.os }}-${{ matrix.python-version }}"
|
||||
fi
|
||||
env:
|
||||
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
|
||||
shell: bash
|
||||
uses: codecov/codecov-action@v1
|
||||
with:
|
||||
env_vars: OS,PYTHON
|
||||
name: ${{ matrix.os }}-${{ matrix.python-version }}
|
||||
fail_ci_if_error: true
|
||||
test_official:
|
||||
name: test-official
|
||||
runs-on: ${{matrix.os}}
|
||||
@@ -78,7 +79,7 @@ jobs:
|
||||
run:
|
||||
git submodule update --init --recursive
|
||||
- name: Set up Python ${{ matrix.python-version }}
|
||||
uses: actions/setup-python@v1
|
||||
uses: actions/setup-python@v2
|
||||
with:
|
||||
python-version: ${{ matrix.python-version }}
|
||||
- name: Install dependencies
|
||||
@@ -107,7 +108,7 @@ jobs:
|
||||
run:
|
||||
git submodule update --init --recursive
|
||||
- name: Set up Python ${{ matrix.python-version }}
|
||||
uses: actions/setup-python@v1
|
||||
uses: actions/setup-python@v2
|
||||
with:
|
||||
python-version: ${{ matrix.python-version }}
|
||||
- name: Install dependencies
|
||||
|
||||
@@ -46,6 +46,7 @@ htmlcov/
|
||||
.coverage.*
|
||||
.cache
|
||||
.pytest_cache
|
||||
.mypy_cache
|
||||
nosetests.xml
|
||||
coverage.xml
|
||||
*,cover
|
||||
@@ -83,3 +84,6 @@ telegram.jpg
|
||||
|
||||
# Exclude .exrc file for Vim
|
||||
.exrc
|
||||
|
||||
# virtual env
|
||||
venv*
|
||||
|
||||
+49
-10
@@ -1,20 +1,59 @@
|
||||
# Make sure that
|
||||
# * the revs specified here match requirements-dev.txt
|
||||
# * the additional_dependencies here match requirements.txt
|
||||
repos:
|
||||
- repo: git://github.com/python-telegram-bot/mirrors-yapf
|
||||
rev: 5769e088ef6e0a0d1eb63bd6d0c1fe9f3606d6c8
|
||||
- repo: https://github.com/psf/black
|
||||
rev: 20.8b1
|
||||
hooks:
|
||||
- id: yapf
|
||||
files: ^(telegram|tests)/.*\.py$
|
||||
- id: black
|
||||
args:
|
||||
- --diff
|
||||
- --check
|
||||
- repo: https://gitlab.com/pycqa/flake8
|
||||
rev: 3.7.1
|
||||
rev: 3.9.2
|
||||
hooks:
|
||||
- id: flake8
|
||||
- repo: git://github.com/pre-commit/mirrors-pylint
|
||||
rev: 9d8dcbc2b86c796275680f239c1e90dcd50bd398
|
||||
- repo: https://github.com/PyCQA/pylint
|
||||
rev: v2.8.3
|
||||
hooks:
|
||||
- id: pylint
|
||||
files: ^telegram/.*\.py$
|
||||
files: ^(telegram|examples)/.*\.py$
|
||||
args:
|
||||
- --errors-only
|
||||
- --disable=import-error
|
||||
- --rcfile=setup.cfg
|
||||
additional_dependencies:
|
||||
- certifi
|
||||
- tornado>=6.1
|
||||
- APScheduler==3.6.3
|
||||
- cachetools==4.2.2
|
||||
- . # this basically does `pip install -e .`
|
||||
- repo: https://github.com/pre-commit/mirrors-mypy
|
||||
rev: v0.812
|
||||
hooks:
|
||||
- id: mypy
|
||||
name: mypy-ptb
|
||||
files: ^telegram/.*\.py$
|
||||
additional_dependencies:
|
||||
- certifi
|
||||
- tornado>=6.1
|
||||
- APScheduler==3.6.3
|
||||
- cachetools==4.2.2
|
||||
- . # this basically does `pip install -e .`
|
||||
- id: mypy
|
||||
name: mypy-examples
|
||||
files: ^examples/.*\.py$
|
||||
args:
|
||||
- --no-strict-optional
|
||||
- --follow-imports=silent
|
||||
additional_dependencies:
|
||||
- certifi
|
||||
- tornado>=6.1
|
||||
- APScheduler==3.6.3
|
||||
- cachetools==4.2.2
|
||||
- . # this basically does `pip install -e .`
|
||||
- repo: https://github.com/asottile/pyupgrade
|
||||
rev: v2.19.1
|
||||
hooks:
|
||||
- id: pyupgrade
|
||||
files: ^(telegram|examples|tests)/.*\.py$
|
||||
args:
|
||||
- --py36-plus
|
||||
|
||||
+17
-5
@@ -1,10 +1,22 @@
|
||||
# syntax: https://docs.readthedocs.io/en/latest/yaml-config.html
|
||||
# .readthedocs.yaml
|
||||
# Read the Docs configuration file
|
||||
# See https://docs.readthedocs.io/en/stable/config-file/v2.html for details
|
||||
|
||||
# Required
|
||||
version: 2
|
||||
|
||||
# Build documentation in the docs/ directory with Sphinx
|
||||
sphinx:
|
||||
configuration: docs/source/conf.py
|
||||
|
||||
# Optionally build your docs in additional formats such as PDF
|
||||
formats:
|
||||
- pdf
|
||||
- pdf
|
||||
|
||||
# Optionally set the version of Python and requirements required to build your docs
|
||||
python:
|
||||
setup_py_install: true
|
||||
version: 3
|
||||
|
||||
requirements_file: docs/requirements-docs.txt
|
||||
install:
|
||||
- method: pip
|
||||
path: .
|
||||
- requirements: docs/requirements-docs.txt
|
||||
|
||||
+23
-2
@@ -2,9 +2,20 @@ Credits
|
||||
=======
|
||||
|
||||
``python-telegram-bot`` was originally created by
|
||||
`Leandro Toledo <https://github.com/leandrotoledo>`_ and is now maintained by
|
||||
`Leandro Toledo <https://github.com/leandrotoledo>`_.
|
||||
The current development team includes
|
||||
|
||||
- `Hinrich Mahler <https://github.com/Bibo-Joshi>`_ (maintainer)
|
||||
- `Poolitzer <https://github.com/Poolitzer>`_ (community liaison)
|
||||
- `Shivam <https://github.com/Starry69>`_
|
||||
- `Harshil <https://github.com/harshil21>`_
|
||||
|
||||
Emeritus maintainers include
|
||||
`Jannes Höke <https://github.com/jh0ker>`_ (`@jh0ker <https://t.me/jh0ker>`_ on Telegram),
|
||||
`Noam Meltzer <https://github.com/tsnoam>`_, `Pieter Schutz <https://github.com/eldinnie>`_, `Jasmin Bom <https://github.com/jsmnbom>`_ and `Hinrich Mahler <https://github.com/Bibo-Joshi>`_.
|
||||
`Noam Meltzer <https://github.com/tsnoam>`_, `Pieter Schutz <https://github.com/eldinnie>`_ and `Jasmin Bom <https://github.com/jsmnbom>`_.
|
||||
|
||||
Vendored packages
|
||||
-----------------
|
||||
|
||||
We're vendoring urllib3 as part of ``python-telegram-bot`` which is distributed under the MIT
|
||||
license. For more info, full credits & license terms, the sources can be found here:
|
||||
@@ -18,6 +29,7 @@ The following wonderful people contributed directly or indirectly to this projec
|
||||
- `Alateas <https://github.com/alateas>`_
|
||||
- `Ales Dokshanin <https://github.com/alesdokshanin>`_
|
||||
- `Ambro17 <https://github.com/Ambro17>`_
|
||||
- `Andrej Zhilenkov <https://github.com/Andrej730>`_
|
||||
- `Anton Tagunov <https://github.com/anton-tagunov>`_
|
||||
- `Avanatiker <https://github.com/Avanatiker>`_
|
||||
- `Balduro <https://github.com/Balduro>`_
|
||||
@@ -26,6 +38,7 @@ The following wonderful people contributed directly or indirectly to this projec
|
||||
- `d-qoi <https://github.com/d-qoi>`_
|
||||
- `daimajia <https://github.com/daimajia>`_
|
||||
- `Daniel Reed <https://github.com/nmlorg>`_
|
||||
- `D David Livingston <https://github.com/daviddl9>`_
|
||||
- `Eana Hufwe <https://github.com/blueset>`_
|
||||
- `Ehsan Online <https://github.com/ehsanonline>`_
|
||||
- `Eli Gao <https://github.com/eligao>`_
|
||||
@@ -34,9 +47,11 @@ The following wonderful people contributed directly or indirectly to this projec
|
||||
- `Eugene Lisitsky <https://github.com/lisitsky>`_
|
||||
- `Eugenio Panadero <https://github.com/azogue>`_
|
||||
- `Evan Haberecht <https://github.com/habereet>`_
|
||||
- `Evgeny Denisov <https://github.com/eIGato>`_
|
||||
- `evgfilim1 <https://github.com/evgfilim1>`_
|
||||
- `franciscod <https://github.com/franciscod>`_
|
||||
- `gamgi <https://github.com/gamgi>`_
|
||||
- `Gauthamram Ravichandran <https://github.com/GauthamramRavichandran>`_
|
||||
- `Harshil <https://github.com/harshil21>`_
|
||||
- `Hugo Damer <https://github.com/HakimusGIT>`_
|
||||
- `ihoru <https://github.com/ihoru>`_
|
||||
@@ -54,11 +69,15 @@ The following wonderful people contributed directly or indirectly to this projec
|
||||
- `Kjwon15 <https://github.com/kjwon15>`_
|
||||
- `Li-aung Yip <https://github.com/LiaungYip>`_
|
||||
- `Loo Zheng Yuan <https://github.com/loozhengyuan>`_
|
||||
- `LRezende <https://github.com/lrezende>`_
|
||||
- `macrojames <https://github.com/macrojames>`_
|
||||
- `Matheus Lemos <https://github.com/mlemosf>`_
|
||||
- `Michael Elovskikh <https://github.com/wronglink>`_
|
||||
- `Mischa Krüger <https://github.com/Makman2>`_
|
||||
- `naveenvhegde <https://github.com/naveenvhegde>`_
|
||||
- `neurrone <https://github.com/neurrone>`_
|
||||
- `NikitaPirate <https://github.com/NikitaPirate>`_
|
||||
- `Nikolai Krivenko <https://github.com/nkrivenko>`_
|
||||
- `njittam <https://github.com/njittam>`_
|
||||
- `Noam Meltzer <https://github.com/tsnoam>`_
|
||||
- `Oleg Shlyazhko <https://github.com/ollmer>`_
|
||||
@@ -69,6 +88,7 @@ The following wonderful people contributed directly or indirectly to this projec
|
||||
- `Paul Larsen <https://github.com/PaulSonOfLars>`_
|
||||
- `Pieter Schutz <https://github.com/eldinnie>`_
|
||||
- `Poolitzer <https://github.com/Poolitzer>`_
|
||||
- `Pranjalya Tiwari <https://github.com/Pranjalya>`_
|
||||
- `Rahiel Kasim <https://github.com/rahiel>`_
|
||||
- `Riko Naka <https://github.com/rikonaka>`_
|
||||
- `Rizlas <https://github.com/rizlas>`_
|
||||
@@ -79,6 +99,7 @@ The following wonderful people contributed directly or indirectly to this projec
|
||||
- `sooyhwang <https://github.com/sooyhwang>`_
|
||||
- `syntx <https://github.com/syntx>`_
|
||||
- `thodnev <https://github.com/thodnev>`_
|
||||
- `Timur Kushukov <https://github.com/timqsh>`_
|
||||
- `Trainer Jono <https://github.com/Tr-Jono>`_
|
||||
- `Valentijn <https://github.com/Faalentijn>`_
|
||||
- `voider1 <https://github.com/voider1>`_
|
||||
|
||||
+445
@@ -2,6 +2,451 @@
|
||||
Changelog
|
||||
=========
|
||||
|
||||
Version 13.6
|
||||
============
|
||||
*Released 2021-06-06*
|
||||
|
||||
New Features:
|
||||
|
||||
- Arbitrary ``callback_data`` (`#1844`_)
|
||||
- Add ``ContextTypes`` & ``BasePersistence.refresh_user/chat/bot_data`` (`#2262`_)
|
||||
- Add ``Filters.attachment`` (`#2528`_)
|
||||
- Add ``pattern`` Argument to ``ChosenInlineResultHandler`` (`#2517`_)
|
||||
|
||||
Major Changes:
|
||||
|
||||
- Add ``slots`` (`#2345`_)
|
||||
|
||||
Minor changes, CI improvements, Doc fixes and Type hinting:
|
||||
|
||||
- Doc Fixes (`#2495`_, `#2510`_)
|
||||
- Add ``max_connections`` Parameter to ``Updater.start_webhook`` (`#2547`_)
|
||||
- Fix for ``Promise.done_callback`` (`#2544`_)
|
||||
- Improve Code Quality (`#2536`_, `#2454`_)
|
||||
- Increase Test Coverage of ``CallbackQueryHandler`` (`#2520`_)
|
||||
- Stabilize CI (`#2522`_, `#2537`_, `#2541`_)
|
||||
- Fix ``send_phone_number_to_provider`` argument for ``Bot.send_invoice`` (`#2527`_)
|
||||
- Handle Classes as Input for ``BasePersistence.replace/insert_bot`` (`#2523`_)
|
||||
- Bump Tornado Version and Remove Workaround from `#2067`_ (`#2494`_)
|
||||
|
||||
.. _`#1844`: https://github.com/python-telegram-bot/python-telegram-bot/pull/1844
|
||||
.. _`#2262`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2262
|
||||
.. _`#2528`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2528
|
||||
.. _`#2517`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2517
|
||||
.. _`#2345`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2345
|
||||
.. _`#2495`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2495
|
||||
.. _`#2547`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2547
|
||||
.. _`#2544`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2544
|
||||
.. _`#2536`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2536
|
||||
.. _`#2454`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2454
|
||||
.. _`#2520`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2520
|
||||
.. _`#2522`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2522
|
||||
.. _`#2537`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2537
|
||||
.. _`#2541`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2541
|
||||
.. _`#2527`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2527
|
||||
.. _`#2523`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2523
|
||||
.. _`#2067`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2067
|
||||
.. _`#2494`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2494
|
||||
.. _`#2510`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2510
|
||||
|
||||
Version 13.5
|
||||
============
|
||||
*Released 2021-04-30*
|
||||
|
||||
**Major Changes:**
|
||||
|
||||
- Full support of Bot API 5.2 (`#2489`_).
|
||||
|
||||
.. note::
|
||||
The ``start_parameter`` argument of ``Bot.send_invoice`` and the corresponding shortcuts is now optional, so the order of
|
||||
parameters had to be changed. Make sure to update your method calls accordingly.
|
||||
|
||||
- Update ``ChatActions``, Deprecating ``ChatAction.RECORD_AUDIO`` and ``ChatAction.UPLOAD_AUDIO`` (`#2460`_)
|
||||
|
||||
**New Features:**
|
||||
|
||||
- Convenience Utilities & Example for Handling ``ChatMemberUpdated`` (`#2490`_)
|
||||
- ``Filters.forwarded_from`` (`#2446`_)
|
||||
|
||||
**Minor changes, CI improvements, Doc fixes and Type hinting:**
|
||||
|
||||
- Improve Timeouts in ``ConversationHandler`` (`#2417`_)
|
||||
- Stabilize CI (`#2480`_)
|
||||
- Doc Fixes (`#2437`_)
|
||||
- Improve Type Hints of Data Filters (`#2456`_)
|
||||
- Add Two ``UserWarnings`` (`#2464`_)
|
||||
- Improve Code Quality (`#2450`_)
|
||||
- Update Fallback Test-Bots (`#2451`_)
|
||||
- Improve Examples (`#2441`_, `#2448`_)
|
||||
|
||||
.. _`#2489`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2489
|
||||
.. _`#2460`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2460
|
||||
.. _`#2490`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2490
|
||||
.. _`#2446`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2446
|
||||
.. _`#2417`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2417
|
||||
.. _`#2480`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2480
|
||||
.. _`#2437`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2437
|
||||
.. _`#2456`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2456
|
||||
.. _`#2464`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2464
|
||||
.. _`#2450`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2450
|
||||
.. _`#2451`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2451
|
||||
.. _`#2441`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2441
|
||||
.. _`#2448`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2448
|
||||
|
||||
Version 13.4.1
|
||||
==============
|
||||
*Released 2021-03-14*
|
||||
|
||||
**Hot fix release:**
|
||||
|
||||
- Fixed a bug in ``setup.py`` (`#2431`_)
|
||||
|
||||
.. _`#2431`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2431
|
||||
|
||||
Version 13.4
|
||||
============
|
||||
*Released 2021-03-14*
|
||||
|
||||
**Major Changes:**
|
||||
|
||||
- Full support of Bot API 5.1 (`#2424`_)
|
||||
|
||||
**Minor changes, CI improvements, doc fixes and type hinting:**
|
||||
|
||||
- Improve ``Updater.set_webhook`` (`#2419`_)
|
||||
- Doc Fixes (`#2404`_)
|
||||
- Type Hinting Fixes (`#2425`_)
|
||||
- Update ``pre-commit`` Settings (`#2415`_)
|
||||
- Fix Logging for Vendored ``urllib3`` (`#2427`_)
|
||||
- Stabilize Tests (`#2409`_)
|
||||
|
||||
.. _`#2424`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2424
|
||||
.. _`#2419`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2419
|
||||
.. _`#2404`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2404
|
||||
.. _`#2425`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2425
|
||||
.. _`#2415`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2415
|
||||
.. _`#2427`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2427
|
||||
.. _`#2409`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2409
|
||||
|
||||
Version 13.3
|
||||
============
|
||||
*Released 2021-02-19*
|
||||
|
||||
**Major Changes:**
|
||||
|
||||
- Make ``cryptography`` Dependency Optional & Refactor Some Tests (`#2386`_, `#2370`_)
|
||||
- Deprecate ``MessageQueue`` (`#2393`_)
|
||||
|
||||
**Bug Fixes:**
|
||||
|
||||
- Refactor ``Defaults`` Integration (`#2363`_)
|
||||
- Add Missing ``telegram.SecureValue`` to init and Docs (`#2398`_)
|
||||
|
||||
**Minor changes:**
|
||||
|
||||
- Doc Fixes (`#2359`_)
|
||||
|
||||
.. _`#2386`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2386
|
||||
.. _`#2370`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2370
|
||||
.. _`#2393`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2393
|
||||
.. _`#2363`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2363
|
||||
.. _`#2398`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2398
|
||||
.. _`#2359`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2359
|
||||
|
||||
Version 13.2
|
||||
============
|
||||
*Released 2021-02-02*
|
||||
|
||||
**Major Changes:**
|
||||
|
||||
- Introduce ``python-telegram-bot-raw`` (`#2324`_)
|
||||
- Explicit Signatures for Shortcuts (`#2240`_)
|
||||
|
||||
**New Features:**
|
||||
|
||||
- Add Missing Shortcuts to ``Message`` (`#2330`_)
|
||||
- Rich Comparison for ``Bot`` (`#2320`_)
|
||||
- Add ``run_async`` Parameter to ``ConversationHandler`` (`#2292`_)
|
||||
- Add New Shortcuts to ``Chat`` (`#2291`_)
|
||||
- Add New Constant ``MAX_ANSWER_CALLBACK_QUERY_TEXT_LENGTH`` (`#2282`_)
|
||||
- Allow Passing Custom Filename For All Media (`#2249`_)
|
||||
- Handle Bytes as File Input (`#2233`_)
|
||||
|
||||
**Bug Fixes:**
|
||||
|
||||
- Fix Escaping in Nested Entities in ``Message`` Properties (`#2312`_)
|
||||
- Adjust Calling of ``Dispatcher.update_persistence`` (`#2285`_)
|
||||
- Add ``quote`` kwarg to ``Message.reply_copy`` (`#2232`_)
|
||||
- ``ConversationHandler``: Docs & ``edited_channel_post`` behavior (`#2339`_)
|
||||
|
||||
**Minor changes, CI improvements, doc fixes and type hinting:**
|
||||
|
||||
- Doc Fixes (`#2253`_, `#2225`_)
|
||||
- Reduce Usage of ``typing.Any`` (`#2321`_)
|
||||
- Extend Deeplinking Example (`#2335`_)
|
||||
- Add pyupgrade to pre-commit Hooks (`#2301`_)
|
||||
- Add PR Template (`#2299`_)
|
||||
- Drop Nightly Tests & Update Badges (`#2323`_)
|
||||
- Update Copyright (`#2289`_, `#2287`_)
|
||||
- Change Order of Class DocStrings (`#2256`_)
|
||||
- Add macOS to Test Matrix (`#2266`_)
|
||||
- Start Using Versioning Directives in Docs (`#2252`_)
|
||||
- Improve Annotations & Docs of Handlers (`#2243`_)
|
||||
|
||||
.. _`#2324`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2324
|
||||
.. _`#2240`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2240
|
||||
.. _`#2330`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2330
|
||||
.. _`#2320`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2320
|
||||
.. _`#2292`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2292
|
||||
.. _`#2291`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2291
|
||||
.. _`#2282`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2282
|
||||
.. _`#2249`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2249
|
||||
.. _`#2233`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2233
|
||||
.. _`#2312`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2312
|
||||
.. _`#2285`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2285
|
||||
.. _`#2232`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2232
|
||||
.. _`#2339`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2339
|
||||
.. _`#2253`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2253
|
||||
.. _`#2225`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2225
|
||||
.. _`#2321`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2321
|
||||
.. _`#2335`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2335
|
||||
.. _`#2301`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2301
|
||||
.. _`#2299`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2299
|
||||
.. _`#2323`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2323
|
||||
.. _`#2289`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2289
|
||||
.. _`#2287`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2287
|
||||
.. _`#2256`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2256
|
||||
.. _`#2266`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2266
|
||||
.. _`#2252`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2252
|
||||
.. _`#2243`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2243
|
||||
|
||||
Version 13.1
|
||||
============
|
||||
*Released 2020-11-29*
|
||||
|
||||
**Major Changes:**
|
||||
|
||||
- Full support of Bot API 5.0 (`#2181`_, `#2186`_, `#2190`_, `#2189`_, `#2183`_, `#2184`_, `#2188`_, `#2185`_, `#2192`_, `#2196`_, `#2193`_, `#2223`_, `#2199`_, `#2187`_, `#2147`_, `#2205`_)
|
||||
|
||||
**New Features:**
|
||||
|
||||
- Add ``Defaults.run_async`` (`#2210`_)
|
||||
- Improve and Expand ``CallbackQuery`` Shortcuts (`#2172`_)
|
||||
- Add XOR Filters and make ``Filters.name`` a Property (`#2179`_)
|
||||
- Add ``Filters.document.file_extension`` (`#2169`_)
|
||||
- Add ``Filters.caption_regex`` (`#2163`_)
|
||||
- Add ``Filters.chat_type`` (`#2128`_)
|
||||
- Handle Non-Binary File Input (`#2202`_)
|
||||
|
||||
**Bug Fixes:**
|
||||
|
||||
- Improve Handling of Custom Objects in ``BasePersistence.insert``/``replace_bot`` (`#2151`_)
|
||||
- Fix bugs in ``replace/insert_bot`` (`#2218`_)
|
||||
|
||||
**Minor changes, CI improvements, doc fixes and type hinting:**
|
||||
|
||||
- Improve Type hinting (`#2204`_, `#2118`_, `#2167`_, `#2136`_)
|
||||
- Doc Fixes & Extensions (`#2201`_, `#2161`_)
|
||||
- Use F-Strings Where Possible (`#2222`_)
|
||||
- Rename kwargs to _kwargs where possible (`#2182`_)
|
||||
- Comply with PEP561 (`#2168`_)
|
||||
- Improve Code Quality (`#2131`_)
|
||||
- Switch Code Formatting to Black (`#2122`_, `#2159`_, `#2158`_)
|
||||
- Update Wheel Settings (`#2142`_)
|
||||
- Update ``timerbot.py`` to ``v13.0`` (`#2149`_)
|
||||
- Overhaul Constants (`#2137`_)
|
||||
- Add Python 3.9 to Test Matrix (`#2132`_)
|
||||
- Switch Codecov to ``GitHub`` Action (`#2127`_)
|
||||
- Specify Required pytz Version (`#2121`_)
|
||||
|
||||
|
||||
.. _`#2181`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2181
|
||||
.. _`#2186`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2186
|
||||
.. _`#2190`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2190
|
||||
.. _`#2189`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2189
|
||||
.. _`#2183`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2183
|
||||
.. _`#2184`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2184
|
||||
.. _`#2188`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2188
|
||||
.. _`#2185`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2185
|
||||
.. _`#2192`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2192
|
||||
.. _`#2196`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2196
|
||||
.. _`#2193`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2193
|
||||
.. _`#2223`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2223
|
||||
.. _`#2199`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2199
|
||||
.. _`#2187`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2187
|
||||
.. _`#2147`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2147
|
||||
.. _`#2205`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2205
|
||||
.. _`#2210`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2210
|
||||
.. _`#2172`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2172
|
||||
.. _`#2179`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2179
|
||||
.. _`#2169`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2169
|
||||
.. _`#2163`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2163
|
||||
.. _`#2128`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2128
|
||||
.. _`#2202`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2202
|
||||
.. _`#2151`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2151
|
||||
.. _`#2218`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2218
|
||||
.. _`#2204`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2204
|
||||
.. _`#2118`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2118
|
||||
.. _`#2167`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2167
|
||||
.. _`#2136`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2136
|
||||
.. _`#2201`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2201
|
||||
.. _`#2161`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2161
|
||||
.. _`#2222`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2222
|
||||
.. _`#2182`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2182
|
||||
.. _`#2168`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2168
|
||||
.. _`#2131`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2131
|
||||
.. _`#2122`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2122
|
||||
.. _`#2159`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2159
|
||||
.. _`#2158`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2158
|
||||
.. _`#2142`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2142
|
||||
.. _`#2149`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2149
|
||||
.. _`#2137`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2137
|
||||
.. _`#2132`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2132
|
||||
.. _`#2127`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2127
|
||||
.. _`#2121`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2121
|
||||
|
||||
Version 13.0
|
||||
============
|
||||
*Released 2020-10-07*
|
||||
|
||||
**For a detailed guide on how to migrate from v12 to v13, see this** `wiki page <https://github.com/python-telegram-bot/python-telegram-bot/wiki/Transition-guide-to-Version-13.0>`_.
|
||||
|
||||
**Major Changes:**
|
||||
|
||||
- Deprecate old-style callbacks, i.e. set ``use_context=True`` by default (`#2050`_)
|
||||
- Refactor Handling of Message VS Update Filters (`#2032`_)
|
||||
- Deprecate ``Message.default_quote`` (`#1965`_)
|
||||
- Refactor persistence of Bot instances (`#1994`_)
|
||||
- Refactor ``JobQueue`` (`#1981`_)
|
||||
- Refactor handling of kwargs in Bot methods (`#1924`_)
|
||||
- Refactor ``Dispatcher.run_async``, deprecating the ``@run_async`` decorator (`#2051`_)
|
||||
|
||||
**New Features:**
|
||||
|
||||
- Type Hinting (`#1920`_)
|
||||
- Automatic Pagination for ``answer_inline_query`` (`#2072`_)
|
||||
- ``Defaults.tzinfo`` (`#2042`_)
|
||||
- Extend rich comparison of objects (`#1724`_)
|
||||
- Add ``Filters.via_bot`` (`#2009`_)
|
||||
- Add missing shortcuts (`#2043`_)
|
||||
- Allow ``DispatcherHandlerStop`` in ``ConversationHandler`` (`#2059`_)
|
||||
- Make Errors picklable (`#2106`_)
|
||||
|
||||
**Minor changes, CI improvements, doc fixes or bug fixes:**
|
||||
|
||||
- Fix Webhook not working on Windows with Python 3.8+ (`#2067`_)
|
||||
- Fix setting thumbs with ``send_media_group`` (`#2093`_)
|
||||
- Make ``MessageHandler`` filter for ``Filters.update`` first (`#2085`_)
|
||||
- Fix ``PicklePersistence.flush()`` with only ``bot_data`` (`#2017`_)
|
||||
- Add test for clean argument of ``Updater.start_polling/webhook`` (`#2002`_)
|
||||
- Doc fixes, refinements and additions (`#2005`_, `#2008`_, `#2089`_, `#2094`_, `#2090`_)
|
||||
- CI fixes (`#2018`_, `#2061`_)
|
||||
- Refine ``pollbot.py`` example (`#2047`_)
|
||||
- Refine Filters in examples (`#2027`_)
|
||||
- Rename ``echobot`` examples (`#2025`_)
|
||||
- Use Lock-Bot to lock old threads (`#2048`_, `#2052`_, `#2049`_, `#2053`_)
|
||||
|
||||
.. _`#2050`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2050
|
||||
.. _`#2032`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2032
|
||||
.. _`#1965`: https://github.com/python-telegram-bot/python-telegram-bot/pull/1965
|
||||
.. _`#1994`: https://github.com/python-telegram-bot/python-telegram-bot/pull/1994
|
||||
.. _`#1981`: https://github.com/python-telegram-bot/python-telegram-bot/pull/1981
|
||||
.. _`#1924`: https://github.com/python-telegram-bot/python-telegram-bot/pull/1924
|
||||
.. _`#2051`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2051
|
||||
.. _`#1920`: https://github.com/python-telegram-bot/python-telegram-bot/pull/1920
|
||||
.. _`#2072`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2072
|
||||
.. _`#2042`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2042
|
||||
.. _`#1724`: https://github.com/python-telegram-bot/python-telegram-bot/pull/1724
|
||||
.. _`#2009`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2009
|
||||
.. _`#2043`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2043
|
||||
.. _`#2059`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2059
|
||||
.. _`#2106`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2106
|
||||
.. _`#2067`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2067
|
||||
.. _`#2093`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2093
|
||||
.. _`#2085`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2085
|
||||
.. _`#2017`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2017
|
||||
.. _`#2002`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2002
|
||||
.. _`#2005`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2005
|
||||
.. _`#2008`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2008
|
||||
.. _`#2089`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2089
|
||||
.. _`#2094`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2094
|
||||
.. _`#2090`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2090
|
||||
.. _`#2018`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2018
|
||||
.. _`#2061`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2061
|
||||
.. _`#2047`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2047
|
||||
.. _`#2027`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2027
|
||||
.. _`#2025`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2025
|
||||
.. _`#2048`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2048
|
||||
.. _`#2052`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2052
|
||||
.. _`#2049`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2049
|
||||
.. _`#2053`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2053
|
||||
|
||||
Version 12.8
|
||||
============
|
||||
*Released 2020-06-22*
|
||||
|
||||
**Major Changes:**
|
||||
|
||||
- Remove Python 2 support (`#1715`_)
|
||||
- Bot API 4.9 support (`#1980`_)
|
||||
- IDs/Usernames of ``Filters.user`` and ``Filters.chat`` can now be updated (`#1757`_)
|
||||
|
||||
**Minor changes, CI improvements, doc fixes or bug fixes:**
|
||||
|
||||
- Update contribution guide and stale bot (`#1937`_)
|
||||
- Remove ``NullHandlers`` (`#1913`_)
|
||||
- Improve and expand examples (`#1943`_, `#1995`_, `#1983`_, `#1997`_)
|
||||
- Doc fixes (`#1940`_, `#1962`_)
|
||||
- Add ``User.send_poll()`` shortcut (`#1968`_)
|
||||
- Ignore private attributes en ``TelegramObject.to_dict()`` (`#1989`_)
|
||||
- Stabilize CI (`#2000`_)
|
||||
|
||||
.. _`#1937`: https://github.com/python-telegram-bot/python-telegram-bot/pull/1937
|
||||
.. _`#1913`: https://github.com/python-telegram-bot/python-telegram-bot/pull/1913
|
||||
.. _`#1943`: https://github.com/python-telegram-bot/python-telegram-bot/pull/1943
|
||||
.. _`#1757`: https://github.com/python-telegram-bot/python-telegram-bot/pull/1757
|
||||
.. _`#1940`: https://github.com/python-telegram-bot/python-telegram-bot/pull/1940
|
||||
.. _`#1962`: https://github.com/python-telegram-bot/python-telegram-bot/pull/1962
|
||||
.. _`#1968`: https://github.com/python-telegram-bot/python-telegram-bot/pull/1968
|
||||
.. _`#1989`: https://github.com/python-telegram-bot/python-telegram-bot/pull/1989
|
||||
.. _`#1995`: https://github.com/python-telegram-bot/python-telegram-bot/pull/1995
|
||||
.. _`#1983`: https://github.com/python-telegram-bot/python-telegram-bot/pull/1983
|
||||
.. _`#1715`: https://github.com/python-telegram-bot/python-telegram-bot/pull/1715
|
||||
.. _`#2000`: https://github.com/python-telegram-bot/python-telegram-bot/pull/2000
|
||||
.. _`#1997`: https://github.com/python-telegram-bot/python-telegram-bot/pull/1997
|
||||
.. _`#1980`: https://github.com/python-telegram-bot/python-telegram-bot/pull/1980
|
||||
|
||||
Version 12.7
|
||||
============
|
||||
*Released 2020-05-02*
|
||||
|
||||
**Major Changes:**
|
||||
|
||||
- Bot API 4.8 support. **Note:** The ``Dice`` object now has a second positional argument ``emoji``. This is relevant, if you instantiate ``Dice`` objects manually. (`#1917`_)
|
||||
- Added ``tzinfo`` argument to ``helpers.from_timestamp``. It now returns an timezone aware object. This is relevant for ``Message.{date,forward_date,edit_date}``, ``Poll.close_date`` and ``ChatMember.until_date`` (`#1621`_)
|
||||
|
||||
**New Features:**
|
||||
|
||||
- New method ``run_monthly`` for the ``JobQueue`` (`#1705`_)
|
||||
- ``Job.next_t`` now gives the datetime of the jobs next execution (`#1685`_)
|
||||
|
||||
**Minor changes, CI improvements, doc fixes or bug fixes:**
|
||||
|
||||
- Stabalize CI (`#1919`_, `#1931`_)
|
||||
- Use ABCs ``@abstractmethod`` instead of raising ``NotImplementedError`` for ``Handler``, ``BasePersistence`` and ``BaseFilter`` (`#1905`_)
|
||||
- Doc fixes (`#1914`_, `#1902`_, `#1910`_)
|
||||
|
||||
.. _`#1902`: https://github.com/python-telegram-bot/python-telegram-bot/pull/1902
|
||||
.. _`#1685`: https://github.com/python-telegram-bot/python-telegram-bot/pull/1685
|
||||
.. _`#1910`: https://github.com/python-telegram-bot/python-telegram-bot/pull/1910
|
||||
.. _`#1914`: https://github.com/python-telegram-bot/python-telegram-bot/pull/1914
|
||||
.. _`#1931`: https://github.com/python-telegram-bot/python-telegram-bot/pull/1931
|
||||
.. _`#1905`: https://github.com/python-telegram-bot/python-telegram-bot/pull/1905
|
||||
.. _`#1919`: https://github.com/python-telegram-bot/python-telegram-bot/pull/1919
|
||||
.. _`#1621`: https://github.com/python-telegram-bot/python-telegram-bot/pull/1621
|
||||
.. _`#1705`: https://github.com/python-telegram-bot/python-telegram-bot/pull/1705
|
||||
.. _`#1917`: https://github.com/python-telegram-bot/python-telegram-bot/pull/1917
|
||||
|
||||
Version 12.6.1
|
||||
==============
|
||||
*Released 2020-04-11*
|
||||
|
||||
+1
-1
@@ -1 +1 @@
|
||||
include LICENSE LICENSE.lesser Makefile requirements.txt
|
||||
include LICENSE LICENSE.lesser Makefile requirements.txt README_RAW.rst telegram/py.typed
|
||||
|
||||
@@ -1,52 +0,0 @@
|
||||
.DEFAULT_GOAL := help
|
||||
.PHONY: clean pep257 pep8 yapf lint test install
|
||||
|
||||
PYLINT := pylint
|
||||
PYTEST := pytest
|
||||
PEP257 := pep257
|
||||
PEP8 := flake8
|
||||
YAPF := yapf
|
||||
PIP := pip
|
||||
|
||||
clean:
|
||||
rm -fr build
|
||||
rm -fr dist
|
||||
find . -name '*.pyc' -exec rm -f {} \;
|
||||
find . -name '*.pyo' -exec rm -f {} \;
|
||||
find . -name '*~' -exec rm -f {} \;
|
||||
find . -regex "./telegram.\(mp3\|mp4\|ogg\|png\|webp\)" -exec rm {} \;
|
||||
|
||||
pep257:
|
||||
$(PEP257) telegram
|
||||
|
||||
pep8:
|
||||
$(PEP8) telegram
|
||||
|
||||
yapf:
|
||||
$(YAPF) -r telegram
|
||||
|
||||
lint:
|
||||
$(PYLINT) -E telegram --disable=no-name-in-module,import-error
|
||||
|
||||
test:
|
||||
$(PYTEST) -v
|
||||
|
||||
install:
|
||||
$(PIP) install -r requirements.txt -r requirements-dev.txt
|
||||
|
||||
help:
|
||||
@echo "Available targets:"
|
||||
@echo "- clean Clean up the source directory"
|
||||
@echo "- pep257 Check docstring style with pep257"
|
||||
@echo "- pep8 Check style with flake8"
|
||||
@echo "- lint Check style with pylint"
|
||||
@echo "- yapf Check style with yapf"
|
||||
@echo "- test Run tests using pytest"
|
||||
@echo
|
||||
@echo "Available variables:"
|
||||
@echo "- PYLINT default: $(PYLINT)"
|
||||
@echo "- PYTEST default: $(PYTEST)"
|
||||
@echo "- PEP257 default: $(PEP257)"
|
||||
@echo "- PEP8 default: $(PEP8)"
|
||||
@echo "- YAPF default: $(YAPF)"
|
||||
@echo "- PIP default: $(PIP)"
|
||||
+49
-17
@@ -1,3 +1,6 @@
|
||||
..
|
||||
Make user to apply any changes to this file to README_RAW.rst as well!
|
||||
|
||||
.. image:: https://github.com/python-telegram-bot/logos/blob/master/logo-text/png/ptb-logo-text_768.png?raw=true
|
||||
:align: center
|
||||
:target: https://python-telegram-bot.org
|
||||
@@ -17,42 +20,49 @@ We have a vibrant community of developers helping each other in our `Telegram gr
|
||||
:target: https://pypi.org/project/python-telegram-bot/
|
||||
:alt: Supported Python versions
|
||||
|
||||
.. image:: https://www.cpu.re/static/python-telegram-bot/downloads.svg
|
||||
:target: https://www.cpu.re/static/python-telegram-bot/downloads-by-python-version.txt
|
||||
.. image:: https://img.shields.io/badge/Bot%20API-5.2-blue?logo=telegram
|
||||
:target: https://core.telegram.org/bots/api-changelog
|
||||
:alt: Supported Bot API versions
|
||||
|
||||
.. image:: https://img.shields.io/pypi/dm/python-telegram-bot
|
||||
:target: https://pypistats.org/packages/python-telegram-bot
|
||||
:alt: PyPi Package Monthly Download
|
||||
|
||||
.. image:: https://img.shields.io/badge/docs-latest-af1a97.svg
|
||||
:target: https://python-telegram-bot.readthedocs.io/
|
||||
.. image:: https://readthedocs.org/projects/python-telegram-bot/badge/?version=stable
|
||||
:target: https://python-telegram-bot.readthedocs.io/en/stable/?badge=stable
|
||||
:alt: Documentation Status
|
||||
|
||||
.. image:: https://img.shields.io/pypi/l/python-telegram-bot.svg
|
||||
:target: https://www.gnu.org/licenses/lgpl-3.0.html
|
||||
:alt: LGPLv3 License
|
||||
|
||||
.. image:: https://github.com/python-telegram-bot/python-telegram-bot/workflows/GitHub%20Actions/badge.svg?event=schedule
|
||||
.. image:: https://github.com/python-telegram-bot/python-telegram-bot/workflows/GitHub%20Actions/badge.svg
|
||||
:target: https://github.com/python-telegram-bot/python-telegram-bot/
|
||||
:alt: Github Actions workflow
|
||||
|
||||
.. image:: https://codecov.io/gh/python-telegram-bot/python-telegram-bot/branch/master/graph/badge.svg
|
||||
:target: https://codecov.io/gh/python-telegram-bot/python-telegram-bot
|
||||
:alt: Code coverage
|
||||
|
||||
|
||||
.. image:: http://isitmaintained.com/badge/resolution/python-telegram-bot/python-telegram-bot.svg
|
||||
:target: http://isitmaintained.com/project/python-telegram-bot/python-telegram-bot
|
||||
:alt: Median time to resolve an issue
|
||||
|
||||
.. image:: https://api.codacy.com/project/badge/Grade/99d901eaa09b44b4819aec05c330c968
|
||||
:target: https://www.codacy.com/app/python-telegram-bot/python-telegram-bot?utm_source=github.com&utm_medium=referral&utm_content=python-telegram-bot/python-telegram-bot&utm_campaign=Badge_Grade
|
||||
:alt: Code quality
|
||||
:alt: Code quality: Codacy
|
||||
|
||||
.. image:: https://img.shields.io/badge/Telegram-Group-blue.svg
|
||||
.. image:: https://deepsource.io/gh/python-telegram-bot/python-telegram-bot.svg/?label=active+issues
|
||||
:target: https://deepsource.io/gh/python-telegram-bot/python-telegram-bot/?ref=repository-badge
|
||||
:alt: Code quality: DeepSource
|
||||
|
||||
.. image:: https://img.shields.io/badge/code%20style-black-000000.svg
|
||||
:target: https://github.com/psf/black
|
||||
|
||||
.. image:: https://img.shields.io/badge/Telegram-Group-blue.svg?logo=telegram
|
||||
:target: https://telegram.me/pythontelegrambotgroup
|
||||
:alt: Telegram Group
|
||||
|
||||
.. image:: https://img.shields.io/badge/IRC-Channel-blue.svg
|
||||
:target: https://webchat.freenode.net/?channels=##python-telegram-bot
|
||||
:alt: IRC Bridge
|
||||
|
||||
=================
|
||||
Table of contents
|
||||
=================
|
||||
@@ -83,17 +93,25 @@ Introduction
|
||||
|
||||
This library provides a pure Python interface for the
|
||||
`Telegram Bot API <https://core.telegram.org/bots/api>`_.
|
||||
It's compatible with Python versions 3.5+ and `PyPy <http://pypy.org/>`_.
|
||||
It's compatible with Python versions 3.6.2+. PTB might also work on `PyPy <http://pypy.org/>`_, though there have been a lot of issues before. Hence, PyPy is not officially supported.
|
||||
|
||||
In addition to the pure API implementation, this library features a number of high-level classes to
|
||||
make the development of bots easy and straightforward. These classes are contained in the
|
||||
``telegram.ext`` submodule.
|
||||
|
||||
A pure API implementation *without* ``telegram.ext`` is available as the standalone package ``python-telegram-bot-raw``. `See here for details. <https://github.com/python-telegram-bot/python-telegram-bot/blob/master/README_RAW.rst>`_
|
||||
|
||||
----
|
||||
Note
|
||||
----
|
||||
|
||||
Installing both ``python-telegram-bot`` and ``python-telegram-bot-raw`` in conjunction will result in undesired side-effects, so only install *one* of both.
|
||||
|
||||
====================
|
||||
Telegram API support
|
||||
====================
|
||||
|
||||
All types and methods of the Telegram Bot API **4.7** are supported.
|
||||
All types and methods of the Telegram Bot API **5.2** are supported.
|
||||
|
||||
==========
|
||||
Installing
|
||||
@@ -119,6 +137,16 @@ In case you have a previously cloned local repository already, you should initia
|
||||
|
||||
$ git submodule update --init --recursive
|
||||
|
||||
---------------------
|
||||
Optional Dependencies
|
||||
---------------------
|
||||
|
||||
PTB can be installed with optional dependencies:
|
||||
|
||||
* ``pip install python-telegram-bot[passport]`` installs the `cryptography <https://cryptography.io>`_ library. Use this, if you want to use Telegram Passport related functionality.
|
||||
* ``pip install python-telegram-bot[ujson]`` installs the `ujson <https://pypi.org/project/ujson/>`_ library. It will then be used for JSON de- & encoding, which can bring speed up compared to the standard `json <https://docs.python.org/3/library/json.html>`_ library.
|
||||
* ``pip install python-telegram-bot[socks]`` installs the `PySocks <https://pypi.org/project/PySocks/>`_ library. Use this, if you want to work behind a Socks5 server.
|
||||
|
||||
===============
|
||||
Getting started
|
||||
===============
|
||||
@@ -139,7 +167,7 @@ Learning by example
|
||||
|
||||
We believe that the best way to learn this package is by example. Here
|
||||
are some examples for you to review. Even if it is not your approach for learning, please take a
|
||||
look at ``echobot2``, it is the de facto base for most of the bots out there. Best of all,
|
||||
look at ``echobot.py``, it is the de facto base for most of the bots out there. Best of all,
|
||||
the code for these examples are released to the public domain, so you can start by grabbing the
|
||||
code and building on top of it.
|
||||
|
||||
@@ -187,20 +215,24 @@ You can get help in several ways:
|
||||
|
||||
1. We have a vibrant community of developers helping each other in our `Telegram group <https://telegram.me/pythontelegrambotgroup>`_. Join us!
|
||||
|
||||
2. Report bugs, request new features or ask questions by `creating an issue <https://github.com/python-telegram-bot/python-telegram-bot/issues/new/choose>`_.
|
||||
2. Report bugs, request new features or ask questions by `creating an issue <https://github.com/python-telegram-bot/python-telegram-bot/issues/new/choose>`_ or `a discussion <https://github.com/python-telegram-bot/python-telegram-bot/discussions/new>`_.
|
||||
|
||||
3. Our `Wiki pages <https://github.com/python-telegram-bot/python-telegram-bot/wiki/>`_ offer a growing amount of resources.
|
||||
|
||||
4. You can even ask for help on Stack Overflow using the `python-telegram-bot tag <https://stackoverflow.com/questions/tagged/python-telegram-bot>`_.
|
||||
|
||||
|
||||
|
||||
============
|
||||
Contributing
|
||||
============
|
||||
|
||||
Contributions of all sizes are welcome. Please review our `contribution guidelines <https://github.com/python-telegram-bot/python-telegram-bot/blob/master/.github/CONTRIBUTING.rst>`_ to get started. You can also help by `reporting bugs <https://github.com/python-telegram-bot/python-telegram-bot/issues/new>`_.
|
||||
|
||||
========
|
||||
Donating
|
||||
========
|
||||
Occasionally we are asked if we accept donations to support the development. While we appreciate the thought, maintaining PTB is our hobby and we have almost no running costs for it. We therefore have nothing set up to accept donations. If you still want to donate, we kindly ask you to donate to another open source project/initiative of your choice instead.
|
||||
|
||||
=======
|
||||
License
|
||||
=======
|
||||
|
||||
+222
@@ -0,0 +1,222 @@
|
||||
..
|
||||
Make user to apply any changes to this file to README.rst as well!
|
||||
|
||||
.. image:: https://github.com/python-telegram-bot/logos/blob/master/logo-text/png/ptb-raw-logo-text_768.png?raw=true
|
||||
:align: center
|
||||
:target: https://python-telegram-bot.org
|
||||
:alt: python-telegram-bot-raw Logo
|
||||
|
||||
We have made you a wrapper you can't refuse
|
||||
|
||||
We have a vibrant community of developers helping each other in our `Telegram group <https://telegram.me/pythontelegrambotgroup>`_. Join us!
|
||||
|
||||
*Stay tuned for library updates and new releases on our* `Telegram Channel <https://telegram.me/pythontelegrambotchannel>`_.
|
||||
|
||||
.. image:: https://img.shields.io/pypi/v/python-telegram-bot-raw.svg
|
||||
:target: https://pypi.org/project/python-telegram-bot-raw/
|
||||
:alt: PyPi Package Version
|
||||
|
||||
.. image:: https://img.shields.io/pypi/pyversions/python-telegram-bot-raw.svg
|
||||
:target: https://pypi.org/project/python-telegram-bot-raw/
|
||||
:alt: Supported Python versions
|
||||
|
||||
.. image:: https://img.shields.io/badge/Bot%20API-5.2-blue?logo=telegram
|
||||
:target: https://core.telegram.org/bots/api-changelog
|
||||
:alt: Supported Bot API versions
|
||||
|
||||
.. image:: https://img.shields.io/pypi/dm/python-telegram-bot-raw
|
||||
:target: https://pypistats.org/packages/python-telegram-bot-raw
|
||||
:alt: PyPi Package Monthly Download
|
||||
|
||||
.. image:: https://readthedocs.org/projects/python-telegram-bot/badge/?version=stable
|
||||
:target: https://python-telegram-bot.readthedocs.io/
|
||||
:alt: Documentation Status
|
||||
|
||||
.. image:: https://img.shields.io/pypi/l/python-telegram-bot-raw.svg
|
||||
:target: https://www.gnu.org/licenses/lgpl-3.0.html
|
||||
:alt: LGPLv3 License
|
||||
|
||||
.. image:: https://github.com/python-telegram-bot/python-telegram-bot/workflows/GitHub%20Actions/badge.svg
|
||||
:target: https://github.com/python-telegram-bot/python-telegram-bot/
|
||||
:alt: Github Actions workflow
|
||||
|
||||
.. image:: https://codecov.io/gh/python-telegram-bot/python-telegram-bot/branch/master/graph/badge.svg
|
||||
:target: https://codecov.io/gh/python-telegram-bot/python-telegram-bot
|
||||
:alt: Code coverage
|
||||
|
||||
.. image:: http://isitmaintained.com/badge/resolution/python-telegram-bot/python-telegram-bot.svg
|
||||
:target: http://isitmaintained.com/project/python-telegram-bot/python-telegram-bot
|
||||
:alt: Median time to resolve an issue
|
||||
|
||||
.. image:: https://api.codacy.com/project/badge/Grade/99d901eaa09b44b4819aec05c330c968
|
||||
:target: https://www.codacy.com/app/python-telegram-bot/python-telegram-bot?utm_source=github.com&utm_medium=referral&utm_content=python-telegram-bot/python-telegram-bot&utm_campaign=Badge_Grade
|
||||
:alt: Code quality: Codacy
|
||||
|
||||
.. image:: https://deepsource.io/gh/python-telegram-bot/python-telegram-bot.svg/?label=active+issues
|
||||
:target: https://deepsource.io/gh/python-telegram-bot/python-telegram-bot/?ref=repository-badge
|
||||
:alt: Code quality: DeepSource
|
||||
|
||||
.. image:: https://img.shields.io/badge/code%20style-black-000000.svg
|
||||
:target: https://github.com/psf/black
|
||||
|
||||
.. image:: https://img.shields.io/badge/Telegram-Group-blue.svg?logo=telegram
|
||||
:target: https://telegram.me/pythontelegrambotgroup
|
||||
:alt: Telegram Group
|
||||
|
||||
=================
|
||||
Table of contents
|
||||
=================
|
||||
|
||||
- `Introduction`_
|
||||
|
||||
- `Telegram API support`_
|
||||
|
||||
- `Installing`_
|
||||
|
||||
- `Getting started`_
|
||||
|
||||
#. `Logging`_
|
||||
|
||||
#. `Documentation`_
|
||||
|
||||
- `Getting help`_
|
||||
|
||||
- `Contributing`_
|
||||
|
||||
- `License`_
|
||||
|
||||
============
|
||||
Introduction
|
||||
============
|
||||
|
||||
This library provides a pure Python, lightweight interface for the
|
||||
`Telegram Bot API <https://core.telegram.org/bots/api>`_.
|
||||
It's compatible with Python versions 3.6.2+. PTB-Raw might also work on `PyPy <http://pypy.org/>`_, though there have been a lot of issues before. Hence, PyPy is not officially supported.
|
||||
|
||||
``python-telegram-bot-raw`` is part of the `python-telegram-bot <https://python-telegram-bot.org>`_ ecosystem and provides the pure API functionality extracted from PTB. It therefore does *not* have independent release schedules, changelogs or documentation. Please consult the PTB resources.
|
||||
|
||||
----
|
||||
Note
|
||||
----
|
||||
|
||||
Installing both ``python-telegram-bot`` and ``python-telegram-bot-raw`` in conjunction will result in undesired side-effects, so only install *one* of both.
|
||||
|
||||
====================
|
||||
Telegram API support
|
||||
====================
|
||||
|
||||
All types and methods of the Telegram Bot API **5.2** are supported.
|
||||
|
||||
==========
|
||||
Installing
|
||||
==========
|
||||
|
||||
You can install or upgrade python-telegram-bot-raw with:
|
||||
|
||||
.. code:: shell
|
||||
|
||||
$ pip install python-telegram-bot-raw --upgrade
|
||||
|
||||
Or you can install from source with:
|
||||
|
||||
.. code:: shell
|
||||
|
||||
$ git clone https://github.com/python-telegram-bot/python-telegram-bot --recursive
|
||||
$ cd python-telegram-bot
|
||||
$ python setup-raw.py install
|
||||
|
||||
In case you have a previously cloned local repository already, you should initialize the added urllib3 submodule before installing with:
|
||||
|
||||
.. code:: shell
|
||||
|
||||
$ git submodule update --init --recursive
|
||||
|
||||
----
|
||||
Note
|
||||
----
|
||||
|
||||
Installing the `.tar.gz` archive available on PyPi directly via `pip` will *not* work as expected, as `pip` does not recognize that it should use `setup-raw.py` instead of `setup.py`.
|
||||
|
||||
---------------------
|
||||
Optional Dependencies
|
||||
---------------------
|
||||
|
||||
PTB can be installed with optional dependencies:
|
||||
|
||||
* ``pip install python-telegram-bot-raw[passport]`` installs the `cryptography <https://cryptography.io>`_ library. Use this, if you want to use Telegram Passport related functionality.
|
||||
* ``pip install python-telegram-bot-raw[ujson]`` installs the `ujson <https://pypi.org/project/ujson/>`_ library. It will then be used for JSON de- & encoding, which can bring speed up compared to the standard `json <https://docs.python.org/3/library/json.html>`_ library.
|
||||
|
||||
===============
|
||||
Getting started
|
||||
===============
|
||||
|
||||
Our Wiki contains an `Introduction to the API <https://github.com/python-telegram-bot/python-telegram-bot/wiki/Introduction-to-the-API>`_. Other references are:
|
||||
|
||||
- the `Telegram API documentation <https://core.telegram.org/bots/api>`_
|
||||
- the `python-telegram-bot documentation <https://python-telegram-bot.readthedocs.io/>`_
|
||||
|
||||
-------
|
||||
Logging
|
||||
-------
|
||||
|
||||
This library uses the ``logging`` module. To set up logging to standard output, put:
|
||||
|
||||
.. code:: python
|
||||
|
||||
import logging
|
||||
logging.basicConfig(level=logging.DEBUG,
|
||||
format='%(asctime)s - %(name)s - %(levelname)s - %(message)s')
|
||||
|
||||
at the beginning of your script.
|
||||
|
||||
You can also use logs in your application by calling ``logging.getLogger()`` and setting the log level you want:
|
||||
|
||||
.. code:: python
|
||||
|
||||
logger = logging.getLogger()
|
||||
logger.setLevel(logging.INFO)
|
||||
|
||||
If you want DEBUG logs instead:
|
||||
|
||||
.. code:: python
|
||||
|
||||
logger.setLevel(logging.DEBUG)
|
||||
|
||||
|
||||
=============
|
||||
Documentation
|
||||
=============
|
||||
|
||||
``python-telegram-bot``'s documentation lives at `readthedocs.io <https://python-telegram-bot.readthedocs.io/>`_, which
|
||||
includes the relevant documentation for ``python-telegram-bot-raw``.
|
||||
|
||||
============
|
||||
Getting help
|
||||
============
|
||||
|
||||
You can get help in several ways:
|
||||
|
||||
1. We have a vibrant community of developers helping each other in our `Telegram group <https://telegram.me/pythontelegrambotgroup>`_. Join us!
|
||||
|
||||
2. Report bugs, request new features or ask questions by `creating an issue <https://github.com/python-telegram-bot/python-telegram-bot/issues/new/choose>`_ or `a discussion <https://github.com/python-telegram-bot/python-telegram-bot/discussions/new>`_.
|
||||
|
||||
3. Our `Wiki pages <https://github.com/python-telegram-bot/python-telegram-bot/wiki/>`_ offer a growing amount of resources.
|
||||
|
||||
4. You can even ask for help on Stack Overflow using the `python-telegram-bot tag <https://stackoverflow.com/questions/tagged/python-telegram-bot>`_.
|
||||
|
||||
============
|
||||
Contributing
|
||||
============
|
||||
|
||||
Contributions of all sizes are welcome. Please review our `contribution guidelines <https://github.com/python-telegram-bot/python-telegram-bot/blob/master/.github/CONTRIBUTING.rst>`_ to get started. You can also help by `reporting bugs <https://github.com/python-telegram-bot/python-telegram-bot/issues/new>`_.
|
||||
|
||||
========
|
||||
Donating
|
||||
========
|
||||
Occasionally we are asked if we accept donations to support the development. While we appreciate the thought, maintaining PTB is our hobby and we have almost no running costs for it. We therefore have nothing set up to accept donations. If you still want to donate, we kindly ask you to donate to another open source project/initiative of your choice instead.
|
||||
|
||||
=======
|
||||
License
|
||||
=======
|
||||
|
||||
You may copy, distribute and modify the software provided that modifications are described and licensed for free under `LGPL-3 <https://www.gnu.org/licenses/lgpl-3.0.html>`_. Derivatives works (including modifications or anything statically linked to the library) can only be redistributed under LGPL-3, but applications that use the library don't have to be.
|
||||
@@ -1 +1,10 @@
|
||||
comment: false
|
||||
|
||||
coverage:
|
||||
status:
|
||||
project:
|
||||
default:
|
||||
# We allow small coverage decreases in the project because we don't retry
|
||||
# on hitting flood limits, which adds noise to the coverage
|
||||
target: auto
|
||||
threshold: 0.1%
|
||||
|
||||
@@ -15,7 +15,7 @@ Depends: ${python3:Depends}, ${misc:Depends}
|
||||
Description: We have made you a wrapper you can't refuse!
|
||||
The Python Telegram bot (Python 3)
|
||||
This library provides a pure Python interface for the Telegram Bot API.
|
||||
It's compatible with Python versions 2.7, 3.3+ and PyPy.
|
||||
It's compatible with Python versions 3.5+ and PyPy.
|
||||
.
|
||||
In addition to the pure API implementation, this library features
|
||||
a number of high-level
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
export PYBUILD_NAME=telegram
|
||||
|
||||
%:
|
||||
DEB_BUILD_OPTIONS=nocheck dh $@ --with python2,python3 --buildsystem=pybuild
|
||||
DEB_BUILD_OPTIONS=nocheck dh $@ --with python3 --buildsystem=pybuild
|
||||
|
||||
|
||||
# If you need to rebuild the Sphinx documentation
|
||||
|
||||
@@ -1,3 +1,6 @@
|
||||
sphinx>=1.7.9
|
||||
sphinx_rtd_theme
|
||||
sphinx==3.5.4
|
||||
sphinx-pypi-upload
|
||||
# When bumping this, make sure to rebuild the dark-mode CSS
|
||||
# More instructions at source/_static/dark.css
|
||||
# Ofc once https://github.com/readthedocs/sphinx_rtd_theme/issues/224 is closed, we should use that
|
||||
sphinx_rtd_theme==0.5.2
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
+17
-12
@@ -13,7 +13,6 @@
|
||||
# serve to show the default.
|
||||
import sys
|
||||
import os
|
||||
import shlex
|
||||
# import telegram
|
||||
|
||||
# If extensions (or modules to document with autodoc) are in another directory,
|
||||
@@ -24,7 +23,7 @@ sys.path.insert(0, os.path.abspath('../..'))
|
||||
# -- General configuration ------------------------------------------------
|
||||
|
||||
# If your documentation needs a minimal Sphinx version, state it here.
|
||||
needs_sphinx = '1.7.9'
|
||||
needs_sphinx = '3.5.2'
|
||||
|
||||
# Add any Sphinx extension module names here, as strings. They can be
|
||||
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
|
||||
@@ -33,6 +32,9 @@ extensions = [
|
||||
'sphinx.ext.autodoc',
|
||||
'sphinx.ext.napoleon'
|
||||
]
|
||||
# Don't show type hints in the signature - that just makes it hardly readable
|
||||
# and we document the types anyway
|
||||
autodoc_typehints = 'none'
|
||||
|
||||
# Add any paths that contain templates here, relative to this directory.
|
||||
templates_path = ['_templates']
|
||||
@@ -49,8 +51,8 @@ source_suffix = '.rst'
|
||||
master_doc = 'index'
|
||||
|
||||
# General information about the project.
|
||||
project = u'Python Telegram Bot'
|
||||
copyright = u'2015-2020, Leandro Toledo'
|
||||
project = u'python-telegram-bot'
|
||||
copyright = u'2015-2021, Leandro Toledo'
|
||||
author = u'Leandro Toledo'
|
||||
|
||||
# The version info for the project you're documenting, acts as replacement for
|
||||
@@ -58,9 +60,9 @@ author = u'Leandro Toledo'
|
||||
# built documents.
|
||||
#
|
||||
# The short X.Y version.
|
||||
version = '12.6' # telegram.__version__[:3]
|
||||
version = '13.6' # telegram.__version__[:3]
|
||||
# The full version, including alpha/beta/rc tags.
|
||||
release = '12.6.1' # telegram.__version__
|
||||
release = '13.6' # telegram.__version__
|
||||
|
||||
# The language for content autogenerated by Sphinx. Refer to documentation
|
||||
# for a list of supported languages.
|
||||
@@ -116,7 +118,9 @@ html_theme = 'sphinx_rtd_theme'
|
||||
# Theme options are theme-specific and customize the look and feel of a theme
|
||||
# further. For a list of options available for each theme, see the
|
||||
# documentation.
|
||||
#html_theme_options = {}
|
||||
html_theme_options = {
|
||||
'style_external_links': True,
|
||||
}
|
||||
|
||||
# Add any paths that contain custom themes here, relative to this directory.
|
||||
#html_theme_path = []
|
||||
@@ -203,7 +207,7 @@ html_static_path = ['_static']
|
||||
#html_search_scorer = 'scorer.js'
|
||||
|
||||
# Output file base name for HTML help builder.
|
||||
htmlhelp_basename = 'PythonTelegramBotdoc'
|
||||
htmlhelp_basename = 'python-telegram-bot-doc'
|
||||
|
||||
# -- Options for LaTeX output ---------------------------------------------
|
||||
|
||||
@@ -228,7 +232,7 @@ latex_elements = {
|
||||
# (source start file, target name, title,
|
||||
# author, documentclass [howto, manual, or own class]).
|
||||
latex_documents = [
|
||||
(master_doc, 'PythonTelegramBot.tex', u'Python Telegram Bot Documentation',
|
||||
(master_doc, 'python-telegram-bot.tex', u'python-telegram-bot Documentation',
|
||||
author, 'manual'),
|
||||
]
|
||||
|
||||
@@ -258,7 +262,7 @@ latex_logo = 'ptb-logo_1024.png'
|
||||
# One entry per manual page. List of tuples
|
||||
# (source start file, name, description, authors, manual section).
|
||||
man_pages = [
|
||||
(master_doc, 'pythontelegrambot', u'Python Telegram Bot Documentation',
|
||||
(master_doc, 'python-telegram-bot', u'python-telegram-bot Documentation',
|
||||
[author], 1)
|
||||
]
|
||||
|
||||
@@ -272,8 +276,8 @@ man_pages = [
|
||||
# (source start file, target name, title, author,
|
||||
# dir menu entry, description, category)
|
||||
texinfo_documents = [
|
||||
(master_doc, 'PythonTelegramBot', u'Python Telegram Bot Documentation',
|
||||
author, 'PythonTelegramBot', "We have made you a wrapper you can't refuse",
|
||||
(master_doc, 'python-telegram-bot', u'python-telegram-bot Documentation',
|
||||
author, 'python-telegram-bot', "We have made you a wrapper you can't refuse",
|
||||
'Miscellaneous'),
|
||||
]
|
||||
|
||||
@@ -301,4 +305,5 @@ def autodoc_skip_member(app, what, name, obj, skip, options):
|
||||
|
||||
|
||||
def setup(app):
|
||||
app.add_css_file("dark.css")
|
||||
app.connect('autodoc-skip-member', autodoc_skip_member)
|
||||
|
||||
@@ -15,14 +15,17 @@ On our wiki you will also find guides like how to use handlers, webhooks, emoji,
|
||||
Examples
|
||||
========
|
||||
|
||||
A great way to learn is by looking at examples. Ours can be found at our `github in the examples folder <https://github.com/python-telegram-bot/python-telegram-bot/tree/master/examples>`_.
|
||||
A great way to learn is by looking at examples. Ours can be found in our `examples folder on Github <https://github.com/python-telegram-bot/python-telegram-bot/tree/master/examples>`_.
|
||||
|
||||
|
||||
Reference
|
||||
=========
|
||||
|
||||
Below you can find a reference of all the classes and methods in python-telegram-bot.
|
||||
Apart from the `telegram.ext` package the objects should reflect the types defined in the `official telegram bot api documentation <https://core.telegram.org/bots/api>`_.
|
||||
Apart from the `telegram.ext` package the objects should reflect the types defined in the `official Telegram Bot API documentation <https://core.telegram.org/bots/api>`_.
|
||||
|
||||
.. toctree::
|
||||
telegram.ext
|
||||
|
||||
.. toctree::
|
||||
telegram
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/files/animation.py
|
||||
|
||||
telegram.Animation
|
||||
==================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/files/audio.py
|
||||
|
||||
telegram.Audio
|
||||
==============
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/bot.py
|
||||
|
||||
telegram.Bot
|
||||
============
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/botcommand.py
|
||||
|
||||
telegram.BotCommand
|
||||
===================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/games/callbackgame.py
|
||||
|
||||
telegram.Callbackgame
|
||||
=====================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/ext/callbackquery.py
|
||||
|
||||
telegram.CallbackQuery
|
||||
======================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/chat.py
|
||||
|
||||
telegram.Chat
|
||||
=============
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/chataction.py
|
||||
|
||||
telegram.ChatAction
|
||||
===================
|
||||
|
||||
|
||||
@@ -0,0 +1,8 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/chatinvitelink.py
|
||||
|
||||
telegram.ChatInviteLink
|
||||
=======================
|
||||
|
||||
.. autoclass:: telegram.ChatInviteLink
|
||||
:members:
|
||||
:show-inheritance:
|
||||
@@ -0,0 +1,8 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/chatlocation.py
|
||||
|
||||
telegram.ChatLocation
|
||||
=====================
|
||||
|
||||
.. autoclass:: telegram.ChatLocation
|
||||
:members:
|
||||
:show-inheritance:
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/chatmember.py
|
||||
|
||||
telegram.ChatMember
|
||||
===================
|
||||
|
||||
|
||||
@@ -0,0 +1,8 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/chatmemberupdated.py
|
||||
|
||||
telegram.ChatMemberUpdated
|
||||
==========================
|
||||
|
||||
.. autoclass:: telegram.ChatMemberUpdated
|
||||
:members:
|
||||
:show-inheritance:
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/chatpermissions.py
|
||||
|
||||
telegram.ChatPermissions
|
||||
========================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/files/chatphoto.py
|
||||
|
||||
telegram.ChatPhoto
|
||||
==================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/choseninlineresult.py
|
||||
|
||||
telegram.ChosenInlineResult
|
||||
===========================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/constants.py
|
||||
|
||||
telegram.constants Module
|
||||
=========================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/files/contact.py
|
||||
|
||||
telegram.Contact
|
||||
================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/passport/credentials.py
|
||||
|
||||
telegram.Credentials
|
||||
====================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/passport/credentials.py
|
||||
|
||||
telegram.DataCredentials
|
||||
========================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/dice.py
|
||||
|
||||
telegram.Dice
|
||||
=============
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/files/document.py
|
||||
|
||||
telegram.Document
|
||||
=================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/passport/credentials.py
|
||||
|
||||
telegram.EncryptedCredentials
|
||||
=============================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/passport/encryptedpassportelement.py
|
||||
|
||||
telegram.EncryptedPassportElement
|
||||
=================================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/error.py
|
||||
|
||||
telegram.error module
|
||||
=====================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/ext/basepersistence.py
|
||||
|
||||
telegram.ext.BasePersistence
|
||||
============================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/ext/callbackcontext.py
|
||||
|
||||
telegram.ext.CallbackContext
|
||||
============================
|
||||
|
||||
|
||||
@@ -0,0 +1,8 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/ext/callbackdatacache.py
|
||||
|
||||
telegram.ext.CallbackDataCache
|
||||
==============================
|
||||
|
||||
.. autoclass:: telegram.ext.CallbackDataCache
|
||||
:members:
|
||||
:show-inheritance:
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/ext/callbackqueryhandler.py
|
||||
|
||||
telegram.ext.CallbackQueryHandler
|
||||
=================================
|
||||
|
||||
|
||||
@@ -0,0 +1,8 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/ext/chatmemberhandler.py
|
||||
|
||||
telegram.ext.ChatMemberHandler
|
||||
==============================
|
||||
|
||||
.. autoclass:: telegram.ext.ChatMemberHandler
|
||||
:members:
|
||||
:show-inheritance:
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/ext/choseninlineresulthandler.py
|
||||
|
||||
telegram.ext.ChosenInlineResultHandler
|
||||
======================================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/ext/commandhandler.py
|
||||
|
||||
telegram.ext.CommandHandler
|
||||
===========================
|
||||
|
||||
|
||||
@@ -0,0 +1,8 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/ext/contexttypes.py
|
||||
|
||||
telegram.ext.ContextTypes
|
||||
=========================
|
||||
|
||||
.. autoclass:: telegram.ext.ContextTypes
|
||||
:members:
|
||||
:show-inheritance:
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/ext/conversationhandler.py
|
||||
|
||||
telegram.ext.ConversationHandler
|
||||
================================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/ext/defaults.py
|
||||
|
||||
telegram.ext.Defaults
|
||||
=====================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/ext/messagequeue.py
|
||||
|
||||
telegram.ext.DelayQueue
|
||||
=======================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/ext/dictpersistence.py
|
||||
|
||||
telegram.ext.DictPersistence
|
||||
============================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/ext/dispatcher.py
|
||||
|
||||
telegram.ext.Dispatcher
|
||||
=======================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/ext/dispatcher.py
|
||||
|
||||
telegram.ext.DispatcherHandlerStop
|
||||
==================================
|
||||
|
||||
|
||||
@@ -0,0 +1,7 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/ext/extbot.py
|
||||
|
||||
telegram.ext.ExtBot
|
||||
===================
|
||||
|
||||
.. autoclass:: telegram.ext.ExtBot
|
||||
:show-inheritance:
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/ext/filters.py
|
||||
|
||||
telegram.ext.filters Module
|
||||
===========================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/ext/handler.py
|
||||
|
||||
telegram.ext.Handler
|
||||
====================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/ext/inlinequeryhandler.py
|
||||
|
||||
telegram.ext.InlineQueryHandler
|
||||
===============================
|
||||
|
||||
|
||||
@@ -0,0 +1,8 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/ext/callbackdatacache.py
|
||||
|
||||
telegram.ext.InvalidCallbackData
|
||||
================================
|
||||
|
||||
.. autoclass:: telegram.ext.InvalidCallbackData
|
||||
:members:
|
||||
:show-inheritance:
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/ext/jobqueue.py
|
||||
|
||||
telegram.ext.Job
|
||||
=====================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/ext/jobqueue.py
|
||||
|
||||
telegram.ext.JobQueue
|
||||
=====================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/ext/messagehandler.py
|
||||
|
||||
telegram.ext.MessageHandler
|
||||
===========================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/ext/messagequeue.py
|
||||
|
||||
telegram.ext.MessageQueue
|
||||
=========================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/ext/picklepersistence.py
|
||||
|
||||
telegram.ext.PicklePersistence
|
||||
==============================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/ext/pollanswerhandler.py
|
||||
|
||||
telegram.ext.PollAnswerHandler
|
||||
==============================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/ext/pollhandler.py
|
||||
|
||||
telegram.ext.PollHandler
|
||||
========================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/ext/precheckoutqueryhandler.py
|
||||
|
||||
telegram.ext.PreCheckoutQueryHandler
|
||||
====================================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/ext/commandhandler.py
|
||||
|
||||
telegram.ext.PrefixHandler
|
||||
===========================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/ext/regexhandler.py
|
||||
|
||||
telegram.ext.RegexHandler
|
||||
=========================
|
||||
|
||||
|
||||
@@ -3,15 +3,16 @@ telegram.ext package
|
||||
|
||||
.. toctree::
|
||||
|
||||
telegram.ext.extbot
|
||||
telegram.ext.updater
|
||||
telegram.ext.dispatcher
|
||||
telegram.ext.dispatcherhandlerstop
|
||||
telegram.ext.filters
|
||||
telegram.ext.callbackcontext
|
||||
telegram.ext.job
|
||||
telegram.ext.jobqueue
|
||||
telegram.ext.messagequeue
|
||||
telegram.ext.delayqueue
|
||||
telegram.ext.callbackcontext
|
||||
telegram.ext.contexttypes
|
||||
telegram.ext.defaults
|
||||
|
||||
Handlers
|
||||
@@ -22,10 +23,12 @@ Handlers
|
||||
telegram.ext.handler
|
||||
telegram.ext.callbackqueryhandler
|
||||
telegram.ext.choseninlineresulthandler
|
||||
telegram.ext.conversationhandler
|
||||
telegram.ext.chatmemberhandler
|
||||
telegram.ext.commandhandler
|
||||
telegram.ext.conversationhandler
|
||||
telegram.ext.inlinequeryhandler
|
||||
telegram.ext.messagehandler
|
||||
telegram.ext.filters
|
||||
telegram.ext.pollanswerhandler
|
||||
telegram.ext.pollhandler
|
||||
telegram.ext.precheckoutqueryhandler
|
||||
@@ -43,4 +46,20 @@ Persistence
|
||||
|
||||
telegram.ext.basepersistence
|
||||
telegram.ext.picklepersistence
|
||||
telegram.ext.dictpersistence
|
||||
telegram.ext.dictpersistence
|
||||
|
||||
Arbitrary Callback Data
|
||||
-----------------------
|
||||
|
||||
.. toctree::
|
||||
|
||||
telegram.ext.callbackdatacache
|
||||
telegram.ext.invalidcallbackdata
|
||||
|
||||
utils
|
||||
-----
|
||||
|
||||
.. toctree::
|
||||
|
||||
telegram.ext.utils.promise
|
||||
telegram.ext.utils.types
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/ext/shippingqueryhandler.py
|
||||
|
||||
telegram.ext.ShippingQueryHandler
|
||||
=================================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/ext/stringcommandhandler.py
|
||||
|
||||
telegram.ext.StringCommandHandler
|
||||
=================================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/ext/stringregexhandler.py
|
||||
|
||||
telegram.ext.StringRegexHandler
|
||||
===============================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/ext/typehandler.py
|
||||
|
||||
telegram.ext.TypeHandler
|
||||
========================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/ext/updater.py
|
||||
|
||||
telegram.ext.Updater
|
||||
====================
|
||||
|
||||
|
||||
@@ -0,0 +1,8 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/ext/utils/promise.py
|
||||
|
||||
telegram.ext.utils.promise.Promise
|
||||
==================================
|
||||
|
||||
.. autoclass:: telegram.ext.utils.promise.Promise
|
||||
:members:
|
||||
:show-inheritance:
|
||||
@@ -0,0 +1,8 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/ext/utils/types.py
|
||||
|
||||
telegram.ext.utils.types Module
|
||||
================================
|
||||
|
||||
.. automodule:: telegram.ext.utils.types
|
||||
:members:
|
||||
:show-inheritance:
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/files/file.py
|
||||
|
||||
telegram.File
|
||||
=============
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/passport/credentials.py
|
||||
|
||||
telegram.FileCredentials
|
||||
========================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/forcereply.py
|
||||
|
||||
telegram.ForceReply
|
||||
===================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/games/game.py
|
||||
|
||||
telegram.Game
|
||||
=============
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/games/gamehighscore.py
|
||||
|
||||
telegram.GameHighScore
|
||||
======================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/passport/data.py
|
||||
|
||||
telegram.IdDocumentData
|
||||
=======================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/inline/inlinekeyboardbutton.py
|
||||
|
||||
telegram.InlineKeyboardButton
|
||||
=============================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/inline/inlinekeyboardmarkup.py
|
||||
|
||||
telegram.InlineKeyboardMarkup
|
||||
=============================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/inline/inlinequery.py
|
||||
|
||||
telegram.InlineQuery
|
||||
====================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/inline/inlinequeryresult.py
|
||||
|
||||
telegram.InlineQueryResult
|
||||
==========================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/inline/inlinequeryresultarticle.py
|
||||
|
||||
telegram.InlineQueryResultArticle
|
||||
=================================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/inline/inlinequeryresultaudio.py
|
||||
|
||||
telegram.InlineQueryResultAudio
|
||||
===============================
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
:github_url: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/inline/inlinequeryresultcachedaudio.py
|
||||
|
||||
telegram.InlineQueryResultCachedAudio
|
||||
=====================================
|
||||
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user