[packaging/craft] bin/Packager: Fix a bug where an absulute path was used instead of a relative path

Hannah von Reth <[email protected]>
Newsgroups gmane.comp.kde.cvs
Message-ID <[email protected]>
Git commit 337858e449af59f9228be52310945db0839b2510 by Hannah von Reth.
Committed on 03/08/2026 at 11:28.
Pushed by vonreth into branch 'master'.

Fix a bug where an absulute path was used instead of a relative path

M  +1    -1    bin/Packager/CollectionPackagerBase.py
M  +1    -0    bin/Packager/PackagerBase.py

https://invent.kde.org/packaging/craft/-/commit/337858e449af59f9228be52310945db0839b2510

diff --git a/bin/Packager/CollectionPackagerBase.py b/bin/Packager/CollectionPackagerBase.py
index c9e70daf4..8d928e5de 100644
--- a/bin/Packager/CollectionPackagerBase.py
+++ b/bin/Packager/CollectionPackagerBase.py
@@ -322,7 +322,7 @@ class CollectionPackagerBase(PackagerBase):
             if dbgName.exists():
                 dbgName.unlink()
             if not self._createArchive(
-                dbgName,
+                dbgName.name,
                 self.archiveDebugDir(),
                 self.packageDestinationDir(),
                 fileType=FileType.Debug,
diff --git a/bin/Packager/PackagerBase.py b/bin/Packager/PackagerBase.py
index 98ea1551e..e98790703 100644
--- a/bin/Packager/PackagerBase.py
+++ b/bin/Packager/PackagerBase.py
@@ -137,6 +137,7 @@ class PackagerBase(CraftBase):
         createDigests=True,
         fileType: FileType = FileType.Binary,
     ) -> bool:
+        assert not Path(archiveName).is_absolute()
         archiveName = Path(destDir) / archiveName
 
         if not utils.compress(archiveName, sourceDir):
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.