Skip to content

Commit 75209df

Browse files
authored
Merge pull request #4 from opensafely-core/sync-fork
Sync fork with upstream repo
2 parents 153a0ca + 9d56f5f commit 75209df

28 files changed

Lines changed: 223 additions & 208 deletions

.editorconfig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Licensed under the Apache License: http://www.apache.org/licenses/LICENSE-2.0
2-
# For details: https://github.com/nedbat/django_coverage_plugin/blob/master/NOTICE.txt
2+
# For details: https://github.com/coveragepy/django_coverage_plugin/blob/main/NOTICE.txt
33

44
# This file is for unifying the coding style for different editors and IDEs.
55
# More information at http://EditorConfig.org

.github/dependabot.yml

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# From:
2+
# https://docs.github.com/en/code-security/supply-chain-security/keeping-your-dependencies-updated-automatically/keeping-your-actions-up-to-date-with-dependabot
3+
# Set update schedule for GitHub Actions
4+
5+
version: 2
6+
updates:
7+
- package-ecosystem: "github-actions"
8+
directory: "/"
9+
schedule:
10+
# Check for updates to GitHub Actions once a week
11+
interval: "weekly"
12+
day: "sunday"
13+
cooldown:
14+
# https://blog.yossarian.net/2025/11/21/We-should-all-be-using-dependency-cooldowns
15+
default-days: 7
16+
groups:
17+
action-dependencies:
18+
patterns:
19+
- "*"
20+
commit-message:
21+
prefix: "chore"

.github/workflows/tests.yml

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -41,19 +41,21 @@ jobs:
4141
python-version:
4242
# When changing this list, be sure to check the [gh-actions] list in
4343
# tox.ini so that tox will run properly.
44-
- "3.8"
45-
- "3.9"
4644
- "3.10"
4745
- "3.11"
4846
- "3.12"
47+
- "3.13"
48+
- "3.14"
4949
fail-fast: false
5050

5151
steps:
5252
- name: "Check out the repo"
53-
uses: "actions/checkout@v3"
53+
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
54+
with:
55+
persist-credentials: false
5456

5557
- name: "Set up Python"
56-
uses: "actions/setup-python@v4"
58+
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
5759
with:
5860
python-version: "${{ matrix.python-version }}"
5961
allow-prereleases: true
@@ -85,12 +87,14 @@ jobs:
8587

8688
steps:
8789
- name: "Check out the repo"
88-
uses: "actions/checkout@v2"
90+
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
91+
with:
92+
persist-credentials: false
8993

9094
- name: "Set up Python"
91-
uses: "actions/setup-python@v2"
95+
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
9296
with:
93-
python-version: "3.8"
97+
python-version: "3.10"
9498

9599
- name: "Install dependencies"
96100
run: |

MANIFEST.in

Lines changed: 9 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,12 @@
11
# Licensed under the Apache 2.0 License
22
# - http://www.apache.org/licenses/LICENSE-2.0
3-
# - https://github.com/nedbat/django_coverage_plugin/blob/master/NOTICE.txt
3+
# - https://github.com/coveragepy/django_coverage_plugin/blob/main/NOTICE.txt
44

5-
exclude .isort.cfg
6-
exclude howto.txt
7-
exclude Makefile
8-
exclude requirements.txt
9-
exclude tox.ini
10-
exclude .editorconfig
11-
include AUTHORS.txt
12-
include LICENSE.txt
13-
include NOTICE.txt
14-
include README.rst
15-
prune tests
5+
include *.txt
6+
include .editorconfig
7+
include .isort.cfg
8+
include Makefile
9+
include tox.ini
10+
11+
recursive-include .github *
12+
recursive-include tests *.py

Makefile

Lines changed: 14 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,10 @@
11
# Licensed under the Apache License: http://www.apache.org/licenses/LICENSE-2.0
2-
# For details: https://github.com/nedbat/django_coverage_plugin/blob/master/NOTICE.txt
2+
# For details: https://github.com/coveragepy/django_coverage_plugin/blob/main/NOTICE.txt
33

44
# Makefile for django_coverage_plugin
55

6+
.PHONY: help test clean sterile dist pypi test_pypi tag ghrelease
7+
68
help: ## Show this help.
79
@echo "Available targets:"
810
@grep '^[a-zA-Z]' $(MAKEFILE_LIST) | sort | awk -F ':.*?## ' 'NF==2 {printf " %-26s%s\n", $$1, $$2}'
@@ -24,15 +26,22 @@ clean: ## Remove non-source files.
2426
sterile: clean ## Remove all non-controlled content, even if expensive.
2527
-rm -rf .tox*
2628

