From 09cb66528ae37daebb3fef23b10e83c60b92796e Mon Sep 17 00:00:00 2001 From: Brady Planden Date: Mon, 8 Jul 2024 11:00:42 +0100 Subject: [PATCH 1/6] fix: API render, version switcher --- docs/_static/switcher.json | 16 +++++++++++++--- docs/_templates/autoapi/index.rst | 2 ++ docs/conf.py | 2 +- 3 files changed, 16 insertions(+), 4 deletions(-) diff --git a/docs/_static/switcher.json b/docs/_static/switcher.json index 5db09bc1..03a97873 100644 --- a/docs/_static/switcher.json +++ b/docs/_static/switcher.json @@ -4,9 +4,19 @@ "url": "https://pybop-docs.readthedocs.io/en/latest/" }, { - "name": "v23.12 (stable)", - "version": "v23.12", - "url": "https://pybop-docs.readthedocs.io/en/v23.12/", + "name": "v24.6 (stable)", + "version": "v24.6", + "url": "https://pybop-docs.readthedocs.io/en/v24.6/", "preferred": true + }, + { + "name": "v24.3.1", + "version": "v24.3.1", + "url": "https://pybop-docs.readthedocs.io/en/v24.3.1/" + }, + { + "name": "v23.12", + "version": "v23.12", + "url": "https://pybop-docs.readthedocs.io/en/v23.12/" } ] diff --git a/docs/_templates/autoapi/index.rst b/docs/_templates/autoapi/index.rst index d6075995..7cc11171 100644 --- a/docs/_templates/autoapi/index.rst +++ b/docs/_templates/autoapi/index.rst @@ -15,4 +15,6 @@ This page contains auto-generated API reference documentation [#f1]_. {% endif %} {% endfor %} + pybop/index + .. [#f1] Created with `sphinx-autoapi `_ diff --git a/docs/conf.py b/docs/conf.py index cfc37a90..df93a8fa 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -39,7 +39,7 @@ # -- Options for autoapi ------------------------------------------------------- autoapi_type = "python" autoapi_dirs = ["../pybop"] -autoapi_keep_files = True +autoapi_keep_files = False autoapi_root = "api" autoapi_member_order = "groupwise" From a9c3547f8f57d9af5d43584a1da26949e665948e Mon Sep 17 00:00:00 2001 From: Brady Planden Date: Mon, 8 Jul 2024 11:10:41 +0100 Subject: [PATCH 2/6] update release_worklfow.md for docs version switcher --- .github/release_workflow.md | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/release_workflow.md b/.github/release_workflow.md index a655f9fe..97fc65d6 100644 --- a/.github/release_workflow.md +++ b/.github/release_workflow.md @@ -11,6 +11,7 @@ To create a new release, follow these steps: - Increment the following; - The version number in the `pyproject.toml` and `CITATION.cff` files following CalVer versioning. - The`CHANGELOG.md` version with the changes for the new version. + - Add a new entry for the documentation site version switcher located at `docs/_static/switcher.json` - Open a PR to the `main` branch. Once the PR is merged, proceed to the next step. 2. **Tag the Release:** From 184bb15963ed112c6ec78cb466e2a8c9ba7e6357 Mon Sep 17 00:00:00 2001 From: Brady Planden Date: Mon, 8 Jul 2024 11:40:14 +0100 Subject: [PATCH 3/6] docs: revert v24.3.1 docs to v24.3 --- docs/_static/switcher.json | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/_static/switcher.json b/docs/_static/switcher.json index 03a97873..2847bc26 100644 --- a/docs/_static/switcher.json +++ b/docs/_static/switcher.json @@ -10,9 +10,9 @@ "preferred": true }, { - "name": "v24.3.1", - "version": "v24.3.1", - "url": "https://pybop-docs.readthedocs.io/en/v24.3.1/" + "name": "v24.3", + "version": "v24.3", + "url": "https://pybop-docs.readthedocs.io/en/v24.3/" }, { "name": "v23.12", From 812e25b11efc20bbc360b056e6ed12bb68b77006 Mon Sep 17 00:00:00 2001 From: Brady Planden Date: Mon, 8 Jul 2024 12:32:37 +0100 Subject: [PATCH 4/6] fix: api ref in installation.md --- docs/installation.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/installation.rst b/docs/installation.rst index 3c0080c1..b9d1462a 100644 --- a/docs/installation.rst +++ b/docs/installation.rst @@ -68,4 +68,4 @@ Next Steps After installing PyBOP, you might want to: * Explore the `Quick Start Guide `_ to begin using PyBOP. -* Check out the `API Reference <../api/index.html>`_ for detailed information on PyBOP's programming interface. +* Check out the `API Reference `_ for detailed information on PyBOP's programming interface. From c945ce5613decdb53473aa24679fc57bae397e2d Mon Sep 17 00:00:00 2001 From: Brady Planden Date: Mon, 8 Jul 2024 12:52:58 +0100 Subject: [PATCH 5/6] fix: broken links, stale contributing information --- CONTRIBUTING.md | 4 +--- docs/installation.rst | 2 +- docs/quick_start.rst | 2 +- 3 files changed, 3 insertions(+), 5 deletions(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 0f3a7f07..727c5c51 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -70,7 +70,7 @@ You now have everything you need to start making changes! ### C. Merging your changes with PyBOP 10. [Test your code!](#testing) -12. If you added a major new feature, perhaps it should be showcased in an [example notebook](#example-notebooks). +12. If you added a major new feature, perhaps it should be showcased in an [example notebook](https://github.com/pybop-team/PyBOP/tree/develop/examples/notebooks). 13. If you've added new functionality, please add additional tests to ensure ample code coverage in PyBOP. 13. When you feel your code is finished, or at least warrants serious discussion, create a [pull request](https://help.github.com/articles/about-pull-requests/) (PR) on [PyBOP's GitHub page](https://github.com/pybop-team/PyBOP). 14. Once a PR has been created, it will be reviewed by any member of the community. Changes might be suggested which you can make by simply adding new commits to the branch. When everything's finished, someone with the right GitHub permissions will merge your changes into PyBOP main repository. @@ -314,8 +314,6 @@ Configuration files: pyproject.toml ``` -Note that this file must be kept in sync with the version number in [pybop/**init**.py](https://github.com/pybop-team/PyBOP/blob/develop/pybop/__init__.py). - ### Continuous Integration using GitHub actions Each change pushed to the PyBOP GitHub repository will trigger the test and benchmark suites to be run, using [GitHub actions](https://github.com/features/actions). diff --git a/docs/installation.rst b/docs/installation.rst index b9d1462a..0a1f3abe 100644 --- a/docs/installation.rst +++ b/docs/installation.rst @@ -55,7 +55,7 @@ To verify that PyBOP has been installed successfully, try running one of the pro For Developers -------------- -If you are installing PyBOP for development purposes, such as contributing to the project, please ensure that you follow the guidelines outlined in the `Contributing Guide <../Contributing.html>`_. It includes additional steps that might be necessary for setting up a development environment, including the installation of dependencies and setup of pre-commit hooks. +If you are installing PyBOP for development purposes, such as contributing to the project, please ensure that you follow the guidelines outlined in the `Contributing Guide `_. It includes additional steps that might be necessary for setting up a development environment, including the installation of dependencies and setup of pre-commit hooks. Further Assistance ------------------ diff --git a/docs/quick_start.rst b/docs/quick_start.rst index 683c82b4..1a3a3508 100644 --- a/docs/quick_start.rst +++ b/docs/quick_start.rst @@ -55,4 +55,4 @@ If you encounter any issues or have questions as you start using PyBOP, don't he - **GitHub Issues**: Report bugs or request new features by opening an `Issue `_ - **GitHub Discussions**: Post your questions or feedback on our `GitHub Discussions `_ -- **Contributions**: Interested in contributing to PyBOP? Check out our `Contributing Guide <../Contributing.html>`_ for guidelines. +- **Contributions**: Interested in contributing to PyBOP? Check out our `Contributing Guide `_ for guidelines. From b4499f15b91776327f494fdaa237a7bdab845631 Mon Sep 17 00:00:00 2001 From: Brady Planden Date: Mon, 8 Jul 2024 13:00:02 +0100 Subject: [PATCH 6/6] fix: grammar --- docs/index.md | 2 +- docs/installation.rst | 2 +- docs/quick_start.rst | 6 +++--- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/docs/index.md b/docs/index.md index d45182ae..4d562165 100644 --- a/docs/index.md +++ b/docs/index.md @@ -8,7 +8,7 @@ html_theme.sidebar_secondary.remove: true # PyBOP: Optimise and Parameterise Battery Models -Welcome to PyBOP, a Python package dedicated to the optimization and parameterization of battery models. PyBOP is designed to streamline your workflow, whether you are conducting academic research, working in industry, or simply interested in battery technology and modelling. +Welcome to PyBOP, a Python package dedicated to the optimisation and parameterisation of battery models. PyBOP is designed to streamline your workflow, whether you are conducting academic research, working in industry, or simply interested in battery technology and modelling. ```{gallery-grid} :grid-columns: 1 2 2 2 diff --git a/docs/installation.rst b/docs/installation.rst index 0a1f3abe..6bc3169c 100644 --- a/docs/installation.rst +++ b/docs/installation.rst @@ -3,7 +3,7 @@ Installation ***************************** -PyBOP is a versatile Python package designed for optimization and parameterization of battery models. Follow the instructions below to install PyBOP and set up your environment to begin utilizing its capabilities. +PyBOP is a versatile Python package designed for optimisation and parameterisation of battery models. Follow the instructions below to install PyBOP and set up your environment to begin utilising its capabilities. Installing PyBOP with pip ------------------------- diff --git a/docs/quick_start.rst b/docs/quick_start.rst index 1a3a3508..1a1617bd 100644 --- a/docs/quick_start.rst +++ b/docs/quick_start.rst @@ -6,7 +6,7 @@ Welcome to the Quick Start Guide for PyBOP. This guide will help you get up and Getting Started with PyBOP -------------------------- -PyBOP is equipped with a series of robust tools that can help you optimize various parameters within your battery models to better match empirical data or to explore the effects of different parameters on battery behavior. +PyBOP is equipped with a series of robust tools that can help you optimise various parameters within your battery models to better match empirical data or to explore the effects of different parameters on battery behavior. To begin using PyBOP: @@ -24,14 +24,14 @@ To begin using PyBOP: import pybop - Now you're ready to utilize PyBOP's functionality in your projects! + Now you're ready to utilise PyBOP's functionality in your projects! Exploring Examples ------------------ To help you get acquainted with PyBOP's capabilities, we provide a collection of examples that demonstrate common use cases and features of the package: -- **Jupyter Notebooks**: Interactive notebooks that include detailed explanations alongside the live code, visualizations, and results. These are an excellent resource for learning and can be easily modified and executed to suit your needs. +- **Jupyter Notebooks**: Interactive notebooks that include detailed explanations alongside the live code, visualisations, and results. These are an excellent resource for learning and can be easily modified and executed to suit your needs. - **Python Scripts**: For those who prefer working in a text editor, IDE, or for integrating into larger projects, we provide equivalent examples in plain Python script format.