Skip to content

Commit c7521ad

Browse files
authored
Update pyproject.toml to be compatible with poetry 2 (#143)
* Refactor pyproject.toml to be compatible with poetry 2 * Update gate.yml to install poetry 2 instead of poetry 2 * Remove version from poetry in gate.yml install command * Bump minimum and newest Python versions in gate.yml * Bump minimum python version in `pyproject.toml`.
1 parent ed02de3 commit c7521ad

3 files changed

Lines changed: 10 additions & 14 deletions

File tree

.github/workflows/gate.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,15 +15,15 @@ jobs:
1515
runs-on: ubuntu-latest
1616
strategy:
1717
matrix:
18-
python-version: ["3.8", "3.11"]
18+
python-version: ["3.9", "3.13"]
1919
steps:
2020
- uses: actions/checkout@v4
2121
- uses: actions/setup-python@v4
2222
with:
2323
python-version: ${{ matrix.python-version }}
2424
- name: install
2525
run: |
26-
pip3 install 'poetry<2.0.0'
26+
pip3 install poetry
2727
poetry install --no-root
2828
- name: test
2929
run: |

README.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,9 @@ What the code in this repo actually does!
2727

2828
### prerequisites
2929

30+
> [!NOTE]
31+
> Poetry 2 [introduced breaking changes](https://github.com/python-poetry/poetry/issues/9136) that are not backwards compatible with Poetry 1. The pyproject.toml is compatible with Poetry 2 only - this is installed by default using the below instructions, but if you are using an already-installed copy of Poetry you should make sure to upgrade it to version 2.
32+
3033
- Install poetry https://python-poetry.org/docs/#installation
3134

3235
- Run the following command to set up the dependencies

pyproject.toml

Lines changed: 5 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,13 @@
11
[project]
22
name = "sheet-to-triples"
3-
license = {file="COPYING", name="GPL-3.0-or-later"}
3+
license = "GPL-3.0-or-later"
4+
license-files = ["COPYING"]
45
version = "0.1.0"
56
authors = [{"name"="Martin Packman", "email"="martin.packman@visual-meaning.com"}]
67
description = "Convert tabular data into triples."
78

8-
# Poetry have their own build metadata block and can't use the one in [project]
9-
# TODO: Replace poetry with a dependency management tool that can.
10-
[tool.poetry]
11-
name = "sheet-to-triples"
12-
version = "0.1.0"
13-
authors = ["Martin Packman <martin.packman@visual-meaning.com>"]
14-
description = "Convert tabular data into triples."
15-
169
[tool.poetry.dependencies]
17-
python = "^3.8.10"
10+
python = "^3.9.13"
1811
pycountry = "^22"
1912
# openpyxl broke parsing some workbooks with filters and the maintainer made
2013
# the classic mistake of blocking the regression fix on a rethink of how
@@ -26,10 +19,10 @@ openpyxl = "=3.0.10"
2619
rdflib = {version = "^7", extras = ["sparql"]}
2720
xlrd = "^2"
2821

29-
[tool.poetry.dev-dependencies]
22+
[tool.poetry.group.dev.dependencies]
3023
ruff = "^0.0.292"
3124
coverage = "^7"
32-
pyfakefs = "^5"
25+
pyfakefs = "^5.7.0"
3326

3427
[tool.ruff]
3528
select = ["C9", "E", "F", "W"]

0 commit comments

Comments
 (0)