Skip to content

Commit

Permalink
Drop python-telegram-bot-raw And Switch to pyproject.toml Based P…
Browse files Browse the repository at this point in the history
…ackaging (#4288)
  • Loading branch information
Bibo-Joshi committed Jun 15, 2024
1 parent a9f6afd commit 44e8292
Show file tree
Hide file tree
Showing 26 changed files with 153 additions and 518 deletions.
11 changes: 3 additions & 8 deletions .github/CONTRIBUTING.rst
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ Setting things up

.. code-block:: bash
$ pip install -r requirements-all.txt
$ pip install -r requirements-dev-all.txt
5. Install pre-commit hooks:
Expand Down Expand Up @@ -210,13 +210,8 @@ doc strings don't have a separate documentation site they generate, instead, the

User facing documentation
-------------------------
We use `sphinx`_ to generate static HTML docs. To build them, first make sure you're running Python 3.9 or above and have the required dependencies:

.. code-block:: bash
$ pip install -r docs/requirements-docs.txt
then run the following from the PTB root directory:
We use `sphinx`_ to generate static HTML docs. To build them, first make sure you're running Python 3.9 or above and have the required dependencies installed as explained above.
Then, run the following from the PTB root directory:

.. code-block:: bash
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ jobs:
- name: Install dependencies
run: |
python -W ignore -m pip install --upgrade pip
python -W ignore -m pip install -r requirements-all.txt
python -W ignore -m pip install -r requirements-dev-all.txt
- name: Test autogeneration of admonitions
run: pytest -v --tb=short tests/docs/admonition_inserter.py
- name: Build docs
Expand Down
19 changes: 0 additions & 19 deletions .github/workflows/pre-commit_dependencies_notifier.yml

This file was deleted.

18 changes: 0 additions & 18 deletions .github/workflows/readme_notifier.yml

This file was deleted.

5 changes: 2 additions & 3 deletions .github/workflows/test_official.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,8 @@ jobs:
- name: Install dependencies
run: |
python -W ignore -m pip install --upgrade pip
python -W ignore -m pip install -r requirements.txt
python -W ignore -m pip install -r requirements-opts.txt
python -W ignore -m pip install -r requirements-dev.txt
python -W ignore -m pip install .[all]
python -W ignore -m pip install -r requirements-unit-tests.txt
- name: Compare to official api
run: |
pytest -v tests/test_official/test_official.py --junit-xml=.test_report_official.xml
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/type_completeness.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,7 @@ on:
pull_request:
paths:
- telegram/**
- requirements.txt
- requirements-opts.txt
- pyproject.toml
push:
branches:
- master
Expand Down
11 changes: 5 additions & 6 deletions .github/workflows/unit_tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,8 @@ on:
paths:
- telegram/**
- tests/**
- requirements.txt
- requirements-opts.txt
- requirements-dev.txt
- pyproject.toml
- requirements-unit-tests.txt
push:
branches:
- master
Expand Down Expand Up @@ -35,8 +34,8 @@ jobs:
run: |
python -W ignore -m pip install --upgrade pip
python -W ignore -m pip install -U pytest-cov
python -W ignore -m pip install -r requirements.txt
python -W ignore -m pip install -r requirements-dev.txt
python -W ignore -m pip install .
python -W ignore -m pip install -r requirements-unit-tests.txt
python -W ignore -m pip install pytest-xdist[psutil]
- name: Test with pytest
Expand Down Expand Up @@ -65,7 +64,7 @@ jobs:
# Test the rest
export TEST_WITH_OPT_DEPS='true'
pip install -r requirements-opts.txt
pip install .[all]
# `-n auto --dist loadfile` uses pytest-xdist to run each test file on a different CPU
# worker. Increasing number of workers has little effect on test duration, but it seems
# to increase flakyness, specially on python 3.7 with --dist=loadgroup.
Expand Down
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Make sure that the additional_dependencies here match requirements(-opts).txt
# Make sure that the additional_dependencies here match pyproject.toml

ci:
autofix_prs: false
Expand Down
1 change: 0 additions & 1 deletion MANIFEST.in

This file was deleted.

3 changes: 2 additions & 1 deletion README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,8 @@ You can also install ``python-telegram-bot`` from source, though this is usually
$ git clone https://github.com/python-telegram-bot/python-telegram-bot
$ cd python-telegram-bot
$ python setup.py install
$ pip install build
$ python -m build
Verifying Releases
------------------
Expand Down
213 changes: 0 additions & 213 deletions README_RAW.rst

This file was deleted.

2 changes: 1 addition & 1 deletion docs/requirements-docs.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ furo-sphinx-search @ git+https://github.com/harshil21/furo-sphinx-search@v0.2.0.
sphinx-paramlinks==0.6.0
sphinxcontrib-mermaid==0.9.2
sphinx-copybutton==0.5.2
sphinx-inline-tabs==2023.4.21
sphinx-inline-tabs==2023.4.21
Loading

0 comments on commit 44e8292

Please sign in to comment.