[Collab-qa-commits] r752 - bapase
atomo64-guest at alioth.debian.org
atomo64-guest at alioth.debian.org
Wed Apr 2 02:03:50 UTC 2008
Author: atomo64-guest
Date: 2008-04-02 02:03:49 +0000 (Wed, 02 Apr 2008)
New Revision: 752
Modified:
bapase/Makefile
bapase/datafiles.rb
bapase/gen_html.rb
Log:
Make bapase DEHS-aware
Modified: bapase/Makefile
===================================================================
--- bapase/Makefile 2008-04-01 08:55:31 UTC (rev 751)
+++ bapase/Makefile 2008-04-02 02:03:49 UTC (rev 752)
@@ -2,7 +2,7 @@
all: scores-html
-scores-html: Sources_ok testing-status.txt popcon_sources.txt package-actions.txt bugsummary wnppsummary orphaned_packages.txt upload-history.txt removals.txt
+scores-html: Sources_ok testing-status.txt popcon_sources.txt package-actions.txt bugsummary wnppsummary orphaned_packages.txt upload-history.txt removals.txt dehs.txt
./gen_html.rb
Sources_ok: testing-main-Sources testing-contrib-Sources testing-non-free-Sources unstable-main-Sources unstable-contrib-Sources unstable-non-free-Sources stable-main-Sources stable-contrib-Sources stable-non-free-Sources oldstable-main-Sources oldstable-contrib-Sources oldstable-non-free-Sources experimental-main-Sources experimental-contrib-Sources experimental-non-free-Sources
@@ -83,7 +83,10 @@
removals.txt:
./getremovals.rb > removals.txt
+dehs.txt:
+ wget -O dehs.txt http://dehs.alioth.debian.org/ddpomail.txt
+
clean:
- rm -f testing-status.txt *-Sources popcon_sources.txt scores.txt Sources_ok bts2ldap-fullindex RC+patch.txt bugsummary wnppsummary orphaned_packages.txt scores-buggy.html scores-orphaned.html upload-history.txt scores-useless.html removals.txt scores-nmued.html
+ rm -f testing-status.txt *-Sources popcon_sources.txt scores.txt Sources_ok bts2ldap-fullindex RC+patch.txt bugsummary wnppsummary orphaned_packages.txt scores-buggy.html scores-orphaned.html upload-history.txt scores-useless.html removals.txt scores-nmued.html dehs.txt
.PHONY: clean scores-html
Modified: bapase/datafiles.rb
===================================================================
--- bapase/datafiles.rb 2008-04-01 08:55:31 UTC (rev 751)
+++ bapase/datafiles.rb 2008-04-02 02:03:49 UTC (rev 752)
@@ -42,6 +42,17 @@
return nmus
end
+# from collab-qa/ddpo-by-mail/dehs.rb with some minor changes
+def read_dehs
+ dehs = {}
+ IO::read('dehs.txt').each_line do |l|
+ pkg, unstable, upstream, date = l.chomp.split('|')
+ next if date == "1970-01-01 00:00:00"
+ d = Date::parse(date)
+ dehs[pkg] = [ unstable, upstream, d ]
+ end
+ return dehs
+end
class TestingStatus
attr_accessor :testingversion, :unstableversion, :firstinunstable, :testingdays, :intesting, :syncdays, :sync, :syncversion
Modified: bapase/gen_html.rb
===================================================================
--- bapase/gen_html.rb 2008-04-01 08:55:31 UTC (rev 751)
+++ bapase/gen_html.rb 2008-04-02 02:03:49 UTC (rev 752)
@@ -19,6 +19,7 @@
$rcbugs, $bugs = read_bugs
$wnpp = read_wnpp
$removals = read_removals
+$dehs = read_dehs
$actions = Actions::read('package-actions.txt')
$orph = OrphanedPackage::readfile
$uploadhistory = LastUpload::readfile
@@ -138,6 +139,9 @@
if $popcon[pkg] < 200
score += (200 - $popcon[pkg]) * 8
end
+ if $dehs.has_key?(pkg)
+ score += (CURDATE - $dehs[pkg][2]) * 2
+ end
if $uploadhistory.has_key?(pkg)
uh = $uploadhistory[pkg]
if CURDATE - uh.date > 30
@@ -174,6 +178,9 @@
if $popcon[pkg] < 500
score += (500 - $popcon[pkg]) * 2
end
+ if $dehs.has_key?(pkg)
+ score += (CURDATE - $dehs[pkg][2])
+ end
if $rcbugs[pkg] > 0
if $rcbugs[pkg] > 4
score += 5 * 300
More information about the Collab-qa-commits
mailing list