From 163c9aefd065b2d27503b18d5acfae11e58666d3 Mon Sep 17 00:00:00 2001 From: "R. Ryantm" Date: Tue, 6 Dec 2022 10:39:21 +0000 Subject: linkchecker: 10.2.0 -> 10.2.1 --- pkgs/tools/networking/linkchecker/default.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkgs/tools/networking/linkchecker/default.nix b/pkgs/tools/networking/linkchecker/default.nix index 1facde5bc792d..1e998573ffc93 100644 --- a/pkgs/tools/networking/linkchecker/default.nix +++ b/pkgs/tools/networking/linkchecker/default.nix @@ -6,7 +6,7 @@ let in pypkgs.buildPythonApplication rec { pname = "linkchecker"; - version = "10.2.0"; + version = "10.2.1"; format = "pyproject"; disabled = pypkgs.pythonOlder "3.7"; @@ -14,8 +14,8 @@ pypkgs.buildPythonApplication rec { src = fetchFromGitHub { owner = pname; repo = pname; - rev = "v" + version; - hash = "sha256-wMiKS14fX5mkY1OwxQPFKm7i4WMFQKg3tdZZqD0g0Rw="; + rev = "refs/tags/v${version}"; + hash = "sha256-z7Qp74cai8GfsxB4n9dSCWQepp0/4PimFiRJQBaVSoo="; }; SETUPTOOLS_SCM_PRETEND_VERSION = version; -- cgit 1.4.1 From 5c1b0ff5ccdf6a6911811e8eaadacf41b89593d9 Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Tue, 6 Dec 2022 22:31:14 +0100 Subject: linkchecker: add changelog to meta --- pkgs/tools/networking/linkchecker/default.nix | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pkgs/tools/networking/linkchecker/default.nix b/pkgs/tools/networking/linkchecker/default.nix index 1e998573ffc93..35766304bb56e 100644 --- a/pkgs/tools/networking/linkchecker/default.nix +++ b/pkgs/tools/networking/linkchecker/default.nix @@ -50,7 +50,8 @@ pypkgs.buildPythonApplication rec { meta = with lib; { description = "Check websites for broken links"; homepage = "https://linkcheck.github.io/linkchecker/"; - license = licenses.gpl2; + changelog = "https://github.com/linkchecker/linkchecker/releases/tag/v${version}"; + license = licenses.gpl2Plus; maintainers = with maintainers; [ peterhoeg tweber ]; }; } -- cgit 1.4.1 From 915d9d054fb7ff9c1b03ea552a7044eb3d4a472a Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Tue, 6 Dec 2022 22:40:36 +0100 Subject: linkchecker: modernize - switch to pytestCheckHook --- pkgs/tools/networking/linkchecker/default.nix | 48 ++++++++++++++++----------- 1 file changed, 28 insertions(+), 20 deletions(-) diff --git a/pkgs/tools/networking/linkchecker/default.nix b/pkgs/tools/networking/linkchecker/default.nix index 35766304bb56e..b7ae9f00996aa 100644 --- a/pkgs/tools/networking/linkchecker/default.nix +++ b/pkgs/tools/networking/linkchecker/default.nix @@ -1,16 +1,15 @@ -{ stdenv, lib, fetchFromGitHub, python3Packages, gettext }: +{ lib +, stdenv +, fetchFromGitHub +, python3 +, gettext +}: -let - pypkgs = python3Packages; - -in -pypkgs.buildPythonApplication rec { +python3.pkgs.buildPythonApplication rec { pname = "linkchecker"; version = "10.2.1"; format = "pyproject"; - disabled = pypkgs.pythonOlder "3.7"; - src = fetchFromGitHub { owner = pname; repo = pname; @@ -20,9 +19,11 @@ pypkgs.buildPythonApplication rec { SETUPTOOLS_SCM_PRETEND_VERSION = version; - nativeBuildInputs = [ gettext ]; + nativeBuildInputs = [ + gettext + ]; - propagatedBuildInputs = with pypkgs; [ + propagatedBuildInputs = with python3.pkgs; [ argcomplete beautifulsoup4 configargparse @@ -33,19 +34,26 @@ pypkgs.buildPythonApplication rec { requests ]; - checkInputs = with pypkgs; [ + checkInputs = with python3.pkgs; [ parameterized - pytest + pytestCheckHook ]; - # test_timeit2 is flakey, and depends sleep being precise to the milisecond - checkPhase = lib.optionalString stdenv.isDarwin '' - # network tests fails on darwin - rm tests/test_network.py tests/checker/test_http*.py tests/checker/test_content_allows_robots.py tests/checker/test_noproxy.py - '' + '' - pytest --ignore=tests/checker/{test_telnet,telnetserver}.py \ - -k 'not TestLoginUrl and not test_timeit2' - ''; + disabledTests = [ + # test_timeit2 is flakey, and depends sleep being precise to the milisecond + "TestLoginUrl" + "test_timeit2" + ]; + + disabledTestPaths = [ + "tests/checker/telnetserver.py" + "tests/checker/test_telnet.py" + ] ++ lib.optionals stdenv.isDarwin [ + "tests/checker/test_content_allows_robots.py" + "tests/checker/test_http*.py" + "tests/checker/test_noproxy.py" + "tests/test_network.py" + ]; meta = with lib; { description = "Check websites for broken links"; -- cgit 1.4.1