27-
kit: ## Make the source distribution.
29+
dist: ## Make the source distribution.
2830
python -m build
2931
python -m twine check dist/*
3032

31-
kit_upload: ## Upload the built distributions to PyPI.
33+
pypi: ## Upload the built distributions to PyPI.
3234
python -m twine upload --verbose dist/*
3335

34-
tag: ## Make a git tag with the version number.
35-
git tag -s -m "Version v$$(python setup.py --version)" v$$(python setup.py --version)
36+
test_pypi: ## Upload the distributions to test PyPI.
37+
python -m twine upload --verbose --repository testpypi --password $$TWINE_TEST_PASSWORD dist/*
38+
39+
_install_e:
40+
python -m pip install -q -e .
41+
42+
tag: _install_e ## Make a git tag with the version number.
43+
@export VER="$$(python -c "import django_coverage_plugin as me; print(me.__version__)")" && \
44+
git tag -s -m "Version v$$VER" v$$VER
3645
git push --all
3746

3847
ghrelease: ## Make a GitHub release for the latest version.

NOTICE.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
Copyright 2015-2022 Ned Batchelder. All rights reserved.
1+
Copyright 2015-2025 Ned Batchelder. All rights reserved.
22

33
Except where noted otherwise, this software is licensed under the Apache
44
License, Version 2.0 (the "License"); you may not use this work except in

README.rst

Lines changed: 37 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,9 @@ Django Template Coverage.py Plugin
44

55
A `coverage.py`_ plugin to measure test coverage of Django templates.
66

7-
.. start-badges
8-
97
| |status| |kit| |license|
108
| |versions| |djversions|
9+
| |sponsor| |bluesky-nedbat| |mastodon-nedbat|
1110
1211
.. |status| image:: https://img.shields.io/pypi/status/django_coverage_plugin.svg
1312
:target: https://pypi.python.org/pypi/django_coverage_plugin
@@ -21,23 +20,31 @@ A `coverage.py`_ plugin to measure test coverage of Django templates.
2120
.. |versions| image:: https://img.shields.io/pypi/pyversions/django_coverage_plugin.svg
2221
:target: https://pypi.python.org/pypi/django_coverage_plugin
2322
:alt: Supported Python Versions
24-
.. |djversions| image:: https://img.shields.io/badge/Django-1.8%20%7C%201.11%20%7C%202.2%20%7C%203.2%20%7C%204.1-44b78b.svg
23+
.. the Django badge says: `3.2 | 4.2 | 5.2`
24+
.. |djversions| image:: https://img.shields.io/badge/Django-3.2%20%7C%204.2%20%7C%205.2-44b78b.svg
2525
:target: https://pypi.python.org/pypi/django_coverage_plugin
2626
:alt: Supported Django Versions
27+
.. |sponsor| image:: https://img.shields.io/badge/%E2%9D%A4-Sponsor%20me-brightgreen?style=flat&logo=GitHub
28+
:target: https://github.com/sponsors/nedbat
29+
:alt: Sponsor me on GitHub
30+
.. |bluesky-nedbat| image:: https://img.shields.io/badge/dynamic/json?style=flat&color=96a3b0&labelColor=3686f7&logo=icloud&logoColor=white&label=@nedbat&url=https%3A%2F%2Fpublic.api.bsky.app%2Fxrpc%2Fapp.bsky.actor.getProfile%3Factor=nedbat.com&query=followersCount
31+
:target: https://bsky.app/profile/nedbat.com
32+
:alt: nedbat on Bluesky
33+
.. |mastodon-nedbat| image:: https://img.shields.io/badge/dynamic/json?style=flat&labelColor=450657&logo=mastodon&logoColor=ffffff&label=@nedbat&query=followers_count&url=https%3A%2F%2Fhachyderm.io%2Fapi%2Fv1%2Faccounts%2Flookup%3Facct=nedbat
34+
:target: https://hachyderm.io/@nedbat
35+
:alt: nedbat on Mastodon
2736

28-
------------------
2937

30-
.. end-badges
3138

3239
Supported on:
3340

34-
- Python: 3.8 through 3.12.
41+
- Python: 3.10 through 3.14.
3542

36-
- Django: 2.x, 3.x and 4.x.
43+
- Django: 3.2 through 5.2.
3744

3845
- Coverage.py: 6.x or higher.
3946

40-
The plugin is pip installable::
47+
The plugin is pip-installable::
4148

4249
$ python3 -m pip install django_coverage_plugin
4350

@@ -49,8 +56,7 @@ To run it, add this setting to your ``.coveragerc`` file::
4956
Then run your tests under `coverage.py`_.
5057

5158
You will see your templates listed in your coverage report along with
52-
your Python modules. Please use `coverage.py`_ v4.4 or greater to allow
53-
the plugin to identify untested templates.
59+
your Python modules.
5460

5561
If you get a :code:`django.core.exceptions.ImproperlyConfigured` error,
5662
you need to set the :code:`DJANGO_SETTINGS_MODULE` environment variable.
@@ -137,6 +143,18 @@ History
137143

138144
.. scriv-insert-here
139145
146+
v3.2.0 — 2025-10-05
147+
-------------------
148+
149+
Drop Python 3.9 and Django 2.2. Add Python 3.14.
150+
151+
152+
v3.1.1 — 2025-06-15
153+
-------------------
154+
155+
Support changes: dropped Python 3.8, added Python 3.13. Added Django 5.2.
156+
157+
140158
v3.1.0 — 2023-07-10
141159
-------------------
142160

@@ -173,7 +191,7 @@ ignore_errors=True`` (`issue 78`_).
173191
When using ``source=.``, an existing coverage HTML report directory would be
174192
found and believed to be unmeasured HTML template files. This is now fixed.
175193

176-
.. _issue 78: https://github.com/nedbat/django_coverage_plugin/issues/78
194+
.. _issue 78: https://github.com/coveragepy/django_coverage_plugin/issues/78
177195

178196

179197
v2.0.1 — 2021-10-06
@@ -196,9 +214,9 @@ case-sensitively, causing templates to be missed (`issue 46`_).
196214
Fix an issue (`issue 63`_) where tag libraries can't be found if imported
197215
during test collection. Thanks to Daniel Izquierdo for the fix.
198216

199-
.. _issue 46: https://github.com/nedbat/django_coverage_plugin/issues/46
200-
.. _issue 60: https://github.com/nedbat/django_coverage_plugin/issues/60
201-
.. _issue 63: https://github.com/nedbat/django_coverage_plugin/issues/63
217+
.. _issue 46: https://github.com/coveragepy/django_coverage_plugin/issues/46
218+
.. _issue 60: https://github.com/coveragepy/django_coverage_plugin/issues/60
219+
.. _issue 63: https://github.com/coveragepy/django_coverage_plugin/issues/63
202220

203221
v1.8.0 — 2020-01-23
204222
-------------------
@@ -248,7 +266,7 @@ v1.4.2 — 2017-02-06
248266
Fixes another instance of `issue 32`_, which was the result of an
249267
initialization order problem.
250268

251-
.. _issue 32: https://github.com/nedbat/django_coverage_plugin/issues/32
269+
.. _issue 32: https://github.com/coveragepy/django_coverage_plugin/issues/32
252270

253271

254272
v1.4.1 — 2017-01-25
@@ -270,8 +288,8 @@ Only the ``django.template.backends.django.DjangoTemplates`` template
270288
engine is supported, and it must be configured with
271289
``['OPTIONS']['debug'] = True``. Fixes `issue 27`_.
272290

273-
.. _issue 28: https://github.com/nedbat/django_coverage_plugin/issues/28
274-
.. _issue 27: https://github.com/nedbat/django_coverage_plugin/issues/27
291+
.. _issue 28: https://github.com/coveragepy/django_coverage_plugin/issues/28
292+
.. _issue 27: https://github.com/coveragepy/django_coverage_plugin/issues/27
275293

276294

277295

@@ -281,7 +299,7 @@ v1.3.1 — 2016-06-02
281299
Settings are read slightly differently, so as to not interfere with
282300
programs that don't need settings. Fixes `issue 18`_.
283301

284-
.. _issue 18: https://github.com/nedbat/django_coverage_plugin/issues/18
302+
.. _issue 18: https://github.com/coveragepy/django_coverage_plugin/issues/18
285303

286304

287305

@@ -317,7 +335,7 @@ plugin, and fixes `issue 17`_.
317335
Potential Django 1.9 support is included, but the patch to Django hasn't
318336
been applied yet.
319337

320-
.. _issue 17: https://github.com/nedbat/django_coverage_plugin/issues/17
338+
.. _issue 17: https://github.com/coveragepy/django_coverage_plugin/issues/17
321339

322340

323341

django_coverage_plugin/__init__.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,10 @@
11
# Licensed under the Apache License: http://www.apache.org/licenses/LICENSE-2.0
2-
# For details: https://github.com/nedbat/django_coverage_plugin/blob/master/NOTICE.txt
2+
# For details: https://github.com/coveragepy/django_coverage_plugin/blob/main/NOTICE.txt
33

44
"""Django Template Coverage Plugin"""
55

6+
__version__ = "3.2.0"
7+
68
from .plugin import DjangoTemplatePluginException # noqa
79
from .plugin import DjangoTemplatePlugin
810

0 commit comments

Comments
 (0)