#1089667 piuparts: fails when (path to) changes file is not world readable

#1089667#5
Date:
2024-12-10 21:34:05 UTC
From:
To:
Package: piuparts
Version: 1.5.1

I'm not sure if this is intended to work, but with a home directory that
doesn't allow access by "other"s, i.e. "chmod o-rwx ~", an unshare
sbuild attempt fails like this here:

  0m0.0s WARNING: /home/rlb/deb/lockfile-progs/lockfile-progs_0.1.21~1.gbp7eb6ac_amd64.changes is not readable. Skipping.

  Piuparts caught exception, exiting...
  ------------------------------------------------------------
  Traceback (most recent call last):
    File "/usr/bin/piuparts", line 3720, in <module>
      main()
    File "/usr/bin/piuparts", line 3705, in main
      process_packages(package_list)
    File "/usr/bin/piuparts", line 3576, in process_packages
      packages = get_package_names_from_package_files(package_list)
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/usr/bin/piuparts", line 2322, in get_package_names_from_package_files
      for filename in package_files:
                      ^^^^^^^^^^^^^
  TypeError: 'NoneType' object is not iterable

Thanks

#1089667#12
Date:
2024-12-11 07:10:50 UTC
From:
To:
Hi,

* Rob Browning <rlb@defaultvalue.org> [2024-12-10 15:34]:

A simple way to reproduce this is:

apt source -b hostname
chmod o-r hostname_3.25_amd64.changes
piuparts hostname_3.25_amd64.changes

Cheers Jochen

#1089667#17
Date:
2025-04-16 09:50:38 UTC
From:
To:

#1089667#22
Date:
2025-04-16 09:49:55 UTC
From:
To:
Same here. Using umask of 0027

   $> umask
   0027

Greets, Dirk.

#1089667#31
Date:
2025-07-07 07:27:08 UTC
From:
To:
Hi, I found a workaround for this bug, thanks to Phil Wyett. Check the test #4 on https://wiki.debian.org/PhilWyett/DebianMentoring

If you're using sbuild to build your debian packages, you should go to your config.pl and comment out the lines calling piuparts and run the sbuild command to first build your package from your debian packaging folder.

Then go back to the directory where your sources.changes is located and there separately run piubuilder for the sources.changes file.

This fixed the issue for me.