Skip to content

Commit aa6f6b2

Browse files
authored
Merge branch 'master' into fix-doc/tutorial-extra-models
2 parents 9d977fe + 62be4a1 commit aa6f6b2

174 files changed

Lines changed: 20599 additions & 4657 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/workflows/contributors.yml

Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
name: FastAPI People Contributors
2+
3+
on:
4+
schedule:
5+
- cron: "0 3 1 * *"
6+
workflow_dispatch:
7+
inputs:
8+
debug_enabled:
9+
description: "Run the build with tmate debugging enabled (https://github.com/marketplace/actions/debugging-with-tmate)"
10+
required: false
11+
default: "false"
12+
13+
env:
14+
UV_SYSTEM_PYTHON: 1
15+
16+
jobs:
17+
job:
18+
if: github.repository_owner == 'fastapi'
19+
runs-on: ubuntu-latest
20+
permissions:
21+
contents: write
22+
steps:
23+
- name: Dump GitHub context
24+
env:
25+
GITHUB_CONTEXT: ${{ toJson(github) }}
26+
run: echo "$GITHUB_CONTEXT"
27+
- uses: actions/checkout@v4
28+
- name: Set up Python
29+
uses: actions/setup-python@v5
30+
with:
31+
python-version: "3.11"
32+
- name: Setup uv
33+
uses: astral-sh/setup-uv@v5
34+
with:
35+
version: "0.4.15"
36+
enable-cache: true
37+
cache-dependency-glob: |
38+
requirements**.txt
39+
pyproject.toml
40+
- name: Install Dependencies
41+
run: uv pip install -r requirements-github-actions.txt
42+
# Allow debugging with tmate
43+
- name: Setup tmate session
44+
uses: mxschmitt/action-tmate@v3
45+
if: ${{ github.event_name == 'workflow_dispatch' && github.event.inputs.debug_enabled == 'true' }}
46+
with:
47+
limit-access-to-actor: true
48+
env:
49+
GITHUB_TOKEN: ${{ secrets.FASTAPI_PR_TOKEN }}
50+
- name: FastAPI People Contributors
51+
run: python ./scripts/contributors.py
52+
env:
53+
GITHUB_TOKEN: ${{ secrets.FASTAPI_PR_TOKEN }}

.github/workflows/smokeshow.yml

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,17 @@ jobs:
4040
path: htmlcov
4141
github-token: ${{ secrets.GITHUB_TOKEN }}
4242
run-id: ${{ github.event.workflow_run.id }}
43-
- run: smokeshow upload htmlcov
43+
# Try 5 times to upload coverage to smokeshow
44+
- name: Upload coverage to Smokeshow
45+
run: |
46+
for i in 1 2 3 4 5; do
47+
if smokeshow upload htmlcov; then
48+
echo "Smokeshow upload success!"
49+
break
50+
fi
51+
echo "Smokeshow upload error, sleep 1 sec and try again."
52+
sleep 1
53+
done
4454
env:
4555
SMOKESHOW_GITHUB_STATUS_DESCRIPTION: Coverage {coverage-percentage}
4656
SMOKESHOW_GITHUB_COVERAGE_THRESHOLD: 100

.github/workflows/topic-repos.yml

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
name: Update Topic Repos
2+
3+
on:
4+
schedule:
5+
- cron: "0 12 1 * *"
6+
workflow_dispatch:
7+
8+
env:
9+
UV_SYSTEM_PYTHON: 1
10+
11+
jobs:
12+
topic-repos:
13+
if: github.repository_owner == 'fastapi'
14+
runs-on: ubuntu-latest
15+
permissions:
16+
contents: write
17+
steps:
18+
- name: Dump GitHub context
19+
env:
20+
GITHUB_CONTEXT: ${{ toJson(github) }}
21+
run: echo "$GITHUB_CONTEXT"
22+
- uses: actions/checkout@v4
23+
- name: Set up Python
24+
uses: actions/setup-python@v5
25+
with:
26+
python-version: "3.11"
27+
- name: Setup uv
28+
uses: astral-sh/setup-uv@v5
29+
with:
30+
version: "0.4.15"
31+
enable-cache: true
32+
cache-dependency-glob: |
33+
requirements**.txt
34+
pyproject.toml
35+
- name: Install GitHub Actions dependencies
36+
run: uv pip install -r requirements-github-actions.txt
37+
- name: Update Topic Repos
38+
run: python ./scripts/topic_repos.py
39+
env:
40+
GITHUB_TOKEN: ${{ secrets.FASTAPI_PR_TOKEN }}

0 commit comments

Comments
 (0)