[Piuparts-commits] [SCM] piuparts git repository branch, develop, updated. 0.44-638-g256a900
Andreas Beckmann
debian at abeckmann.de
Fri Jun 1 21:08:34 UTC 2012
The following commit has been merged in the develop branch:
commit a4a7369211a9348fda8a8341f996497fe1ad3b70
Author: Andreas Beckmann <debian at abeckmann.de>
Date: Fri Jun 1 22:21:41 2012 +0200
p-a: classify fail logs into /affected/ or /bugged/
stop mixing found and affected bugs
separate the logs into /bugged/ and /affected/
* /affected/ logs need frequent rechecking,
* /bugged/ logs need a source upload
Signed-off-by: Andreas Beckmann <debian at abeckmann.de>
diff --git a/debian/changelog b/debian/changelog
index b7bb43f..a46969b 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -24,6 +24,13 @@ piuparts (0.45) UNRELEASED; urgency=low
(Closes: #674672)
[ Andreas Beckmann ]
+ * master/db/report: Add a new category /affected/ for failed logs where the
+ bug is in a dependency, but only exposed by the package being tested.
+ - In the BTS these are reported as
+ Package: buggy-package
+ Version: buggy-version
+ Affects: package-under-test
+ Found: package-under-test/tested-version
* piuparts.py:
- Implement --install-remove-install option to test installation in
config-files-remaining state. (Closes: #359154)
@@ -73,6 +80,7 @@ piuparts (0.45) UNRELEASED; urgency=low
- Handle logs in /affected/ directories.
* piuparts-analyze.py:
- Don't report further bugs/versions if we found a match.
+ - Classify logs with bugs filed into /bugged/ or /affected/.
* Remove known_circular_depends from piuparts.conf handling.
* Remove static list known_circular_depends from piuparts.conf.
diff --git a/piuparts-analyze.py b/piuparts-analyze.py
index 4fc9b1c..7203915 100644
--- a/piuparts-analyze.py
+++ b/piuparts-analyze.py
@@ -53,7 +53,7 @@ def find_logs(directory):
def find_bugged_logs(failed_log):
package = package_name(failed_log)
pat = "/" + package + "_"
- return [x for x in find_logs("bugged") if pat in x]
+ return [x for x in find_logs("bugged") + find_logs("affected") if pat in x]
def package_name(log):
@@ -130,9 +130,9 @@ def get_bug_versions(bug):
return list(reversed(sorted([x.rsplit('/', 1)[-1] for x in debianbts.get_status((bug,))[0].found_versions], cmp=apt_pkg.version_compare))) or ['~']
-def move_to_bugged(failed_log):
- print("Moving %s to bugged" % failed_log)
- os.rename(failed_log, os.path.join("bugged", os.path.basename(failed_log)))
+def move_to_bugged(failed_log, bugged="bugged"):
+ print("Moving %s to %s" % (failed_log, bugged))
+ os.rename(failed_log, os.path.join(bugged, os.path.basename(failed_log)))
def mark_bugged_version(failed_log, bugged_log):
@@ -156,12 +156,18 @@ def mark_logs_with_reported_bugs():
pversion = package_source_version(failed_log)
failed_errors = extract_errors(failed_log)
moved = False
- for bug in piuparts_bugs_in(pname):
+ abugs = piuparts_bugs_affecting(pname)
+ bugs = piuparts_bugs_in(pname)
+ for bug in abugs + bugs:
if moved:
break
+ if bug in abugs:
+ bugged = "affected"
+ else:
+ bugged = "bugged"
found_versions = get_bug_versions(bug)
if pversion in found_versions:
- move_to_bugged(failed_log)
+ move_to_bugged(failed_log, bugged)
moved = True
break
for bug_version in found_versions:
@@ -220,8 +226,10 @@ def all_piuparts_bugs():
def piuparts_bugs_in(package):
- return debianbts.get_bugs('package', package, 'bugs', all_piuparts_bugs()) + \
- debianbts.get_bugs('affects', package, 'bugs', all_piuparts_bugs())
+ return debianbts.get_bugs('package', package, 'bugs', all_piuparts_bugs())
+
+def piuparts_bugs_affecting(package):
+ return debianbts.get_bugs('affects', package, 'bugs', all_piuparts_bugs())
def main():
--
piuparts git repository
More information about the Piuparts-commits
mailing list