[Midnightbsd-cvs] [MidnightBSD/mports] 9c64d6: archivers/py-lz4: fix test suite failures

Lucas Holt noreply at github.com
Wed Apr 29 20:34:46 EDT 2026


  Branch: refs/heads/master
  Home:   https://github.com/MidnightBSD/mports
  Commit: 9c64d690fec8cc896cd652c48562f16d83d95e64
      https://github.com/MidnightBSD/mports/commit/9c64d690fec8cc896cd652c48562f16d83d95e64
  Author: Lucas Holt <luke at foolishgames.com>
  Date:   2026-04-29 (Wed, 29 Apr 2026)

  Changed paths:
    M archivers/py-lz4/Makefile

  Log Message:
  -----------
  archivers/py-lz4: fix test suite failures

Two issues caused every test run to fail:

1. pytest runs from WRKSRC which contains the source lz4/ directory.
   Python imports this instead of the installed package, then fails to
   load compiled C extensions (_version, _block, _frame) that only
   exist in the pep517 build/ directory.  Add a pre-test target that
   runs setup.py build_ext (setup.cfg has inplace=1) to copy the .so
   files into the source tree so pytest can import a working lz4.

2. The stream module is experimental (requires PYLZ4_EXPERIMENTAL=1)
   and is not built by default.  The upstream tox default env only
   tests block and frame.  Restrict TEST_ARGS to tests/block and
   tests/frame to match, avoiding collection errors for lz4.stream.

AI-Assisted-by: Claude Sonnet 4.6 <noreply at anthropic.com>
Signed-off-by: Lucas Holt <luke at foolishgames.com>



To unsubscribe from these emails, change your notification settings at https://github.com/MidnightBSD/mports/settings/notifications


More information about the Midnightbsd-cvs mailing list