Skip to content

Commit 4ca6782

Browse files
committed
Merge branch 'main' into bugfix-57/literal-satype
2 parents 303f10f + 349bc73 commit 4ca6782

File tree

359 files changed

+2886
-18615
lines changed

Some content is hidden

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

359 files changed

+2886
-18615
lines changed

.github/workflows/build-docs.yml

Lines changed: 7 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ jobs:
2222
outputs:
2323
docs: ${{ steps.filter.outputs.docs }}
2424
steps:
25-
- uses: actions/checkout@v5
25+
- uses: actions/checkout@v6
2626
# For pull requests it's not necessary to checkout the code but for the main branch it is
2727
- uses: dorny/paths-filter@v3
2828
id: filter
@@ -33,12 +33,9 @@ jobs:
3333
- docs/**
3434
- docs_src/**
3535
- requirements-docs.txt
36-
- requirements-docs-insiders.txt
3736
- pyproject.toml
3837
- mkdocs.yml
39-
- mkdocs.insiders.yml
40-
- mkdocs.maybe-insiders.yml
41-
- mkdocs.no-insiders.yml
38+
- mkdocs.env.yml
4239
- .github/workflows/build-docs.yml
4340
- .github/workflows/deploy-docs.yml
4441
- data/**
@@ -53,13 +50,13 @@ jobs:
5350
env:
5451
GITHUB_CONTEXT: ${{ toJson(github) }}
5552
run: echo "$GITHUB_CONTEXT"
56-
- uses: actions/checkout@v5
53+
- uses: actions/checkout@v6
5754
- name: Set up Python
58-
uses: actions/setup-python@v5
55+
uses: actions/setup-python@v6
5956
with:
6057
python-version: "3.11"
6158
- name: Setup uv
62-
uses: astral-sh/setup-uv@v6
59+
uses: astral-sh/setup-uv@v7
6360
with:
6461
version: "0.4.15"
6562
enable-cache: true
@@ -68,20 +65,15 @@ jobs:
6865
pyproject.toml
6966
- name: Install docs extras
7067
run: uv pip install -r requirements-docs.txt
71-
- name: Install Material for MkDocs Insiders
72-
if: ( github.event_name != 'pull_request' || github.secret_source == 'Actions' )
73-
run: uv pip install -r requirements-docs-insiders.txt
74-
env:
75-
TOKEN: ${{ secrets.SQLMODEL_MKDOCS_MATERIAL_INSIDERS }}
76-
- uses: actions/cache@v4
68+
- uses: actions/cache@v5
7769
with:
7870
key: mkdocs-cards-${{ github.ref }}
7971
path: .cache
8072
- name: Verify README
8173
run: python ./scripts/docs.py verify-readme
8274
- name: Build Docs
8375
run: python ./scripts/docs.py build
84-
- uses: actions/upload-artifact@v4
76+
- uses: actions/upload-artifact@v6
8577
with:
8678
name: docs-site
8779
path: ./site/**

.github/workflows/deploy-docs.yml

Lines changed: 14 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -23,13 +23,13 @@ jobs:
2323
env:
2424
GITHUB_CONTEXT: ${{ toJson(github) }}
2525
run: echo "$GITHUB_CONTEXT"
26-
- uses: actions/checkout@v5
26+
- uses: actions/checkout@v6
2727
- name: Set up Python
28-
uses: actions/setup-python@v5
28+
uses: actions/setup-python@v6
2929
with:
3030
python-version: "3.11"
3131
- name: Setup uv
32-
uses: astral-sh/setup-uv@v6
32+
uses: astral-sh/setup-uv@v7
3333
with:
3434
version: "0.4.15"
3535
enable-cache: true
@@ -44,12 +44,12 @@ jobs:
4444
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
4545
COMMIT_SHA: ${{ github.event.workflow_run.head_sha }}
4646
RUN_ID: ${{ github.run_id }}
47-
47+
STATE: "pending"
4848
- name: Clean site
4949
run: |
5050
rm -rf ./site
5151
mkdir ./site
52-
- uses: actions/download-artifact@v5
52+
- uses: actions/download-artifact@v7
5353
with:
5454
path: ./site/
5555
pattern: docs-site
@@ -68,11 +68,19 @@ jobs:
6868
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}
6969
accountId: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}
7070
command: pages deploy ./site --project-name=${{ env.PROJECT_NAME }} --branch=${{ env.BRANCH }}
71+
- name: Deploy Docs Status Error
72+
if: failure()
73+
run: python ./scripts/deploy_docs_status.py
74+
env:
75+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
76+
COMMIT_SHA: ${{ github.event.workflow_run.head_sha }}
77+
RUN_ID: ${{ github.run_id }}
78+
STATE: "error"
7179
- name: Comment Deploy
7280
run: python ./scripts/deploy_docs_status.py
7381
env:
7482
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
7583
DEPLOY_URL: ${{ steps.deploy.outputs.deployment-url }}
7684
COMMIT_SHA: ${{ github.event.workflow_run.head_sha }}
7785
RUN_ID: ${{ github.run_id }}
78-
IS_DONE: "true"
86+
STATE: "success"
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
name: "Conflict detector"
2+
on:
3+
push:
4+
pull_request_target:
5+
types: [synchronize]
6+
7+
jobs:
8+
main:
9+
permissions:
10+
contents: read
11+
pull-requests: write
12+
runs-on: ubuntu-latest
13+
steps:
14+
- name: Check if PRs have merge conflicts
15+
uses: eps1lon/actions-label-merge-conflict@v3
16+
with:
17+
dirtyLabel: "conflicts"
18+
repoToken: "${{ secrets.GITHUB_TOKEN }}"
19+
commentOnDirty: "This pull request has a merge conflict that needs to be resolved."

.github/workflows/issue-manager.yml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ jobs:
2727
env:
2828
GITHUB_CONTEXT: ${{ toJson(github) }}
2929
run: echo "$GITHUB_CONTEXT"
30-
- uses: tiangolo/issue-manager@0.5.1
30+
- uses: tiangolo/issue-manager@0.6.0
3131
with:
3232
token: ${{ secrets.GITHUB_TOKEN }}
3333
config: >
@@ -38,7 +38,11 @@ jobs:
3838
},
3939
"waiting": {
4040
"delay": 2628000,
41-
"message": "As this PR has been waiting for the original user for a while but seems to be inactive, it's now going to be closed. But if there's anyone interested, feel free to create a new PR."
41+
"message": "As this PR has been waiting for the original user for a while but seems to be inactive, it's now going to be closed. But if there's anyone interested, feel free to create a new PR.",
42+
"reminder": {
43+
"before": "P3D",
44+
"message": "Heads-up: this will be closed in 3 days unless there’s new activity."
45+
}
4246
},
4347
"invalid": {
4448
"delay": 0,

.github/workflows/labeler.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ jobs:
1616
pull-requests: write
1717
runs-on: ubuntu-latest
1818
steps:
19-
- uses: actions/labeler@v5
19+
- uses: actions/labeler@v6
2020
if: ${{ github.event.action != 'labeled' && github.event.action != 'unlabeled' }}
2121
- run: echo "Done adding labels"
2222
# Run this after labeler applied labels

.github/workflows/latest-changes.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ jobs:
2020
latest-changes:
2121
runs-on: ubuntu-latest
2222
steps:
23-
- uses: actions/checkout@v5
23+
- uses: actions/checkout@v6
2424
with:
2525
# To allow latest-changes to commit to the main branch
2626
token: ${{ secrets.SQLMODEL_LATEST_CHANGES }}
@@ -30,7 +30,7 @@ jobs:
3030
if: ${{ github.event_name == 'workflow_dispatch' && github.event.inputs.debug_enabled == 'true' }}
3131
with:
3232
limit-access-to-actor: true
33-
- uses: tiangolo/latest-changes@0.4.0
33+
- uses: tiangolo/latest-changes@0.4.1
3434
with:
3535
token: ${{ secrets.GITHUB_TOKEN }}
3636
latest_changes_file: docs/release-notes.md

.github/workflows/pre-commit.yml

Lines changed: 93 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,93 @@
1+
name: pre-commit
2+
3+
on:
4+
pull_request:
5+
types:
6+
- opened
7+
- synchronize
8+
9+
env:
10+
# Forks and Dependabot don't have access to secrets
11+
HAS_SECRETS: ${{ secrets.PRE_COMMIT != '' }}
12+
13+
jobs:
14+
pre-commit:
15+
runs-on: ubuntu-latest
16+
steps:
17+
- name: Dump GitHub context
18+
env:
19+
GITHUB_CONTEXT: ${{ toJson(github) }}
20+
run: echo "$GITHUB_CONTEXT"
21+
- uses: actions/checkout@v6
22+
name: Checkout PR for own repo
23+
if: env.HAS_SECRETS == 'true'
24+
with:
25+
# To be able to commit it needs to fetch the head of the branch, not the
26+
# merge commit
27+
ref: ${{ github.head_ref }}
28+
# And it needs the full history to be able to compute diffs
29+
fetch-depth: 0
30+
# A token other than the default GITHUB_TOKEN is needed to be able to trigger CI
31+
token: ${{ secrets.PRE_COMMIT }}
32+
# pre-commit lite ci needs the default checkout configs to work
33+
- uses: actions/checkout@v6
34+
name: Checkout PR for fork
35+
if: env.HAS_SECRETS == 'false'
36+
with:
37+
# To be able to commit it needs the head branch of the PR, the remote one
38+
ref: ${{ github.event.pull_request.head.sha }}
39+
fetch-depth: 0
40+
- name: Set up Python
41+
uses: actions/setup-python@v6
42+
with:
43+
python-version: "3.14"
44+
- name: Setup uv
45+
uses: astral-sh/setup-uv@v7
46+
with:
47+
cache-dependency-glob: |
48+
requirements**.txt
49+
pyproject.toml
50+
uv.lock
51+
- name: Install Dependencies
52+
run: |
53+
uv venv
54+
uv pip install -r requirements.txt
55+
- name: Run prek - pre-commit
56+
id: precommit
57+
run: uvx prek run --from-ref origin/${GITHUB_BASE_REF} --to-ref HEAD --show-diff-on-failure
58+
continue-on-error: true
59+
- name: Commit and push changes
60+
if: env.HAS_SECRETS == 'true'
61+
run: |
62+
git config user.name "github-actions[bot]"
63+
git config user.email "github-actions[bot]@users.noreply.github.com"
64+
git add -A
65+
if git diff --staged --quiet; then
66+
echo "No changes to commit"
67+
else
68+
git commit -m "🎨 Auto format"
69+
git push
70+
fi
71+
- uses: pre-commit-ci/lite-action@v1.1.0
72+
if: env.HAS_SECRETS == 'false'
73+
with:
74+
msg: 🎨 Auto format
75+
- name: Error out on pre-commit errors
76+
if: steps.precommit.outcome == 'failure'
77+
run: exit 1
78+
79+
# https://github.com/marketplace/actions/alls-green#why
80+
pre-commit-alls-green: # This job does nothing and is only used for the branch protection
81+
if: always()
82+
needs:
83+
- pre-commit
84+
runs-on: ubuntu-latest
85+
steps:
86+
- name: Dump GitHub context
87+
env:
88+
GITHUB_CONTEXT: ${{ toJson(github) }}
89+
run: echo "$GITHUB_CONTEXT"
90+
- name: Decide whether the needed jobs succeeded or failed
91+
uses: re-actors/alls-green@release/v1
92+
with:
93+
jobs: ${{ toJSON(needs) }}

.github/workflows/publish.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,9 @@ jobs:
2222
permissions:
2323
id-token: write
2424
steps:
25-
- uses: actions/checkout@v5
25+
- uses: actions/checkout@v6
2626
- name: Set up Python
27-
uses: actions/setup-python@v5
27+
uses: actions/setup-python@v6
2828
with:
2929
python-version: "3.11"
3030
- name: Install build dependencies
@@ -34,4 +34,4 @@ jobs:
3434
TIANGOLO_BUILD_PACKAGE: ${{ matrix.package }}
3535
run: python -m build
3636
- name: Publish
37-
uses: pypa/gh-action-pypi-publish@v1.12.4
37+
uses: pypa/gh-action-pypi-publish@v1.13.0

.github/workflows/smokeshow.yml

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -13,23 +13,20 @@ env:
1313

1414
jobs:
1515
smokeshow:
16-
if: ${{ github.event.workflow_run.conclusion == 'success' }}
1716
runs-on: ubuntu-latest
1817
steps:
19-
- uses: actions/checkout@v5
20-
- uses: actions/setup-python@v5
18+
- uses: actions/checkout@v6
19+
- uses: actions/setup-python@v6
2120
with:
22-
python-version: '3.9'
21+
python-version: '3.13'
2322
- name: Setup uv
24-
uses: astral-sh/setup-uv@v6
23+
uses: astral-sh/setup-uv@v7
2524
with:
26-
version: "0.4.15"
27-
enable-cache: true
2825
cache-dependency-glob: |
2926
requirements**.txt
3027
pyproject.toml
3128
- run: uv pip install -r requirements-github-actions.txt
32-
- uses: actions/download-artifact@v5
29+
- uses: actions/download-artifact@v7
3330
with:
3431
name: coverage-html
3532
path: htmlcov
@@ -48,7 +45,7 @@ jobs:
4845
done
4946
env:
5047
SMOKESHOW_GITHUB_STATUS_DESCRIPTION: Coverage {coverage-percentage}
51-
SMOKESHOW_GITHUB_COVERAGE_THRESHOLD: 95
48+
SMOKESHOW_GITHUB_COVERAGE_THRESHOLD: 99
5249
SMOKESHOW_GITHUB_CONTEXT: coverage
5350
SMOKESHOW_GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
5451
SMOKESHOW_GITHUB_PR_HEAD_SHA: ${{ github.event.workflow_run.head_sha }}

.github/workflows/test-redistribute.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,9 @@ jobs:
2222
env:
2323
GITHUB_CONTEXT: ${{ toJson(github) }}
2424
run: echo "$GITHUB_CONTEXT"
25-
- uses: actions/checkout@v5
25+
- uses: actions/checkout@v6
2626
- name: Set up Python
27-
uses: actions/setup-python@v5
27+
uses: actions/setup-python@v6
2828
with:
2929
python-version: "3.10"
3030
- name: Install build dependencies

0 commit comments

Comments
 (0)