Skip to content

Commit a2a0330

Browse files
authored
Merge pull request #4950 from pybamm-team/release/v25.4.0
Release v25.4.0
2 parents 817ac83 + 64df74d commit a2a0330

File tree

172 files changed

+6282
-2684
lines changed

Some content is hidden

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

172 files changed

+6282
-2684
lines changed

.all-contributorsrc

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1028,6 +1028,53 @@
10281028
"doc",
10291029
"infra"
10301030
]
1031+
},
1032+
{
1033+
"login": "vidipsingh",
1034+
"name": "Vidip Singh",
1035+
"avatar_url": "https://avatars.githubusercontent.com/u/112854574?v=4",
1036+
"profile": "https://github.com/vidipsingh",
1037+
"contributions": [
1038+
"infra"
1039+
]
1040+
},
1041+
{
1042+
"login": "chtamar",
1043+
"name": "chtamar",
1044+
"avatar_url": "https://avatars.githubusercontent.com/u/196436685?v=4",
1045+
"profile": "https://github.com/chtamar",
1046+
"contributions": [
1047+
"code",
1048+
"doc",
1049+
"test"
1050+
]
1051+
},
1052+
{
1053+
"login": "d-cogswell",
1054+
"name": "Dan Cogswell",
1055+
"avatar_url": "https://avatars.githubusercontent.com/u/51965251?v=4",
1056+
"profile": "https://dancogswell.com",
1057+
"contributions": [
1058+
"code"
1059+
]
1060+
},
1061+
{
1062+
"login": "Prtm2110",
1063+
"name": "Pratham Hole",
1064+
"avatar_url": "https://avatars.githubusercontent.com/u/139000226?v=4",
1065+
"profile": "https://github.com/Prtm2110",
1066+
"contributions": [
1067+
"test"
1068+
]
1069+
},
1070+
{
1071+
"login": "JC230903",
1072+
"name": "JC_005",
1073+
"avatar_url": "https://avatars.githubusercontent.com/u/152909047?v=4",
1074+
"profile": "https://github.com/JC230903",
1075+
"contributions": [
1076+
"infra"
1077+
]
10311078
}
10321079
],
10331080
"contributorsPerLine": 7,

.github/CODEOWNERS

