Repository: pybamm-team/liionpack (language: python)

Issue:
liionpack does not work on Python 3.7
### Discussed in https://github.com/pybamm-team/liionpack/discussions/214

<div type='discussions-op-text'>

<sup>Originally posted by **frivollier** January 14, 2023</sup>
I am looking for help with liionpack  https://github.com/pybamm-team/liionpack

I am getting the following type KeyError while running all examples.  (this is  error from  the example git home page readme.md)


`Traceback (most recent call last):
  File "/Users/frivollier/software_local/BESSTools1/liionpack_DT/test.py", line 46, in <module>
    manager='casadi')
  File "/Users/frivollier/software_local/BESSTools1/venv/lib/python3.7/site-packages/liionpack/solver_utils.py", line 441, in solve
    setup_only=False,
  File "/Users/frivollier/software_local/BESSTools1/venv/lib/python3.7/site-packages/liionpack/solvers.py", line 317, in solve
    self.protocol = lp.generate_protocol_from_experiment(experiment, flatten=True)
  File "/Users/frivollier/software_local/BESSTools1/venv/lib/python3.7/site-packages/liionpack/protocols.py", line 30, in generate_protocol_from_experiment
    typ = op["type"]
KeyError: 'type'
`
running on mac python 3.7

thanks for pointing me in the right direction for some help.

Regards,

Fred

</div>


Discussion / hints:
## Issue
liionpack supports Python 3.7, 3.8, and 3.9, but pybamm’s recent version only supports 3.8 and 3.9. Installing liionpack on Python 3.7 works, but it installs an older version of pybamm (a version that supports Python 3.7). This older version of pybamm is incompatible with liionpack’s latest version, which results in errors.

## Solution
Drop Python 3.7 support :slightly_smiling_face:

---

Creating a PR.

Fix patch:
diff --git a/pyproject.toml b/pyproject.toml
index 4b2fdcf4..3bb425bc 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -12,7 +12,7 @@ license = "MIT"
 authors = [
     { name = "Tom Tranter", email = "t.g.tranter@gmail.com" },
 ]
-requires-python = ">=3.7"
+requires-python = ">=3.8"
 classifiers = [
     "Development Status :: 4 - Beta",
     "Intended Audience :: Developers",
@@ -21,7 +21,6 @@ classifiers = [
     "Programming Language :: Python",
     "Programming Language :: Python :: 3",
     "Programming Language :: Python :: 3 :: Only",
-    "Programming Language :: Python :: 3.7",
     "Programming Language :: Python :: 3.8",
     "Programming Language :: Python :: 3.9",
     "Topic :: Scientific/Engineering",


Test patch:
diff --git a/.github/workflows/test_on_push.yml b/.github/workflows/test_on_push.yml
index cf4bd1d3..c08d1c58 100644
--- a/.github/workflows/test_on_push.yml
+++ b/.github/workflows/test_on_push.yml
@@ -37,13 +37,17 @@ jobs:
   pip-build:
     needs: style
     runs-on: ubuntu-latest
+    strategy:
+      fail-fast: false
+      matrix:
+        python-version: [3.8, 3.9]
 
     steps:
     - uses: actions/checkout@v3
     - name: Set up Python 3.8
       uses: actions/setup-python@v4
       with:
-        python-version: 3.8
+        python-version: ${{ matrix.python-version }}
 
     - name: Install latex
       run: |