python3Packages.pixelmatch: init at 0.3.0 and fix folium (#439528)

This commit is contained in:
Fabian Affolter
2025-09-26 19:04:25 +00:00
committed by GitHub
3 changed files with 58 additions and 6 deletions
@@ -1,7 +1,7 @@
{
lib,
branca,
buildPythonPackage,
branca,
fetchFromGitHub,
geodatasets,
geopandas,
@@ -10,6 +10,7 @@
numpy,
pandas,
pillow,
pixelmatch,
pytestCheckHook,
pythonOlder,
requests,
@@ -52,16 +53,16 @@ buildPythonPackage rec {
nbconvert
pandas
pillow
pixelmatch
pytestCheckHook
selenium
];
disabledTests = [
# Tests require internet connection
"test__repr_png_is_bytes"
"test_geojson"
"test_heat_map_with_weights"
"test_json_request"
"test_notebook"
# no selenium driver
"test__repr_png_is_bytes"
"test_valid_png_size"
"test_valid_png"
# pooch tries to write somewhere it can, and geodatasets does not give us an env var to customize this.
@@ -69,7 +70,8 @@ buildPythonPackage rec {
];
disabledTestPaths = [
# Import issue with selenium.webdriver.common.fedcm
# Selenium cannot find chrome driver, even with chromedriver package
"tests/snapshots/test_snapshots.py"
"tests/selenium"
];
@@ -0,0 +1,48 @@
{
lib,
buildPythonPackage,
fetchgit,
pillow,
poetry-core,
pytestCheckHook,
pytest-benchmark,
pythonOlder,
}:
let
owner = "whtsky";
repo = "pixelmatch-py";
in
buildPythonPackage rec {
pname = "pixelmatch";
version = "0.3.0";
pyproject = true;
disabled = pythonOlder "3.7";
src = fetchgit {
url = "https://github.com/whtsky/pixelmatch-py.git";
tag = "v${version}";
hash = "sha256-xq0LT7v83YRz0baw24iDXiuUxiNPMEsiZNIewsH3JPw=";
fetchLFS = true;
};
build-system = [
poetry-core
];
nativeCheckInputs = [
pillow
pytest-benchmark
pytestCheckHook
];
pythonImportsCheck = [ "pixelmatch" ];
meta = {
description = "A pixel-level image comparison library";
homepage = "https://github.com/whtsky/pixelmatch-py";
changelog = "https://github.com/whtsky/pixelmatch-py/tree/v${version}#changelog";
license = with lib.licenses; [ isc ];
teams = [ lib.teams.geospatial ];
};
}
+2
View File
@@ -11859,6 +11859,8 @@ self: super: with self; {
pixel-ring = callPackage ../development/python-modules/pixel-ring { };
pixelmatch = callPackage ../development/python-modules/pixelmatch { };
pizzapi = callPackage ../development/python-modules/pizzapi { };
pjsua2 =