Subject: [bug#76354] [PATCH] gnu: Add python-imageio-freeimage.

From: Sharlatan Hellseher <[email-masked]>
Date: Tue, 18 Feb 2025 17:25:49 +0000

Hi,

> (python-imageio)[arguments]: Remove the freeimage substitution from the
> 'fix-source phase.

--8<---------------cut here---------------start------------->8---
          (add-after 'unpack 'fix-failing-tests
            (lambda _
              (substitute* "tests/test_core.py"
                (("(core\\.load_lib)\\((\\[gllib\\], \\[\\])\\)"
                  all fun args)
                 (string-append "raises(ValueError, " fun ", " args ")")))
              (delete-file "tests/test_freeimage.py"))))))
--8<---------------cut here---------------end--------------->8---
It looks the whole [arguments] block may be removed and skip test
logic applied in #:test-flags as the package uses python-pytest e.g.
"--ignore=tests/test_freeimage.py" or "-k not <test-name>".

--8<---------------cut here---------------start------------->8---
+      #:tests? #f ; tests need internet and are not distributed in PyPI
--8<---------------cut here---------------end--------------->8---
Maybe install from Git?
<https://github.com/imageio/imageio-freeimage/blob/master/tests/test_freeimage.py>
the only one tests file which does not require urllib or requrests.

--8<---------------cut here---------------start------------->8---
 (symlink (search-input-file inputs "lib/libfreeimage.so")
--8<---------------cut here---------------end--------------->8---
Maybe swap to #$(this-package-input "<package>") instead?

---
Oleg