From 763447f2ce9a89ed03bd52fdfd73ea91088ce436 Mon Sep 17 00:00:00 2001 From: Dom Sekotill Date: Fri, 21 Oct 2022 17:21:07 +0100 Subject: [PATCH 1/4] Fix PLATFORMS in release pipelines --- .gitlab-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index e70771c..3442e0a 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -37,7 +37,6 @@ Build Images: - plugins/* - scripts/* variables: - PLATFORMS: "" BUILD_ARGS: >- wp_version=$WORDPRESS_VERSION php_version=$PHP_VERSION @@ -45,6 +44,7 @@ Build Images: parallel: matrix: - TARGET: [nginx, fastcgi] + PLATFORMS: [""] trigger: include: - project: dom/project-templates -- GitLab From 4dd0ae4ca6ef62a39d2f25be78e3362a328d3e1a Mon Sep 17 00:00:00 2001 From: Dom Sekotill Date: Fri, 21 Oct 2022 17:23:46 +0100 Subject: [PATCH 2/4] Set runtime version for mypy to check against --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index f526eaa..4375022 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -93,7 +93,7 @@ repos: rev: v0.910 hooks: - id: mypy - args: ["--config-file=.lint.cfg"] + args: ["--config-file=.lint.cfg", "--python-version=3.9"] additional_dependencies: - types-requests - behave-utils ~=0.3.2 -- GitLab From 6efa967527f7ddfb1fd2ecae62454b8c64f095dc Mon Sep 17 00:00:00 2001 From: Dom Sekotill Date: Fri, 21 Oct 2022 17:35:13 +0100 Subject: [PATCH 3/4] Address typing issue from pipeline checks --- .pre-commit-config.yaml | 2 +- tests/steps/pages.py | 6 ++++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 4375022..a8fae9e 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -90,7 +90,7 @@ repos: - flake8-tabs - repo: https://github.com/pre-commit/mirrors-mypy - rev: v0.910 + rev: v0.982 hooks: - id: mypy args: ["--config-file=.lint.cfg", "--python-version=3.9"] diff --git a/tests/steps/pages.py b/tests/steps/pages.py index 7921b4f..6263847 100644 --- a/tests/steps/pages.py +++ b/tests/steps/pages.py @@ -1,4 +1,4 @@ -# Copyright 2021 Dominik Sekotill +# Copyright 2021-2022 Dominik Sekotill # # This Source Code Form is subject to the terms of the Mozilla Public # License, v. 2.0. If a copy of the MPL was not distributed with this @@ -64,7 +64,9 @@ def create_post(context: Context, post_type: PostType, text: str|None = None) -> """ Create a WP post of the given type and store it in the context with the type as the name """ - post = use_fixture(wp_post, context, post_type, text or getattr(context, "text", "")) + text = text or getattr(context, "text", "") + assert isinstance(text, str) + post = use_fixture(wp_post, context, post_type, text) setattr(context, post_type.value, post) -- GitLab From 0cb615e85720745338f578b18c329b468335ccc4 Mon Sep 17 00:00:00 2001 From: Dom Sekotill Date: Fri, 21 Oct 2022 17:35:40 +0100 Subject: [PATCH 4/4] Bump copyright dates for files merged in 2022 --- tests/environment.py | 2 +- tests/steps/commands.py | 2 +- tests/wp.py | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/environment.py b/tests/environment.py index 1d0837e..3d839be 100644 --- a/tests/environment.py +++ b/tests/environment.py @@ -1,4 +1,4 @@ -# Copyright 2021 Dominik Sekotill +# Copyright 2021-2022 Dominik Sekotill # # This Source Code Form is subject to the terms of the Mozilla Public # License, v. 2.0. If a copy of the MPL was not distributed with this diff --git a/tests/steps/commands.py b/tests/steps/commands.py index 422a8f7..acd1f72 100644 --- a/tests/steps/commands.py +++ b/tests/steps/commands.py @@ -1,4 +1,4 @@ -# Copyright 2021 Dominik Sekotill +# Copyright 2021-2022 Dominik Sekotill # # This Source Code Form is subject to the terms of the Mozilla Public # License, v. 2.0. If a copy of the MPL was not distributed with this diff --git a/tests/wp.py b/tests/wp.py index 9d22f21..efc01b3 100644 --- a/tests/wp.py +++ b/tests/wp.py @@ -1,4 +1,4 @@ -# Copyright 2021 Dominik Sekotill +# Copyright 2021-2022 Dominik Sekotill # # This Source Code Form is subject to the terms of the Mozilla Public # License, v. 2.0. If a copy of the MPL was not distributed with this -- GitLab