Skip to content

Commit abffc1e

Browse files
authored
Merge branch 'master' into fix_issue_6921_atomic_requests
2 parents 5c65845 + 376026c commit abffc1e

350 files changed

Lines changed: 23428 additions & 11132 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/FUNDING.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
1+
github: encode
12
custom: https://fund.django-rest-framework.org/topics/funding/

.github/dependabot.yml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
# Keep GitHub Actions up to date with GitHub's Dependabot...
2+
# https://docs.github.com/en/code-security/dependabot/working-with-dependabot/keeping-your-actions-up-to-date-with-dependabot
3+
# https://docs.github.com/en/code-security/dependabot/dependabot-version-updates/configuration-options-for-the-dependabot.yml-file#package-ecosystem
4+
version: 2
5+
updates:
6+
- package-ecosystem: github-actions
7+
directory: /
8+
groups:
9+
github-actions:
10+
patterns:
11+
- "*" # Group all Action updates into a single larger pull request
12+
schedule:
13+
interval: weekly

.github/stale.yml

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
# Documentation: https://github.com/probot/stale
2+
3+
# Number of days of inactivity before an issue becomes stale
4+
daysUntilStale: 60
5+
6+
# Number of days of inactivity before a stale issue is closed
7+
daysUntilClose: 7
8+
9+
# Comment to post when marking an issue as stale. Set to `false` to disable
10+
markComment: >
11+
This issue has been automatically marked as stale because it has not had
12+
recent activity. It will be closed if no further activity occurs. Thank you
13+
for your contributions.
14+
15+
# Comment to post when closing a stale issue. Set to `false` to disable
16+
closeComment: false
17+
18+
# Limit the number of actions per hour, from 1-30. Default is 30
19+
limitPerRun: 1
20+
21+
# Label to use when marking as stale
22+
staleLabel: stale

.github/workflows/main.yml

Lines changed: 73 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,73 @@
1+
name: CI
2+
3+
on:
4+
push:
5+
branches:
6+
- master
7+
pull_request:
8+
9+
jobs:
10+
tests:
11+
name: Python ${{ matrix.python-version }}
12+
runs-on: ubuntu-24.04
13+
14+
strategy:
15+
matrix:
16+
python-version:
17+
- '3.9'
18+
- '3.10'
19+
- '3.11'
20+
- '3.12'
21+
- '3.13'
22+
23+
steps:
24+
- uses: actions/checkout@v4
25+
26+
- uses: actions/setup-python@v5
27+
with:
28+
python-version: ${{ matrix.python-version }}
29+
cache: 'pip'
30+
cache-dependency-path: 'requirements/*.txt'
31+
32+
- name: Upgrade packaging tools
33+
run: python -m pip install --upgrade pip setuptools virtualenv wheel
34+
35+
- name: Install dependencies
36+
run: python -m pip install --upgrade tox
37+
38+
- name: Run tox targets for ${{ matrix.python-version }}
39+
run: tox run -f py$(echo ${{ matrix.python-version }} | tr -d . | cut -f 1 -d '-')
40+
41+
- name: Run extra tox targets
42+
if: ${{ matrix.python-version == '3.9' }}
43+
run: |
44+
tox -e base,dist,docs
45+
46+
- name: Upload coverage
47+
uses: codecov/codecov-action@v5
48+
with:
49+
env_vars: TOXENV,DJANGO
50+
51+
test-docs:
52+
name: Test documentation links
53+
runs-on: ubuntu-24.04
54+
steps:
55+
- uses: actions/checkout@v4
56+
57+
- uses: actions/setup-python@v5
58+
with:
59+
python-version: '3.9'
60+
61+
- name: Install dependencies
62+
run: pip install -r requirements/requirements-documentation.txt
63+
64+
# Start mkdocs server and wait for it to be ready
65+
- run: mkdocs serve &
66+
- run: WAIT_TIME=0 && until nc -vzw 2 localhost 8000 || [ $WAIT_TIME -eq 5 ]; do sleep $(( WAIT_TIME++ )); done
67+
- run: if [ $WAIT_TIME == 5 ]; then echo cannot start mkdocs server on http://localhost:8000; exit 1; fi
68+
69+
- name: Check links
70+
continue-on-error: true
71+
run: pylinkvalidate.py -P http://localhost:8000/
72+
73+
- run: echo "Done"

.github/workflows/pre-commit.yml

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
name: pre-commit
2+
3+
on:
4+
push:
5+
branches:
6+
- master
7+
pull_request:
8+
9+
jobs:
10+
pre-commit:
11+
runs-on: ubuntu-latest
12+
13+
steps:
14+
- uses: actions/checkout@v4
15+
with:
16+
fetch-depth: 0
17+
18+
- uses: actions/setup-python@v5
19+
with:
20+
python-version: "3.10"
21+
22+
- uses: pre-commit/action@v3.0.1

.gitignore

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
*.db
33
*~
44
.*
5+
*.py.bak
6+
57

68
/site/
79
/htmlcov/
@@ -13,6 +15,6 @@
1315
MANIFEST
1416
coverage.*
1517

18+
!.github
1619
!.gitignore
17-
!.travis.yml
18-
!.isort.cfg
20+
!.pre-commit-config.yaml

.pre-commit-config.yaml

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
repos:
2+
- repo: https://github.com/pre-commit/pre-commit-hooks
3+
rev: v4.5.0
4+
hooks:
5+
- id: check-added-large-files
6+
- id: check-case-conflict
7+
- id: check-json
8+
- id: check-merge-conflict
9+
- id: check-symlinks
10+
- id: check-toml
11+
- repo: https://github.com/pycqa/isort
12+
rev: 5.13.2
13+
hooks:
14+
- id: isort
15+
- repo: https://github.com/PyCQA/flake8
16+
rev: 7.0.0
17+
hooks:
18+
- id: flake8
19+
additional_dependencies:
20+
- flake8-tidy-imports
21+
- repo: https://github.com/adamchainz/blacken-docs
22+
rev: 1.16.0
23+
hooks:
24+
- id: blacken-docs
25+
exclude: ^(?!docs).*$
26+
additional_dependencies:
27+
- black==23.1.0
28+
- repo: https://github.com/codespell-project/codespell
29+
# Configuration for codespell is in .codespellrc
30+
rev: v2.2.6
31+
hooks:
32+
- id: codespell
33+
exclude: locale|kickstarter-announcement.md|coreapi-0.1.1.js
34+
35+
- repo: https://github.com/asottile/pyupgrade
36+
rev: v3.19.1
37+
hooks:
38+
- id: pyupgrade
39+
args: ["--py39-plus", "--keep-percent-format"]

.travis.yml

Lines changed: 0 additions & 55 deletions
This file was deleted.

.tx/config

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
[main]
2+
host = https://www.transifex.com
3+
lang_map = sr@latin:sr_Latn, zh-Hans:zh_Hans, zh-Hant:zh_Hant
4+
5+
[django-rest-framework.djangopo]
6+
file_filter = rest_framework/locale/<lang>/LC_MESSAGES/django.po
7+
source_file = rest_framework/locale/en_US/LC_MESSAGES/django.po
8+
source_lang = en_US
9+
type = PO

0 commit comments

Comments
 (0)