csvs-to-sqlite: 1.2 -> 1.3

1. Remove pin on click 7, because except for one unit test that checks
the help output too strictly, the app still works with click 8.

2. Pull in patches that make the app compatible with pandas 2.

authored by Theodore Ni and committed by Martin Weinelt 6d45281d 3ba65a37

+32 -24
+32 -24
pkgs/tools/misc/csvs-to-sqlite/default.nix
··· 1 - { lib, python3, fetchFromGitHub }: 2 3 - let 4 - # csvs-to-sqlite is currently not compatible with Click 8. See the following 5 - # https://github.com/simonw/csvs-to-sqlite/issues/80 6 - # 7 - # Workaround the issue by providing click 7 explicitly. 8 - python = python3.override { 9 - packageOverrides = self: super: { 10 - # Use click 7 11 - click = super.click.overridePythonAttrs (old: rec { 12 - version = "7.1.2"; 13 - src = old.src.override { 14 - inherit version; 15 - hash = "sha256-0rUlXHxjSbwb0eWeCM0SrLvWPOZJ8liHVXg6qU37axo="; 16 - }; 17 - }); 18 - }; 19 - }; 20 - in with python.pkgs; buildPythonApplication rec { 21 pname = "csvs-to-sqlite"; 22 - version = "1.2"; 23 format = "setuptools"; 24 - 25 - disabled = !isPy3k; 26 27 src = fetchFromGitHub { 28 owner = "simonw"; 29 repo = pname; 30 rev = version; 31 - hash = "sha256-ZG7Yto8q9QNNJPB/LMwzucLfCGiqwBd3l0ePZs5jKV0"; 32 }; 33 34 propagatedBuildInputs = [ 35 click 36 dateparser 37 pandas 38 py-lru-cache 39 six 40 ]; 41 42 nativeCheckInputs = [ 43 pytestCheckHook 44 ]; 45 46 meta = with lib; { ··· 49 license = licenses.asl20; 50 maintainers = [ maintainers.costrouc ]; 51 }; 52 - 53 }
··· 1 + { lib, python3, fetchFromGitHub, fetchpatch }: 2 3 + with python3.pkgs; buildPythonApplication rec { 4 pname = "csvs-to-sqlite"; 5 + version = "1.3"; 6 format = "setuptools"; 7 8 src = fetchFromGitHub { 9 owner = "simonw"; 10 repo = pname; 11 rev = version; 12 + hash = "sha256-wV6htULG3lg2IhG2bXmc/9vjcK8/+WA7jm3iJu4ZoOE="; 13 }; 14 15 + patches = [ 16 + # https://github.com/simonw/csvs-to-sqlite/pull/92 17 + (fetchpatch { 18 + name = "pandas2-compatibility-1.patch"; 19 + url = "https://github.com/simonw/csvs-to-sqlite/commit/fcd5b9c7485bc7b95bf2ed9507f18a60728e0bcb.patch"; 20 + hash = "sha256-ZmaNWxsqeNw5H5gAih66DLMmzmePD4no1B5mTf8aFvI="; 21 + }) 22 + (fetchpatch { 23 + name = "pandas2-compatibility-2.patch"; 24 + url = "https://github.com/simonw/csvs-to-sqlite/commit/3d190aa44e8d3a66a9a3ca5dc11c6fe46da024df.patch"; 25 + hash = "sha256-uYUH0Mhn6LIf+AHcn6WuCo5zFuSNWOZBM+AoqkmMnSI="; 26 + }) 27 + ]; 28 + 29 + nativeBuildInputs = [ 30 + pythonRelaxDepsHook 31 + ]; 32 + 33 propagatedBuildInputs = [ 34 click 35 dateparser 36 pandas 37 py-lru-cache 38 six 39 + ]; 40 + 41 + pythonRelaxDeps = [ 42 + "click" 43 ]; 44 45 nativeCheckInputs = [ 46 + cogapp 47 pytestCheckHook 48 + ]; 49 + 50 + disabledTests = [ 51 + # Test needs to be adjusted for click >= 8. 52 + "test_if_cog_needs_to_be_run" 53 ]; 54 55 meta = with lib; { ··· 58 license = licenses.asl20; 59 maintainers = [ maintainers.costrouc ]; 60 }; 61 }