[Piuparts-devel] Bug#746722: Spurious log directory creation in piuparts-report

Dave Steele dsteele at gmail.com
Fri May 2 21:06:25 UTC 2014


Package: piuparts-master
thanks

Each run of piuparts-report results in either an exception crash, or a
fresh set of master section log file directories in the current
directory.

Per 740386, where the problem was discussed:

On Sat, Mar 1, 2014 at 4:16 PM, Andreas Beckmann <anbe at debian.org> wrote:
> On 2014-03-01 16:44, Dave Steele wrote:
>> On Sat, Mar 1, 2014 at 1:52 AM, Andreas Beckmann <anbe at debian.org> wrote:
>>> On 2014-02-28 22:57, Dave Steele wrote:
>>>> 3057fb6 piuparts-report.py: Establish PackagesDB prefix
>>>
>>> NACK. Or why is this needed for sources_db? This doesn't have logfiles.
>>>
...
>> line 345, in create_subdirs
>>     os.makedirs(sdir)
>>   File "/usr/lib/python2.7/os.py", line 157, in makedirs
>>     mkdir(name, mode)
>> OSError: [Errno 13] Permission denied: 'pass'
>>
...
> So let's try to fix this properly, not work around it ...
>
> I'll look into this later next week.
>
>
> Andreas

I'd say that the 'proper' fix to packagesdb is more substantial than
any of the alternatives likely under consideration.

The proposed patch was:

diff --git a/piuparts-report.py b/piuparts-report.py
index 8a5e9b6..cf55c4c 100644
--- a/piuparts-report.py
+++ b/piuparts-report.py
@@ -731,7 +731,7 @@ class Section:
         self._load_package_database(section, master_directory)
         self._binary_db = self._package_databases[section]

-        self._source_db = piupartslib.packagesdb.PackagesDB()
+        self._source_db =
piupartslib.packagesdb.PackagesDB(prefix=self._section_directory)
         self._source_db.load_packages_urls(
                 self._distro_config.get_sources_urls(
                     self._config.get_distro(),


-- 
"Le mieux est l'ennemi du bien" - Voltaire



More information about the Piuparts-devel mailing list