Lines changed: 1 addition & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -1,34 +1,2 @@
11
# Automatically request reviews from maintainers
2-
3-
# Package
4-
src/pybamm/discretisations/ @martinjrobins @rtimms @valentinsulzer
5-
src/pybamm/experiment/ @brosaplanella @martinjrobins @rtimms @valentinsulzer @TomTranter
6-
src/pybamm/expression_tree/ @martinjrobins @rtimms @valentinsulzer
7-
src/pybamm/geometry/ @martinjrobins @rtimms @valentinsulzer
8-
src/pybamm/input/ @brosaplanella @DrSOKane @rtimms @valentinsulzer @TomTranter @kratman
9-
src/pybamm/meshes/ @martinjrobins @rtimms @valentinsulzer @rtimms
10-
src/pybamm/models/ @brosaplanella @DrSOKane @rtimms @valentinsulzer @TomTranter @rtimms
11-
src/pybamm/parameters/ @brosaplanella @DrSOKane @rtimms @valentinsulzer @TomTranter @rtimms @kratman
12-
src/pybamm/plotting/ @martinjrobins @rtimms @Saransh-cpp @valentinsulzer @rtimms @kratman @agriyakhetarpal
13-
src/pybamm/solvers/ @martinjrobins @rtimms @valentinsulzer @TomTranter @rtimms @MarcBerliner
14-
src/pybamm/spatial_methods/ @martinjrobins @rtimms @valentinsulzer @rtimms
15-
src/pybamm/* @pybamm-team/maintainers # the files directly under /pybamm/, will not recurse
16-
17-
# CI/CD workflows
18-
/.github/ @martinjrobins @Saransh-cpp @agriyakhetarpal @kratman @arjxn-py
19-
20-
# Benchmarks
21-
/benchmarks/ @brosaplanella @Saransh-cpp @agriyakhetarpal @arjxn-py
22-
23-
# Documentation
24-
/docs/ @kratman @arjxn-py @agriyakhetarpal @Saransh-cpp
25-
26-
# Example scripts
27-
/examples/ @kratman @agriyakhetarpal @Saransh-cpp
28-
29-
# Installation and other scripts
30-
/scripts/ @martinjrobins @Saransh-cpp @agriyakhetarpal @kratman @arjxn-py
31-
32-
# Files in the root directory
33-
/* @martinjrobins @Saransh-cpp @agriyakhetarpal @kratman @arjxn-py
34-
/CHANGELOG.md # no owner (almost every PR edits the CHANGELOG)
2+
* @pybamm-team/maintainers

.github/PULL_REQUEST_TEMPLATE.md

Lines changed: 9 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,26 +1,18 @@
11
# Description
22

3-
Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context. List any dependencies that are required for this change.
3+
Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context.
44

55
Fixes # (issue)
66

77
## Type of change
88

9-
Please add a line in the relevant section of [CHANGELOG.md](https://github.com/pybamm-team/PyBaMM/blob/develop/CHANGELOG.md) to document the change (include PR #) - note reverse order of PR #s. If necessary, also add to the list of breaking changes.
9+
Please add a line in the relevant section of [CHANGELOG.md](https://github.com/pybamm-team/PyBaMM/blob/develop/CHANGELOG.md) to document the change (include PR #)
1010

11-
- [ ] New feature (non-breaking change which adds functionality)
12-
- [ ] Optimization (back-end change that speeds up the code)
13-
- [ ] Bug fix (non-breaking change which fixes an issue)
11+
# Important checks:
1412

15-
# Key checklist:
16-
17-
- [ ] No style issues: `$ pre-commit run` (or `$ nox -s pre-commit`) (see [CONTRIBUTING.md](https://github.com/pybamm-team/PyBaMM/blob/develop/CONTRIBUTING.md#installing-and-using-pre-commit) for how to set this up to run automatically when committing locally, in just two lines of code)
18-
- [ ] All tests pass: `$ python -m pytest` (or `$ nox -s tests`)
19-
- [ ] The documentation builds: `$ python -m pytest --doctest-plus src` (or `$ nox -s doctests`)
20-
21-
You can run integration tests, unit tests, and doctests together at once, using `$ nox -s quick`.
22-
23-
## Further checks:
24-
25-
- [ ] Code is commented, particularly in hard-to-understand areas
26-
- [ ] Tests added that prove fix is effective or that feature works
13+
Please confirm the following before marking the PR as ready for review:
14+
- No style issues: `nox -s pre-commit`
15+
- All tests pass: `nox -s tests`
16+
- The documentation builds: `nox -s doctests`
17+
- Code is commented for hard-to-understand areas
18+
- Tests added that prove fix is effective or that feature works

.github/release_workflow.md

Lines changed: 16 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -3,44 +3,41 @@
33
This file contains the workflow required to make a `PyBaMM` release on
44
GitHub, PyPI, and conda-forge by the maintainers.
55

6-
## Initial release (automated)
6+
## Creating a release
77

8-
1. The `update_version.yml` workflow will run on every 1st of January, May
9-
and September, updating incrementing the version to `vYY.MM.0` by running
10-
`scripts/update_version.py` in the following files:
8+
1. Checkout the latest develop branch, then create a local tag `vYY.MM.0`
9+
with the new version. The year and month are taken from the date of the
10+
release. The final number represents the bug fix version, which is zero for
11+
a new release.
12+
13+
2. Run `scripts/update_version.py` to update the following files:
1114

12-
- `pybamm/version.py`
13-
- `docs/conf.py`
1415
- `CITATION.cff`
15-
- `pyproject.toml`
1616
- `CHANGELOG.md`
1717

18-
These changes will be automatically pushed to a new branch `vYY.MM`
19-
and a PR from `vYY.MM` to `main` will be created.
18+
These changes should be pushed to a release branch `vYY.MM.0`
19+
and a PR from `vYY.MM.0` to `main` needs to be created.
2020

21-
2. Create a new GitHub _release_ with the tag `vYY.MM.0` from the `vYY.MM`
22-
branch and a description copied from `CHANGELOG.md`.
21+
3. After the release PR has been merged, create a new GitHub _release_ with the
22+
tag `vYY.MM.0` from the `vYY.MM` branch and a description copied from
23+
`CHANGELOG.md`.
2324

24-
3. This release will automatically trigger `publish_pypi.yml` and create a
25+
4. This release will automatically trigger `publish_pypi.yml` and create a
2526
_release_ on PyPI.
2627

27-
## Bug fix releases (manual)
28+
## Bug fix releases
2829

29-
If a new release is required after the release of `vYY.MM.{x-1}` -
30+
If a new bugfix release is required after the release of `vYY.MM.{x-1}` -
3031

3132
1. Create a new branch for the `vYY.MM.x` release using the `vYY.MM.{x-1}` tag.
3233

3334
2. Cherry-pick the bug fixes to `vYY.MM.x` branch once the fix is
3435
merged into `develop`. The CHANGELOG entry for such fixes should go under the
3536
`YY.MM.x` heading in `CHANGELOG.md`
3637

37-
3. Run `scripts/update_version.py` manually while setting `VERSION=vYY.MM.x`
38-
in your environment. This will update the version in the following files:
38+
3. Run `scripts/update_version.py` manually to update:
3939

40-
- `pybamm/version.py`
41-
- `docs/conf.py`
4240
- `CITATION.cff`
43-
- `pyproject.toml`
4441
- `CHANGELOG.md`
4542

4643
Commit the changes to your release branch.

.github/workflows/benchmark_on_push.yml

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,9 @@ on:
33
push:
44
branches: [main, develop]
55

6+
7+
permissions: {}
8+
69
concurrency:
710
# Cancel intermediate builds always
811
group: ${{ github.workflow }}-${{ github.ref }}
@@ -14,13 +17,18 @@ env:
1417
jobs:
1518
benchmarks:
1619
runs-on: ubuntu-latest
20+
permissions:
21+
contents: read
1722
steps:
1823
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
24+
with:
25+
persist-credentials: false
1926
- name: Set up Python 3.12
20-
uses: actions/setup-python@0b93645e9fea7318ecaed2b359559ac225c90a2b # v5.3.0
27+
uses: actions/setup-python@8d9ed9ac5c53483de85588cdf95a591a75ab9f55 # v5.5.0
2128
with:
2229
python-version: 3.12
2330

31+
2432
- name: Install Linux system dependencies
2533
run: |
2634
sudo apt-get update

.github/workflows/discussion_autoresponder.yml

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,20 @@ on:
44
discussion:
55
types: [created]
66

7+
8+
permissions: {}
9+
710
jobs:
811
autorespond:
912
name: Autorespond to New Discussions
1013
runs-on: ubuntu-latest
14+
permissions:
15+
discussions: write
16+
contents: read
1117

1218
steps:
1319
- name: Run Discussion Autoresponder
14-
uses: wesleyscholl/[email protected]
20+
uses: wesleyscholl/discussion-auto-responder@b1a3c1b9a1e3d1b1a3c1b9a1e3d1b1a3c1b9a1e3 # v1.0.8
1521
with:
1622
GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}"
1723
comment_body: "Hi! We have now moved our discussions to [Discourse](https://pybamm.discourse.group/). Please post your question there."

.github/workflows/docker.yml

Lines changed: 16 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,37 +6,47 @@ on:
66
branches:
77
- develop
88

9+
permissions: {}
10+
911
jobs:
1012
build_docker_image:
1113
# This workflow is only of value to PyBaMM and would always be skipped in forks
12-
if: github.repository_owner == 'pybamm-team'
14+
if: github.repository == 'pybamm-team/PyBaMM'
1315
name: Build image
1416
runs-on: ubuntu-latest
17+
permissions:
18+
contents: read
1519

1620
steps:
1721
- name: Checkout
1822
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
23+
with:
24+
persist-credentials: false
1925

2026
- name: Set up QEMU
21-
uses: docker/setup-qemu-action@53851d14592bedcffcf25ea515637cff71ef929a # v3.3.0
27+
uses: docker/setup-qemu-action@29109295f81e9208d7d86ff1c6c12d2833863392 # v3.6.0
2228

23-
- name: Set up Docker Buildx
24-
uses: docker/setup-buildx-action@6524bf65af31da8d45b59e8c27de4bd072b392f5 # v3.8.0
2529

30+
- name: Set up Docker Buildx
31+
uses: docker/setup-buildx-action@b5ca514318bd6ebac0fb2aedd5d36ec1b5c232a2 # v3.10.0
32+
with:
33+
cache-binary: false
2634
- name: Login to Docker Hub
27-
uses: docker/login-action@9780b0c442fbb1117ed29e0efdff1e18412f7567 # v3.3.0
35+
uses: docker/login-action@74a5d142397b4f367a81961eba4e8cd7edddf772 # v3.4.0
2836
with:
2937
username: ${{ secrets.DOCKERHUB_USERNAME }}
3038
password: ${{ secrets.DOCKERHUB_TOKEN }}
3139

40+
3241
- name: Build and push Docker image to Docker Hub
33-
uses: docker/build-push-action@67a2d409c0a876cbe6b11854e3e25193efe4e62d # v6.12.0
42+
uses: docker/build-push-action@471d1dc4e07e5cdedd4c2171150001c434f0b7a4 # v6.15.0
3443
with:
3544
context: .
3645
file: scripts/Dockerfile
3746
tags: pybamm/pybamm:latest
3847
push: true
3948
platforms: linux/amd64, linux/arm64
49+
no-cache: true
4050

4151
- name: List built image(s)
4252
run: docker images

.github/workflows/lychee_url_checker.yml

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,25 +10,33 @@ on:
1010
# Run everyday at 3 am UTC
1111
- cron: "0 3 * * *"
1212

13+
14+
permissions: {}
15+
1316
jobs:
1417
linkChecker:
1518
runs-on: ubuntu-latest
19+
permissions:
20+
contents: read
21+
1622
steps:
1723

1824
# cache Lychee results to avoid hitting rate limits
1925
- name: Restore lychee cache
20-
uses: actions/cache@1bd1e32a3bdc45362d1e726936510720a7c30a57 # v4.2.0
26+
uses: actions/cache@5a3ec84eff668545956fd18022155c47e93e2684 # v4.2.3
2127
with:
2228
path: .lycheecache
2329
key: cache-lychee-${{ github.sha }}
2430
restore-keys: cache-lychee-
2531

2632
# check URLs with Lychee
2733
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
34+
with:
35+
persist-credentials: false
2836

2937
# use stable version for now to avoid breaking changes
3038
- name: Lychee URL checker
31-
uses: lycheeverse/lychee-action@f796c8b7d468feb9b8c0a46da3fac0af6874d374 # v2.2.0
39+
uses: lycheeverse/lychee-action@1d97d84f0bc547f7b25f4c2170d87d810dc2fb2c # v2.4.0
3240
with:
3341
# arguments with file types to check
3442
args: >-

.github/workflows/need_reply_remove.yml

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,13 +7,18 @@ on:
77
types:
88
- created
99

10+
permissions: {}
11+
1012
jobs:
1113
build:
1214
runs-on: ubuntu-latest
15+
permissions:
16+
issues: read
17+
contents: read
1318
if: |
1419
github.event.comment.author_association != 'OWNER' &&
1520
github.event.comment.author_association != 'COLLABORATOR' &&
16-
github.repository_owner == 'pybamm-team' &&
21+
github.repository == 'pybamm-team/PyBaMM' &&
1722
github.event_name != 'pull_request'
1823
steps:
1924
- name: Remove needs-reply label

.github/workflows/needs_reply.yml

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,16 @@ on:
44
schedule:
55
- cron: "0 0 * * *"
66

7+
8+
permissions: {}
9+
710
jobs:
811
build:
912
runs-on: ubuntu-latest
10-
if: github.repository_owner == 'pybamm-team'
13+
permissions:
14+
issues: read
15+
contents: read
16+
if: github.repository == 'pybamm-team/PyBaMM'
1117
steps:
1218
- name: Close old issues that need reply
1319
uses: dwieeb/needs-reply@71e8d5144caa0d4a1e292348bfafa3866d08c855 # v2.0.0

0 commit comments

Comments
 (0)