Skip to content

[pull] master from python-telegram-bot:master #34

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 134 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
134 commits
Select commit Hold shift + click to select a range
006a290
Bump `furo` from 2024.5.6 to 2024.7.18 (#4392)
dependabot[bot] Jul 21, 2024
c3f17bb
Start Adapting to RTD Addons (#4386)
Bibo-Joshi Jul 21, 2024
0913b85
Add Internal Constants for Encodings (#4378)
elpekenin Jul 21, 2024
6d70c56
Bump `sphinx` from 7.3.7 to 7.4.7 (#4395)
dependabot[bot] Jul 21, 2024
8a205b1
Add Introductory Paragraphs to Telegram Types Subsections (#4389)
mohdyusuf2312 Jul 24, 2024
af76a84
Update `cachetools` requirement from ~=5.3.3 to >=5.3.3,<5.5.0 (#4390)
dependabot[bot] Jul 24, 2024
a967dbe
Document Return Types of `RequestData` Members (#4396)
Bibo-Joshi Aug 2, 2024
6578c76
API 7.8 (#4408)
Bibo-Joshi Aug 2, 2024
b89f5d6
Bump `dependabot/fetch-metadata` from 2.1.0 to 2.2.0 (#4411)
dependabot[bot] Aug 2, 2024
e637d17
Bump `pytest` from 8.2.2 to 8.3.2 (#4403)
dependabot[bot] Aug 2, 2024
3a49372
Add Parameter `read_file_handle` to `InputFile` (#4388)
Bibo-Joshi Aug 2, 2024
9c50a38
Bump `test-summary/action` from 2.3 to 2.4 (#4410)
dependabot[bot] Aug 3, 2024
1787586
Bugfix for "Available In" Admonitions (#4413)
harshil21 Aug 3, 2024
8f9db63
Bump `ruff` and Add New Rules (#4416)
harshil21 Aug 7, 2024
374875c
Bump `sphinx` from 7.4.7 to 8.0.2 and `furo` from 2024.7.18 to 2024.8…
dependabot[bot] Aug 13, 2024
3017bf0
Update Python 3.13 Test Suite to RC1 (#4415)
harshil21 Aug 13, 2024
fbf07bf
Improve Fixture Usage in `test_message.py` (#4431)
Palaptin Aug 19, 2024
a05362c
Remove Surplus Logging from `Updater` Network Loop (#4432)
MartinHjelmare Aug 19, 2024
1e05381
Update Test Suite to New Test Channel Setup (#4435)
Bibo-Joshi Aug 26, 2024
01f6893
Bot API 7.9 (#4429)
Poolitzer Sep 1, 2024
e0f3686
Add `MessageEntity.shift_entities` and `MessageEntity.concatenate` (#…
Bibo-Joshi Sep 1, 2024
b17b0d2
Improve PyPI Automation (#4375)
Bibo-Joshi Sep 1, 2024
60b439f
Update `cachetools` requirement from <5.5.0,>=5.3.3 to >=5.3.3,<5.6.0…
dependabot[bot] Sep 1, 2024
970d2ab
Documentation Improvements (#4400, #4448)
Bibo-Joshi Sep 1, 2024
8c692d1
Bump Version to v21.5 (#4449)
Bibo-Joshi Sep 1, 2024
b9d2efd
Rename Testing Base Classes (#4453)
Bibo-Joshi Sep 3, 2024
0b352b0
Make Tests for `telegram.ext` Independent of Networking (#4454)
Bibo-Joshi Sep 9, 2024
1223e85
Add Parameter `httpx_kwargs` to `HTTPXRequest` (#4451)
Bibo-Joshi Sep 11, 2024
ec909e6
Enforce the `offline_bot` Fixture in `Test*WithoutRequest` (#4465)
Bibo-Joshi Sep 13, 2024
b3155b2
Update Python 3.13 Test Suite to RC2 (#4471)
harshil21 Sep 13, 2024
6b5e46c
Improve Type Completeness (#4466)
Bibo-Joshi Sep 14, 2024
9248c53
Bump `pytest` from 8.3.2 to 8.3.3 (#4475)
dependabot[bot] Sep 14, 2024
67a97ae
API 7.10 (#4461, #4460, #4463, #4464)
harshil21 Sep 17, 2024
e314e78
Bump Version to v21.6 (#4486)
Bibo-Joshi Sep 19, 2024
28d19c3
Introduce `conftest.py` for File Related Tests (#4488)
Bibo-Joshi Sep 21, 2024
2eae283
Maintenance Work on `Bot` Tests (#4489)
Bibo-Joshi Sep 21, 2024
3409f51
Introduce Codecov's Test Analysis (#4487)
Bibo-Joshi Sep 21, 2024
9709c03
Fix Failing Tests by Making Them Independent (#4494)
Bibo-Joshi Sep 21, 2024
bd3cdbc
Update `pytest-xdist` Usage (#4491)
Bibo-Joshi Sep 22, 2024
79e589b
Reduce Creation of HTTP Clients in Tests (#4493)
Bibo-Joshi Sep 25, 2024
2bc6556
Stabilize Some Flaky Tests (#4500)
Bibo-Joshi Sep 25, 2024
2f06902
Improve Test Instability Caused by `Message` Fixtures (#4507)
Bibo-Joshi Oct 1, 2024
9a8b208
Bump `Bibo-Joshi/pyright-type-completeness` from 1.0.0 to 1.0.1 (#4510)
dependabot[bot] Oct 2, 2024
0685463
Bump `srvaroa/labeler` from 1.10.1 to 1.11.0 (#4509)
dependabot[bot] Oct 2, 2024
a39a59e
Bump `sphinxcontrib-mermaid` from 0.9.2 to 1.0.0 (#4529)
dependabot[bot] Oct 21, 2024
2ce687c
Bump `sphinx` from 8.0.2 to 8.1.3 (#4532)
dependabot[bot] Oct 21, 2024
efacc3d
Allow `Sequence` in `Application.add_handlers` (#4531)
roast-lord Oct 23, 2024
847b97f
Use Stable Python 3.13 Release in Test Suite (#4535)
Bibo-Joshi Oct 24, 2024
5ab82a9
Drop Support for Python 3.8 (#4398)
elpekenin Oct 24, 2024
6540f28
Use `sphinx-build-compatibility` to Keep Sphinx Compatibility (#4492)
Bibo-Joshi Oct 31, 2024
3c8f6ed
Fix Linkcheck Workflow (#4545)
Bibo-Joshi Nov 1, 2024
bd6a60b
Bump `srvaroa/labeler` from 1.11.0 to 1.11.1 (#4549)
dependabot[bot] Nov 2, 2024
507d6bc
Improve Exception Handling in `File.download_*` (#4542)
Bibo-Joshi Nov 3, 2024
032a859
Update Automation to Label Changes (#4552)
Bibo-Joshi Nov 3, 2024
7a8f441
Update Issue Templates to Use Issue Types (#4553)
Bibo-Joshi Nov 4, 2024
62f8975
Bot API 7.11 (#4546)
Bibo-Joshi Nov 4, 2024
dab75fb
Add `Message.reply_paid_media` (#4551)
Bibo-Joshi Nov 4, 2024
0eb11ff
Documentation Improvements (#4536, #4556)
Bibo-Joshi Nov 4, 2024
1511237
Bump Version to v21.7 (#4557)
Bibo-Joshi Nov 4, 2024
ef1685c
Full Support for Bot API 8.0 (#4566, #4568, #4570, #4571, #4574, #457…
Bibo-Joshi Dec 1, 2024
ffe23be
Documentation Improvements (#4573, #4565)
Bibo-Joshi Dec 1, 2024
cec34e4
Bump Version to v21.8 (#4583)
Bibo-Joshi Dec 1, 2024
da93fe9
Bump `srvaroa/labeler` from 1.11.1 to 1.12.0 (#4586)
dependabot[bot] Dec 2, 2024
3709c2f
Bump `pylint` to v3.3.2 to Improve Python 3.13 Support (#4590)
nemacysts Dec 4, 2024
89dfa37
Bump `codecov/codecov-action` from 4 to 5 (#4585)
dependabot[bot] Dec 4, 2024
eda2172
Allow `Sequence` Input for `allowed_updates` in `Application` and `Up…
nemacysts Dec 4, 2024
4327954
Full Support for Bot API 8.1 (#4594)
Bibo-Joshi Dec 7, 2024
ce9742a
Use `MessageLimit.DEEP_LINK_LENGTH` in `helpers.create_deep_linked_ur…
nemacysts Dec 7, 2024
c42a230
Bump `pytest` from 8.3.3 to 8.3.4 (#4596)
dependabot[bot] Dec 7, 2024
ca7a309
Update `aiolimiter` requirement from ~=1.1.0 to >=1.1,<1.3 (#4595)
dependabot[bot] Dec 7, 2024
2ac5201
Bump Version to v21.9 (#4601)
Bibo-Joshi Dec 7, 2024
4afe174
Add Static Security Analysis of GitHub Actions Workflows (#4606)
Bibo-Joshi Dec 13, 2024
4f255b6
Unify `datetime` Imports (#4605)
cuevasrja Dec 15, 2024
df20e49
Refactor Module Structure and Tests for Star Payments Classes (#4615)
Bibo-Joshi Dec 29, 2024
a6cd9c5
Allow Input of Type `Sticker` for Several Methods (#4616)
Bibo-Joshi Dec 29, 2024
f7a3f67
Use Custom Labels for `dependabot` PRs (#4621)
Bibo-Joshi Dec 30, 2024
dfb3c13
Bump `github/codeql-action` from 3.27.9 to 3.28.0 (#4624)
dependabot[bot] Dec 30, 2024
e1e7b62
Bump `actions/upload-artifact` from 4.4.3 to 4.5.0 (#4623)
dependabot[bot] Dec 30, 2024
a9a7b07
Bump `codecov/codecov-action` from 5.1.1 to 5.1.2 (#4622)
dependabot[bot] Dec 31, 2024
3c9bba6
Bump `astral-sh/setup-uv` from 4.2.0 to 5.1.0 (#4625)
dependabot[bot] Dec 31, 2024
3fc50c7
Remove Redundant `pylint` Suppressions (#4628)
Poolitzer Dec 31, 2024
5f35304
Update Copyright to 2025 (#4631)
Bibo-Joshi Jan 1, 2025
d0a6e51
Bump APS & Deprecate `pytz` Support (#4582)
dependabot[bot] Jan 1, 2025
679d038
Ensure Forward Compatibility of `Gift` and `Gifts` (#4634)
Bibo-Joshi Jan 2, 2025
a781a4f
Add Parameter `pattern` to `JobQueue.jobs()` (#4613)
Bibo-Joshi Jan 2, 2025
f2dc017
Full Support for Bot API 8.2 (#4633)
Poolitzer Jan 3, 2025
e4b0f8c
Bump Version to v21.10 (#4639)
Bibo-Joshi Jan 3, 2025
16605c5
Bump `pre-commit` Hooks to Latest Versions (#4643)
pre-commit-ci[bot] Jan 7, 2025
f57dd52
Add `BaseUpdateProcessor.current_concurrent_updates` (#4626)
Bibo-Joshi Jan 14, 2025
dd592cd
Simplify Handling of Empty Data in `TelegramObject.de_json` and Frien…
Bibo-Joshi Jan 14, 2025
61b87ba
Support `allow_paid_broadcast` in `AIORateLimiter` (#4627)
Bibo-Joshi Jan 23, 2025
5dd7b8f
Extend Customization Support for `Bot.base_(file_)url` (#4632)
Bibo-Joshi Jan 23, 2025
d7e063d
Overhaul Admonition Insertion in Documentation (#4462)
harshil21 Jan 31, 2025
6319f4b
Bump `codecov/test-results-action` from 1.0.1 to 1.0.2 (#4663)
dependabot[bot] Feb 2, 2025
4cdb1a0
Bump `astral-sh/setup-uv` from 5.1.0 to 5.2.2 (#4664)
dependabot[bot] Feb 2, 2025
79acc1a
Bump `actions/stale` from 9.0.0 to 9.1.0 (#4667)
dependabot[bot] Feb 2, 2025
a2150b3
Accept `datetime.timedelta` Input in `Bot` Method Parameters (#4651)
Bibo-Joshi Feb 2, 2025
69ddc47
Bump `dependabot/fetch-metadata` from 2.2.0 to 2.3.0 (#4666)
dependabot[bot] Feb 2, 2025
64006aa
Bump `actions/setup-python` from 5.3.0 to 5.4.0 (#4665)
dependabot[bot] Feb 2, 2025
dfb0ae3
Use Fine Grained Permissions for GitHub Actions Workflows (#4668)
Bibo-Joshi Feb 2, 2025
f9f1533
Refactor Tests for `TelegramObject` Classes with Subclasses (#4654)
Bibo-Joshi Feb 6, 2025
2d5f4a6
Fix a Bug in `edit_user_star_subscription` (#4681)
vavasik800 Feb 15, 2025
7c23087
Remove Deprecated `InlineQueryResultArticle.hide_url` (#4640)
Bibo-Joshi Feb 17, 2025
5d73132
Make `provider_token` Argument Optional (#4689)
Bibo-Joshi Feb 26, 2025
35a48f8
Documentation Improvements (#4641)
Bibo-Joshi Feb 27, 2025
b0d22ac
Add Bootstrapping Logic to `Application.run_*` (#4673)
Bibo-Joshi Mar 1, 2025
b75948e
Full Support for Bot API 8.3 (#4676)
Poolitzer Mar 1, 2025
77c2593
Stabilize Linkcheck Test (#4693)
Bibo-Joshi Mar 1, 2025
9323caf
Bump Version to v21.11 (#4694)
Bibo-Joshi Mar 1, 2025
3464f24
Fix ReadTheDocs Build (#4695)
Bibo-Joshi Mar 1, 2025
1e4f31f
Bump Version to v21.11.1 (#4696)
Bibo-Joshi Mar 1, 2025
76d8eaf
Add `chango` As Changelog Management Tool (#4672)
Bibo-Joshi Mar 1, 2025
a5dacab
Bump github/codeql-action from 3.28.8 to 3.28.10 (#4697)
dependabot[bot] Mar 2, 2025
d5e5874
Bump srvaroa/labeler from 1.12.0 to 1.13.0 (#4698)
dependabot[bot] Mar 2, 2025
892a66d
Bump astral-sh/setup-uv from 5.2.2 to 5.3.1 (#4699)
dependabot[bot] Mar 2, 2025
753f372
Bump Bibo-Joshi/chango from 0.3.1 to 0.3.2 (#4700)
dependabot[bot] Mar 2, 2025
519dee7
Bump pypa/gh-action-pypi-publish from 1.12.3 to 1.12.4 (#4701)
dependabot[bot] Mar 2, 2025
8266870
Bump pytest from 8.3.4 to 8.3.5 (#4709)
dependabot[bot] Mar 8, 2025
6d71346
Bump sphinx from 8.1.3 to 8.2.3 (#4710)
dependabot[bot] Mar 8, 2025
1503287
Bump Bibo-Joshi/chango from 0.3.2 to 0.4.0 (#4712)
Bibo-Joshi Mar 9, 2025
1cf000c
Remove Functionality Deprecated in v20.x (#4671)
Bibo-Joshi Mar 15, 2025
9ebd489
Bump Version to v22.0 (#4719)
Bibo-Joshi Mar 15, 2025
83676de
Reenable `test_official` Blocked by Debug Remnant (#4746)
aelkheir Apr 6, 2025
3cd8a40
Bump `actions/download-artifact` from 4.1.8 to 4.2.1 (#4745)
dependabot[bot] Apr 6, 2025
036910e
Bump `astral-sh/setup-uv` from 5.3.1 to 5.4.1 (#4744)
dependabot[bot] Apr 6, 2025
511222c
Bump `codecov/test-results-action` from 1.0.2 to 1.1.0 (#4741)
dependabot[bot] Apr 6, 2025
e69069d
Bump `github/codeql-action` from 3.28.10 to 3.28.13 (#4743)
dependabot[bot] Apr 6, 2025
a9e53af
Update `AUTHORS.rst`, Adding @aelkheir to Active Development Team (#4…
Bibo-Joshi Apr 7, 2025
7823822
Bump `actions/setup-python` from 5.4.0 to 5.5.0 (#4742)
dependabot[bot] Apr 7, 2025
ed9496b
Ensure Proper Execution of `Bot.shutdown` (#4733)
Poolitzer Apr 8, 2025
c6e12b1
Drop Backward Compatibility for `user_id` in `send_gift` (#4692)
Bibo-Joshi Apr 11, 2025
17ae6a7
Fix Handling of `Defaults` for `InputPaidMedia` (#4761)
ngrogolev Apr 19, 2025
54ce1d8
Fine Tune `chango` and Release Workflows (#4758)
Bibo-Joshi Apr 19, 2025
486ceaa
Clarify Documentation and Type Hints of `Input(Paid)Media` (#4762)
Bibo-Joshi Apr 20, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
2 changes: 1 addition & 1 deletion .github/CONTRIBUTING.rst
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,7 @@ 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 installed as explained above.
We use `sphinx`_ to generate static HTML docs. To build them, first make sure you're running Python 3.10 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
4 changes: 2 additions & 2 deletions .github/ISSUE_TEMPLATE/bug-report.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name: Bug Report
description: Create a report to help us improve
title: "[BUG]"
labels: ["bug :bug:"]
labels: ["📋 triage"]
type: '🐛 bug'

body:
- type: markdown
Expand Down
4 changes: 2 additions & 2 deletions .github/ISSUE_TEMPLATE/feature-request.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name: Feature Request
description: Suggest an idea for this project
title: "[FEATURE]"
labels: ["enhancement"]
labels: ["📋 triage"]
type: '💡 feature'

body:
- type: textarea
Expand Down
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/question.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name: Question
description: Get help with errors or general questions
title: "[QUESTION]"
labels: ["question"]
type: '❔ question'

body:
- type: markdown
Expand Down
6 changes: 6 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,16 @@ updates:
schedule:
interval: "weekly"
day: "friday"
labels:
- "⚙️ dependencies"
- "🔗 python"

# Updates the dependencies of the GitHub Actions workflows
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "monthly"
day: "friday"
labels:
- "⚙️ dependencies"
- "🔗 github-actions"
4 changes: 2 additions & 2 deletions .github/labeler.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
version: 1

labels:
- label: "dependencies"
- label: "⚙️ dependencies"
authors: ["dependabot[bot]", "pre-commit-ci[bot]"]
- label: "code quality"
- label: "🛠 code-quality"
authors: ["pre-commit-ci[bot]"]
5 changes: 5 additions & 0 deletions .github/workflows/assets/release_template.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
<b>We've just released {tag}</b>.
Thank you to everyone who contributed to this release.
As usual, upgrade using <code>pip install -U python-telegram-bot</code>.

The release notes can be found <a href="https://docs.python-telegram-bot.org/en/{tag}/changelog.html">here</a>.
66 changes: 66 additions & 0 deletions .github/workflows/chango.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
name: Chango
on:
pull_request:
types:
- opened
- reopened
- synchronize

permissions: {}

jobs:
create-chango-fragment:
permissions:
# Give the default GITHUB_TOKEN write permission to commit and push the
# added or changed files to the repository.
contents: write
name: Create chango Fragment
runs-on: ubuntu-latest
outputs:
IS_RELEASE_PR: ${{ steps.check_title.outputs.IS_RELEASE_PR }}

steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
# needed for commit and push step at the end
persist-credentials: true
- name: Check PR Title
id: check_title
run: | # zizmor: ignore[template-injection]
if [[ "$(echo "${{ github.event.pull_request.title }}" | tr '[:upper:]' '[:lower:]')" =~ ^bump\ version\ to\ .* ]]; then
echo "COMMIT_AND_PUSH=false" >> $GITHUB_OUTPUT
echo "IS_RELEASE_PR=true" >> $GITHUB_OUTPUT
else
echo "COMMIT_AND_PUSH=true" >> $GITHUB_OUTPUT
echo "IS_RELEASE_PR=false" >> $GITHUB_OUTPUT
fi

# Create the new fragment
- uses: Bibo-Joshi/chango@9d6bd9d7612eca5fab2c5161687011be59baaf19 # v0.4.0
with:
github-token: ${{ secrets.CHANGO_PAT }}
query-issue-types: true
commit-and-push: ${{ steps.check_title.outputs.COMMIT_AND_PUSH }}

# Run `chango release` if applicable - needs some additional setup.
- name: Set up Python
if: steps.check_title.outputs.IS_RELEASE_PR == 'true'
uses: actions/setup-python@8d9ed9ac5c53483de85588cdf95a591a75ab9f55 # v5.5.0
with:
python-version: "3.x"

- name: Do Release
if: steps.check_title.outputs.IS_RELEASE_PR == 'true'
run: |
cd ./target-repo
git add changes/unreleased/*
pip install . -r docs/requirements-docs.txt
VERSION_TAG=$(python -c "from telegram import __version__; print(f'{__version__}')")
chango release --uid $VERSION_TAG

- name: Commit & Push
if: steps.check_title.outputs.IS_RELEASE_PR == 'true'
uses: stefanzweifel/git-auto-commit-action@e348103e9026cc0eee72ae06630dbe30c8bf7a79 # v5.1.0
with:
commit_message: "Do chango Release"
repository: ./target-repo
11 changes: 7 additions & 4 deletions .github/workflows/dependabot-prs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@ on:
pull_request:
types: [opened, reopened]

permissions: {}

jobs:
process-dependabot-prs:
permissions:
Expand All @@ -16,22 +18,23 @@ jobs:

- name: Fetch Dependabot metadata
id: dependabot-metadata
uses: dependabot/fetch-metadata@v2.1.0
uses: dependabot/fetch-metadata@d7267f607e9d3fb96fc2fbe83e0af444713e90b7 # v2.3.0

- uses: actions/checkout@v4
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
ref: ${{ github.event.pull_request.head.ref }}
persist-credentials: false

- name: Update Version Number in Other Files
uses: jacobtomlinson/gha-find-replace@v3
uses: jacobtomlinson/gha-find-replace@f1069b438f125e5395d84d1c6fd3b559a7880cb5 # v3
with:
find: ${{ steps.dependabot-metadata.outputs.previous-version }}
replace: ${{ steps.dependabot-metadata.outputs.new-version }}
regex: false
exclude: CHANGES.rst

- name: Commit & Push Changes to PR
uses: EndBug/[email protected]
uses: EndBug/add-and-commit@a94899bca583c204427a224a7af87c02f9b325d5 # v9.1.4
with:
message: 'Update version number in other files'
committer_name: GitHub Actions
Expand Down
Original file line number Diff line number Diff line change
@@ -1,26 +1,34 @@
name: Test Documentation Build
name: Test Admonitions Generation
on:
pull_request:
paths:
- telegram/**
- docs/**
- .github/workflows/docs-admonitions.yml
push:
branches:
- master

permissions: {}

jobs:
test-sphinx-build:
name: test-sphinx-build
test-admonitions:
name: Test Admonitions Generation
runs-on: ${{matrix.os}}
permissions:
# for uploading artifacts
actions: write
strategy:
matrix:
python-version: [3.9]
python-version: ['3.12']
os: [ubuntu-latest]
fail-fast: False
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
persist-credentials: false
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
uses: actions/setup-python@8d9ed9ac5c53483de85588cdf95a591a75ab9f55 # v5.5.0
with:
python-version: ${{ matrix.python-version }}
cache: 'pip'
Expand All @@ -30,17 +38,4 @@ jobs:
python -W ignore -m pip install --upgrade pip
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
run: sphinx-build docs/source docs/build/html -W --keep-going -j auto
- name: Upload docs
uses: actions/upload-artifact@v4
with:
name: HTML Docs
retention-days: 7
path: |
# Exclude the .doctrees folder and .buildinfo file from the artifact
# since they are not needed and add to the size
docs/build/html/*
!docs/build/html/.doctrees
!docs/build/html/.buildinfo
run: pytest -v --tb=short tests/docs/admonition_inserter.py
22 changes: 18 additions & 4 deletions .github/workflows/docs-linkcheck.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,25 +3,39 @@ on:
schedule:
# First day of month at 05:46 in every 2nd month
- cron: '46 5 1 */2 *'
pull_request:
paths:
- .github/workflows/docs-linkcheck.yml

permissions: {}

jobs:
test-sphinx-build:
name: test-sphinx-linkcheck
runs-on: ${{matrix.os}}
strategy:
matrix:
python-version: [3.9]
python-version: ['3.12']
os: [ubuntu-latest]
fail-fast: False
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
persist-credentials: false
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
uses: actions/setup-python@8d9ed9ac5c53483de85588cdf95a591a75ab9f55 # v5.5.0
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -W ignore -m pip install --upgrade pip
python -W ignore -m pip install -r requirements-dev-all.txt
- name: Check Links
run: sphinx-build docs/source docs/build/html -W --keep-going -j auto -b linkcheck
run: sphinx-build docs/source docs/build/html --keep-going -j auto -b linkcheck
- name: Upload linkcheck output
# Run also if the previous steps failed
if: always()
uses: actions/upload-artifact@6f51ac03b9356f520e9adb1b1b7802705f340c2b # v4.5.0
with:
name: linkcheck-output
path: docs/build/html/output.*
33 changes: 33 additions & 0 deletions .github/workflows/gha_security.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: GitHub Actions Security Analysis

on:
push:
branches:
- master
pull_request:

permissions: {}

jobs:
zizmor:
name: Security Analysis with zizmor
runs-on: ubuntu-latest
permissions:
contents: read
security-events: write
steps:
- name: Checkout repository
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
persist-credentials: false
- name: Install the latest version of uv
uses: astral-sh/setup-uv@0c5e2b8115b80b4c7c5ddf6ffdd634974642d182 # v5.4.1
- name: Run zizmor
run: uvx zizmor --persona=pedantic --format sarif . > results.sarif
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Upload SARIF file
uses: github/codeql-action/upload-sarif@1b549b9259bda1cb5ddde3b41741a82a2d15a841 # v3.28.13
with:
sarif_file: results.sarif
category: zizmor
4 changes: 3 additions & 1 deletion .github/workflows/labelling.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,16 @@ on:
pull_request:
types: [opened]

permissions: {}

jobs:
pre-commit-ci:
permissions:
contents: read # for srvaroa/labeler to read config file
pull-requests: write # for srvaroa/labeler to add labels in PR
runs-on: ubuntu-latest
steps:
- uses: srvaroa/labeler@v1.10.1
- uses: srvaroa/labeler@0a20eccb8c94a1ee0bed5f16859aece1c45c3e55 # v1.13.0
# Config file at .github/labeler.yml
env:
GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}"
8 changes: 7 additions & 1 deletion .github/workflows/lock.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,17 @@ on:
schedule:
- cron: '8 4 * * *'

permissions: {}

jobs:
lock:
runs-on: ubuntu-latest
permissions:
# For locking the threads
issues: write
pull-requests: write
steps:
- uses: dessant/[email protected]
- uses: dessant/lock-threads@1bf7ec25051fe7c00bdd17e6a7cf3d7bfb7dc771 # v5.0.1
with:
github-token: ${{ github.token }}
issue-inactive-days: '7'
Expand Down
Loading