From 86c2ec94d3f60c13098349a6d28b6289ebd3d1c8 Mon Sep 17 00:00:00 2001 From: Mauko Quiroga Date: Fri, 18 Oct 2024 12:48:59 +0200 Subject: [PATCH] fix: package name --- .github/workflows/workflow.yml | 2 +- .yamllint | 4 ---- Makefile | 5 +---- openfisca_extension_template/tests/test_api.py | 2 +- pyproject.toml | 14 ++++---------- 5 files changed, 7 insertions(+), 20 deletions(-) diff --git a/.github/workflows/workflow.yml b/.github/workflows/workflow.yml index ea2da34..8612f10 100644 --- a/.github/workflows/workflow.yml +++ b/.github/workflows/workflow.yml @@ -128,7 +128,7 @@ jobs: pyproject.toml key: tests-${{ github.sha }} - - name: Lint files + - name: Check built package run: tox -r -e dist check-version-and-changelog: diff --git a/.yamllint b/.yamllint index 2883d60..1f20366 100644 --- a/.yamllint +++ b/.yamllint @@ -1,6 +1,2 @@ --- - extends: relaxed - -rules: - line-length: disable diff --git a/Makefile b/Makefile index 4346662..0b00604 100644 --- a/Makefile +++ b/Makefile @@ -18,15 +18,12 @@ install: format: @# Do not analyse .gitignored files. @# `make` needs `$$` to output `$`. Ref: http://stackoverflow.com/questions/2382764. - black `git ls-files | grep "\.py$$"` - isort `git ls-files | grep "\.py$$"` - pyproject-fmt pyproject.toml ruff format `git ls-files | grep "\.py$$"` + isort `git ls-files | grep "\.py$$"` lint: clean @# Do not analyse .gitignored files. @# `make` needs `$$` to output `$`. Ref: http://stackoverflow.com/questions/2382764. - black --check `git ls-files | grep "\.py$$"` isort --check `git ls-files | grep "\.py$$"` ruff check `git ls-files | grep "\.py$$"` yamllint `git ls-files | grep "\.yaml$$"` diff --git a/openfisca_extension_template/tests/test_api.py b/openfisca_extension_template/tests/test_api.py index 620d91f..7772fd2 100644 --- a/openfisca_extension_template/tests/test_api.py +++ b/openfisca_extension_template/tests/test_api.py @@ -70,4 +70,4 @@ def test_openfisca_server(payload): with request.urlopen(**payload) as response: data = json.loads(response.read().decode("utf-8")) assert response.status == client.OK - assert data["info"]["title"] == "Openfisca-Country_Template Web API" + assert data["info"]["title"] == "Openfisca-Country-Template Web API" diff --git a/pyproject.toml b/pyproject.toml index 0567e7c..89b916a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -3,7 +3,7 @@ build-backend = "poetry.core.masonry.api" requires = [ "poetry-core>=1.7", "setuptools>=61" ] [tool.poetry] -name = "openfisca_extension_template" +name = "openfisca-extension_template" version = "2.0.0" description = "An OpenFisca extension that adds some variables to an already-existing tax and benefit system." license = "AGPL-3.0-only" @@ -28,10 +28,8 @@ packages = [ { include = "openfisca_extension_template", from = "." } ] [tool.poetry.dependencies] python = "~3.9 || ~3.10 || ~3.11" -openfisca_country_template = ">=7" -black = { version = "^24.8.0", optional = true } +openfisca-country_template = ">=7" isort = { version = "^5.13.2", optional = true } -pyproject-fmt = { version = "^2.3.1", optional = true } ruff = { version = "^0.6.9", optional = true } ruff-lsp = { version = "^0.0.57", optional = true } yamllint = { version = "^1.35.1", optional = true } @@ -86,10 +84,6 @@ sections = [ "LOCALFOLDER", ] -[tool.pyproject-fmt] -column_width = 79 -indent = 4 - [tool.pytest.ini_options] addopts = "--exitfirst --showlocals --doctest-modules --disable-warnings" testpaths = [ "openfisca_extension_template/tests" ] @@ -108,7 +102,7 @@ commands_pre = [ "install", "--find-links", ".", - "openfisca_extension_template", + "openfisca-extension_template", ], ] @@ -122,7 +116,7 @@ commands_pre = [ "install", "--find-links", ".", - "openfisca_extension_template[dev]", + "openfisca-extension_template[dev]", ], ]