-
Notifications
You must be signed in to change notification settings - Fork 0
Releasing a new version
This project adheres to the Semantic Versioning specification by Tom Preston-Werner.
Creating a release on windows is inadvisable due to the limitations for setting file permissions on the Windows file-system. On Windows 10 you can install a native Ubuntu shell_ to solve this problem. Within the shell first run:
$ umask 0022
To make sure file permissions will be set right. then Clone the repo (or pull the latest master) and follow the steps below to package the library. Uploading can be done from within Windows again if you prefer.
Packages:
$ pip install -r requirements-dev.txt -r docs/requirements-docs.txt $ pip install wheel twine
-
Bump version:
- telegram/version.py
- docs/source/conf.py
-
Log changes to:
- CHANGES.rst
-
Run tests:
$ make test
-
Build source distribution:
$ python setup.py sdist bdist_wheel
-
Register new version (obsolete, not needed):
$ python setup.py register
-
Upload to PyPI (-s to sign the package with your GnuPG key):
$ twine upload -s dist/python*
-
Commit the version bump and add tag:
$ git commit -a -m 'Bump version to v<VERSION>' $ git push
-
Create a new release:
- Tag version: v<VERSION>
- Release title: v<VERSION>
- Description: <logs from CHANGES.rst>
- Upload the source distribution from pypi as binary attachment + asc (gpg signature) + sha1 (create it yourself).
-
Documentation:
* Build localy
$ python setup.py build_sphinx
- Fix any errors in the build
- On Readthedocs dashboard trigger a build for stable release.
-
Close milestones for this version.
-
Test in a clean virtualenv that
pip install python-telegram-bot
works with the new version.
Please use the following channels/groups to announce a new version release:
- Wiki of
python-telegram-bot
© Copyright 2015-2025 – Licensed by Creative Commons
- Architecture Overview
- Builder Pattern for
Application
- Types of Handlers
- Working with Files and Media
- Exceptions, Warnings and Logging
- Concurrency in PTB
- Advanced Filters
- Storing data
- Making your bot persistent
- Adding Defaults
- Job Queue
- Arbitrary
callback_data
- Avoiding flood limits
- Webhooks
- Bot API Forward Compatiblity
- Frequently requested design patterns
- Code snippets
- Performance Optimizations
- Telegram Passport
- Bots built with PTB
- Automated Bot Tests