[Piuparts-devel] Bug#673919: piuparts-report - Release Section object when section processing complete

Dave Steele dsteele at gmail.com
Tue May 22 02:25:21 UTC 2012


Package: piuparts
Version: 0.44
Tags: patch
User: debian-qa at lists.debian.org
Usertags: piuparts

piuparts-report is a bit of a resource hog, both in terms of RAM usage
and clock time. There is a loop in the main routine that maintains an
array of Section objects, which is never accessed. Removing this array
would permit those objects to be garbage collected earlier.

    https://github.com/davesteele/piuparts/commits/release-sections


--------------------


>From 93812d32c990739e62e16a35ab91f79e2036bdd2 Mon Sep 17 00:00:00 2001
From: David Steele <dsteele at gmail.com>
Date: Mon, 21 May 2012 20:35:15 -0400
Subject: [PATCH] piuparts-report - Release Section object when section
 processing complete

---
 piuparts-report.py |    2 --
 1 file changed, 2 deletions(-)

diff --git a/piuparts-report.py b/piuparts-report.py
index b714171..9d9b4c1 100644
--- a/piuparts-report.py
+++ b/piuparts-report.py
@@ -1125,11 +1125,9 @@ def main():


     if os.path.exists(master_directory):
-        sections = []
         for section_name in section_names:
             section = Section(section_name)
             section.generate_output(master_directory=master_directory,output_directory=output_directory,section_names=section_names,
ht_root=ht_root)
-            sections.append(section)

         # static pages
         logging.debug("Writing static pages")
--
1.7.10





More information about the Piuparts-devel mailing list