🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: linux.debian.bugs.dist
Article #3886

Bug#1153508: FTBFS with platformdirs 4.14

#3886
From: Stefano Rivera
Date: Mon, 09 Nov 2026 10:50
47 lines
3678 bytes
Package: python3-datacache
Version: 1.27.1-1
Severity: serious
Tags: ftbfs patch
Forwarded: https://github.com/openvax/datacache/issues/138

Sorry, I didn't spot this before uploading platfarmdirs 4.14, but it 
causes a (presumably consequential) test failure in datacache:

____ test_linux_caches_follow_an_absolute_xdg_cache_home[ {tmp}/xdg \t-xdg] ____

platform_home = <function platform_home.<locals>.simulate at 0x7f5403644510>
tmp_path = PosixPath('/tmp/pytest-of-sbuild/pytest-0/test_linux_caches_follow_an_ab5')
monkeypatch = <_pytest.monkeypatch.MonkeyPatch object at 0x7f5403419da0>
xdg = ' {tmp}/xdg \t', under = 'xdg'

    @pytest.mark.skipif(os.name != "posix", reason="POSIX path separators")
    @pytest.mark.parametrize("xdg, under", [
        (None, ".cache"),
        ("", ".cache"),
        ("relative/cache", ".cache"),  # Never relative to the working directory.
        ("~/cache", ".cache"),  # Not expanded: relative, as XDG specifies.
        ("{tmp}/xdg", "xdg"),
        (" {tmp}/xdg \t", "xdg"),  # Stripped, which platformdirs before 4.6 didn't do.
    ])
    def test_linux_caches_follow_an_absolute_xdg_cache_home(platform_home, tmp_path, monkeypatch, xdg, under):
        platform_home(platformdirs.unix.Unix)
        if xdg is not None:
            monkeypatch.setenv("XDG_CACHE_HOME", xdg.format(tmp=tmp_path))
>       assert get_data_dir("example") == str(tmp_path / under / "example")
E       AssertionError: assert '/tmp/pytest-...cache/example' == '/tmp/pytest-...5/xdg/example'
E         
E         Skipping 53 identical leading characters in diff, use -v to show
E         - ow_an_ab5/xdg/example
E         ?           ^^^
E         + ow_an_ab5/.cache/example
E         ?           ^^^^^^

tests/test_cache_paths.py:180: AssertionError
=========================== short test summary info ============================
FAILED tests/test_cache_paths.py::test_linux_caches_follow_an_absolute_xdg_cache_home[ {tmp}/xdg \t-xdg]

This should be resolved with:

https://github.com/openvax/datacache/pull/144

Stefano
Technical Details
Message-ID: <NXv6N-aNxo-7@gated-at.bofh.it>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!news.corradoroberto.it!diesel.cu.mi.it!bofh.it!news.nic.it!robomod

Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!news.corradoroberto.it!diesel.cu.mi.it!bofh.it!news.nic.it!robomod
From: Stefano Rivera <stefanor@debian.org>
Newsgroups: linux.debian.bugs.dist
Subject: Bug#1153508: FTBFS with platformdirs 4.14
Date: Mon, 09 Nov 2026 11:50:01 +0100
Message-ID: <NXv6N-aNxo-7@gated-at.bofh.it>
X-Mailbox-Line: From debian-bugs-dist-request@lists.debian.org  Mon Nov  9 10:43:08 2026
Old-Return-Path: <debbugs@buxtehude.debian.org>
X-Spam-Flag: NO
X-Spam-Score: -1.7
Reply-To: Stefano Rivera <stefanor@debian.org>, 1153508@bugs.debian.org
Resent-To: debian-bugs-dist@lists.debian.org
Resent-Cc: debian-med-packaging@lists.alioth.debian.org
X-Debian-Pr-Message: report 1153508
X-Debian-Pr-Package: python3-datacache
X-Debian-Pr-Keywords: ftbfs patch
X-Debian-Pr-Source: python-datacache
X-Reportbug-Version: 13.2.0+nmu1
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
User-Agent: NeoMutt/20260616
X-Debian-User: stefanor
X-Debian-Message: from BTS
X-Mailing-List: <debian-bugs-dist@lists.debian.org> archive/latest/2001629
List-ID: <debian-bugs-dist.lists.debian.org>
List-URL: <https://lists.debian.org/debian-bugs-dist/>
Approved: robomod@news.nic.it
Lines: 47
Organization: linux.* mail to news gateway
Sender: robomod@news.nic.it
X-Original-Date: Mon, 9 Nov 2026 10:40:34 +0000
X-Original-Message-ID: <avGiwsp__qHSkRhw@grieg.kardiogramm.net>