[Collab-qa-commits] r1128 - in svnbuildstat/trunk: lib/SvnBuildStat lib/SvnBuildStat/Controller root/src root/src/packages root/src/teams
goneri at alioth.debian.org
goneri at alioth.debian.org
Mon Aug 25 20:10:44 UTC 2008
Author: goneri
Date: 2008-08-25 20:10:43 +0000 (Mon, 25 Aug 2008)
New Revision: 1128
Added:
svnbuildstat/trunk/root/src/packages/list.tt2
Removed:
svnbuildstat/trunk/root/src/packages/listByMaintainer.tt2
Modified:
svnbuildstat/trunk/lib/SvnBuildStat/Common.pm
svnbuildstat/trunk/lib/SvnBuildStat/Controller/Controls.pm
svnbuildstat/trunk/lib/SvnBuildStat/Controller/Maintainers.pm
svnbuildstat/trunk/lib/SvnBuildStat/Controller/Packages.pm
svnbuildstat/trunk/lib/SvnBuildStat/Controller/Teams.pm
svnbuildstat/trunk/root/src/packages/info.tt2
svnbuildstat/trunk/root/src/teams/main.tt2
svnbuildstat/trunk/root/src/ttsite.css
Log:
improve the status of the package info page
remove the ByMaintainer and ByTeam pages
Modified: svnbuildstat/trunk/lib/SvnBuildStat/Common.pm
===================================================================
--- svnbuildstat/trunk/lib/SvnBuildStat/Common.pm 2008-08-25 16:47:46 UTC (rev 1127)
+++ svnbuildstat/trunk/lib/SvnBuildStat/Common.pm 2008-08-25 20:10:43 UTC (rev 1128)
@@ -286,7 +286,7 @@
}
foreach (@changelog) {
- s/[[:cntrl:]]//g;
+ s/[[:cntrl:]]//g; # Avoid breakage with the SQL injection
if (/^\S/ && $ret->{debchangelogentry}) {
# I ignore svn-bp empty template entry
if ($ret->{debchangelogentry} =~ /^.*\n\s\s\*\sNOT RELEASED YET\n\n\s--.*/m) {
@@ -295,7 +295,7 @@
last;
}
}
- $ret->{debchangelogentry} .= $_;
+ $ret->{debchangelogentry} .= $_."\n";
}
# if ($ret->{text} =~ /^\S+\s\((\S+)\)/) {
Modified: svnbuildstat/trunk/lib/SvnBuildStat/Controller/Controls.pm
===================================================================
--- svnbuildstat/trunk/lib/SvnBuildStat/Controller/Controls.pm 2008-08-25 16:47:46 UTC (rev 1127)
+++ svnbuildstat/trunk/lib/SvnBuildStat/Controller/Controls.pm 2008-08-25 20:10:43 UTC (rev 1128)
@@ -35,13 +35,47 @@
die "unspported arch";
}
- my $changelogentry_id = $c->model('SvnBuildStat::Model::DB::Viewtobuild')->search({$params->{arch} => 'true' })->first->changelogentry_id;
+
+ my $dbh = $c->model('DB')->storage->dbh;
+ my $tobuild = $dbh->selectall_arrayref("
+ SELECT
+ changelogentry.id AS changelogentry_id,
+ FROM
+ changelogentry
+ LEFT JOIN
+ build
+ ON
+ changelogentry.id = build.changelogentry_id
+ LEFT JOIN
+ repositoryentry
+ ON
+ changelogentry.id = repositoryentry.changelogentry_id
+ WHERE
+ repositoryentry.".$params->{arch}." = true
+ AND
+ repositoryentry.blacklisted = false
+ AND
+ changelogentry.dscuri IS NOT NULL
+ AND
+ (
+ changelogentry.lastbuildstart IS NULL
+ OR
+ changelogentry.lastbuildstart < (now() - '03:00:00'::interval)
+ )
+ ORDER BY
+ build.id IS NOT NULL,
+ build.time,
+ changelogentry.date
+ LIMIT 1");
+
+
+ my $changelogentry_id = $tobuild->[0][0];
die "Can't find a package to build" unless $changelogentry_id;
my $changelogentry = $c->model('SvnBuildStat::Model::DB::Changelogentry')->search ({id => $changelogentry_id})->first;
# lastbuildstart should in changelogentry directly?
- $changelogentry->lastbuildstart('now'); # TODO uncomment this
- $changelogentry->update(); # TODO the same
+ $changelogentry->lastbuildstart('now');
+ $changelogentry->update();
my $dscuri = $changelogentry->dscuri;
Modified: svnbuildstat/trunk/lib/SvnBuildStat/Controller/Maintainers.pm
===================================================================
--- svnbuildstat/trunk/lib/SvnBuildStat/Controller/Maintainers.pm 2008-08-25 16:47:46 UTC (rev 1127)
+++ svnbuildstat/trunk/lib/SvnBuildStat/Controller/Maintainers.pm 2008-08-25 20:10:43 UTC (rev 1128)
@@ -34,7 +34,7 @@
my $repository_rs;
my $maintainer;
- $c->stash->{maintainers} = [ $c->model('SvnBuildStat::Model::DB::Maintainer')->search(undef,{order_by=>"name"}) ];
+ $c->stash->{maintainers} = [ $c->model('SvnBuildStat::Model::DB::Maintainer')->search({isateam => 'false'},{order_by=>"name"}) ];
$c->stash->{template} = 'maintainers/main.tt2';
Modified: svnbuildstat/trunk/lib/SvnBuildStat/Controller/Packages.pm
===================================================================
--- svnbuildstat/trunk/lib/SvnBuildStat/Controller/Packages.pm 2008-08-25 16:47:46 UTC (rev 1127)
+++ svnbuildstat/trunk/lib/SvnBuildStat/Controller/Packages.pm 2008-08-25 20:10:43 UTC (rev 1128)
@@ -3,7 +3,7 @@
use strict;
use warnings;
use base 'Catalyst::Controller';
-
+use Data::Dumper;
=head1 NAME
SvnBuildStat::Controller::Packages - Catalyst Controller
@@ -39,7 +39,7 @@
$c->response->redirect($c->uri_for('/'));
}
-sub listByMaintainer : Local {
+sub list : Local {
my ( $self, $c, $email ) = @_;
# Do not remove
@@ -50,7 +50,7 @@
my $package_hashref = $dbh->selectall_hashref("
SELECT
- maintainer.email, maintainer.name, sourcepackage.name AS name, sourcepackage.id AS sourcepackage_id, changelogentry.id AS changelogentry_id, changelogentry.dscuri, changelogentry.isnative, changelogentry.isindebian, count(buildall.id) AS buildallcount, count(buildok.isbuildok) AS buildokcount, repositoryentry.issyncedwithupstream, repositoryentry.iswatchfilebroken
+ sourcepackage.name AS sourcepackage_name, maintainer.email, maintainer.name, sourcepackage.id AS sourcepackage_id, changelogentry.id AS changelogentry_id, changelogentry.dscuri, changelogentry.isnative, changelogentry.isindebian, count(buildall.id) AS buildallcount, count(buildok.isbuildok) AS buildokcount, repositoryentry.issyncedwithupstream, repositoryentry.iswatchfilebroken
FROM
sourcepackage, repositoryentry_maintainer, maintainer, changelogentry, repositoryentry
LEFT OUTER JOIN build AS buildall
@@ -78,53 +78,11 @@
$c->stash->{packages} = preparePackages($dbh, $package_hashref);
- $c->stash->{template} = 'packages/listByMaintainer.tt2';
+ $c->stash->{template} = 'packages/list.tt2';
}
-sub listByTeam : Local {
- my ( $self, $c, $team_id ) = @_;
- die unless $team_id =~ /^\d+$/;
-
- my $dbh = $c->model('DB')->storage->dbh;
-
- my $package_hashref = $dbh->selectall_hashref("
-SELECT
- sourcepackage.name AS name, sourcepackage.id AS sourcepackage_id, changelogentry.id AS changelogentry_id, changelogentry.dscuri, changelogentry.isnative, changelogentry.isindebian, count(buildall.id) AS buildallcount, count(buildok.isbuildok) AS buildokcount, repositoryentry.issyncedwithupstream, repositoryentry.iswatchfilebroken
-FROM
- repository, sourcepackage, changelogentry, repositoryentry
- LEFT OUTER JOIN build AS buildall
- ON
- repositoryentry.changelogentry_id=buildall.changelogentry_id
- LEFT OUTER JOIN build AS buildok
- ON
- repositoryentry.changelogentry_id=buildok.changelogentry_id AND buildok.isbuildok=true
-WHERE
- repositoryentry.repository_id=repository.id
- AND
- repository.team_id=4
- AND
- repositoryentry.changelogentry_id=changelogentry.id
- AND
- repositoryentry.sourcepackage_id=sourcepackage.id
- GROUP BY sourcepackage.name, sourcepackage.id, changelogentry.id, changelogentry.dscuri, changelogentry.isnative, changelogentry.isindebian, repositoryentry.issyncedwithupstream, repositoryentry.iswatchfilebroken
-
- ", 1);
-
- # TODO find a way to merge the Team view and the par Maintainer view related to the team
- # TODO maybe by adding a team.email entry
- my $name_arrayref = $dbh->selectall_arrayref("SELECT name FROM team WHERE id='$team_id'");
- $c->stash->{maintainer}->{name} = $name_arrayref->[0][0];
-
- $c->stash->{packages} = preparePackages($dbh, $package_hashref);
-
- $c->stash->{template} = 'packages/listByMaintainer.tt2';
-
-
- }
-
-
sub preparePackages : Private {
my ($dbh, $package_hashref) = @_;
@@ -161,90 +119,219 @@
}
sub info : Local {
- my ($self, $c, $name) = @_;
+ my ($self, $c, $packagename) = @_;
- # Retrieve all of the book records as book model objects and store in the
- # stash where they can be accessed by the TT template
- my $package = $c->model('SvnBuildStat::Model::DB::Sourcepackage')->search({name => $name})->first;
- if (!$package) {
+ die unless $packagename =~ /^[\w_-]+$/;
+
+ my $dbh = $c->model('DB')->storage->dbh;
+
+ my $req = "SELECT
+ sourcepackage.name as sourcepackage_name,
+ vcs.name as vcs_name,
+ versioninsid,
+ istarballpresent,
+ upstreamversion,
+ repositoryentry.lastcheck,
+ blacklisted,
+ changelogentry.rev,
+ todo,
+ issyncedwithupstream,
+ iswatchfilebroken,
+ isinnew,
+ isindebian,
+ isinincoming,
+ epoch,
+ version,
+ isnative,
+ debrevision,
+ debchangelogentry,
+ uri,
+ subdir,
+ changelogentry.id AS changelogentry_id,
+ repositoryentry.id AS repositoryentry_id,
+ sourcepackage.id AS sourcepackage_id
+ FROM
+ sourcepackage,
+ repositoryentry,
+ repository,
+ vcs,
+ changelogentry
+ WHERE
+ sourcepackage.name = '".$packagename."'
+ AND
+ repositoryentry.sourcepackage_id=sourcepackage.id
+ AND
+ repositoryentry.repository_id=repository.id
+ AND
+ repository.vcs_id=vcs.id
+ AND
+ repositoryentry.changelogentry_id=changelogentry.id
+ ORDER BY
+ vcs_name";
+# print $req;
+ my $packageinfo = $dbh->selectall_hashref($req, 1);
+
+ if (!$packageinfo || !%$packageinfo) {
$c->response->redirect($c->uri_for('/'));
return;
}
- my @currentchangelogentry = split $/, $package->currentchangelogentry;
- my @todo = split $/, $package->todo;
- $c->stash->{package} = $package->name;
- $c->stash->{bugpic} = $package->name;
+ # The idea behind that is to have be able to provide the information if the package is on different vcs
+ my @vcses = keys %$packageinfo;
+ my $vcs = $vcses[0];
+# my @currentchangelogentry = split $/, $package->currentchangelogentry;
+# my @todo = split $/, $package->todo;
+ $c->stash->{package} = $packagename;
+ $c->stash->{bugpic} = $packagename;
$c->stash->{bugpic} =~ s!^(.)(.+)$!http://people.debian.org/~glandium/bts/$1/$1$2.png! ;
- $c->stash->{istarballpresent} = $package->istarballpresent;
- $c->stash->{isindebian} = $package->isindebian;
- $c->stash->{tarballuri} = $package->tarballuri;
- $c->stash->{svndebrelease} = $package->svndebrelease;
- $c->stash->{iswatchfilebroken} = $package->iswatchfilebroken;
- $c->stash->{uri} = $package->uri;
- $c->stash->{weburi} = $package->uri;
- $c->stash->{weburi} =~ s!svn://svn.debian.org/svn!http://svn.debian.org/wsvn!;
- $c->stash->{isuptodate} = $package->isuptodate;
- $c->stash->{upstreamrelease} = $package->upstreamrelease;
- $c->stash->{currentchangelogentry} = \@currentchangelogentry;
- $c->stash->{todo} = \@todo;
+# $c->stash->{istarballpresent} = $packageinfo->{$vcs}->{istarballpresent};
+# print Dumper($packageinfo->{$vcs});
+ foreach (keys %{$packageinfo->{$vcs}}) {
+ $c->stash->{$_} = $packageinfo->{$vcs}->{$_};
+ }
+
+
+
+# $c->stash->{isindebian} = $package->isindebian;
+# $c->stash->{tarballuri} = $package->tarballuri;
+# $c->stash->{svndebrelease} = $package->svndebrelease;
+# $c->stash->{iswatchfilebroken} = $package->iswatchfilebroken;
+# $c->stash->{uri} = $package->uri;
+# $c->stash->{weburi} = $package->uri;
+# $c->stash->{weburi} =~ s!svn://svn.debian.org/svn!http://svn.debian.org/wsvn!;
+# $c->stash->{isuptodate} = $package->isuptodate;
+# $c->stash->{upstreamrelease} = $package->upstreamrelease;
+# $c->stash->{currentchangelogentry} = \@currentchangelogentry;
+# $c->stash->{todo} = \@todo;
############ Maintainers list
- my $packagemaintainer_rs = $c->model('SvnBuildStat::Model::DB::PackageMaintainer')->search({package_id => $package->id});
- $c->stash->{maintainers} = [ $packagemaintainer_rs->search_related("maintainer_id")->all ];
+ my $maintainer_rs = $c->model('SvnBuildStat::Model::DB::RepositoryentryMaintainer')->search({repositoryentry_id => $packageinfo->{$vcs}->{'repositoryentry_id'}});
+ $c->stash->{maintainers} = [ $maintainer_rs->search_related("maintainer_id")->all ];
- #############
- my $bug_rs = $c->model('SvnBuildStat::Model::DB::Bug')->search(package_id => $package->id);
- while (my $bug = $bug_rs->next) {
+ my $bugsinfo = $dbh->selectall_hashref("select bug.id as bug_id, bug.name as bug_name, bugseverity.name AS bugseverity_name, isreleasecritic from bug, bugseverity where bug.bugseverity_id=bugseverity.id and sourcepackage_id = ".$packageinfo->{$vcs}->{'sourcepackage_id'}, 1);
+
+ foreach (keys %$bugsinfo) {
+ my $bug_name = $bugsinfo->{$_}->{bug_name};
+ $bug_name =~ s/^(.{80})(.*)/$1 (...)/;
my $bugerror;
my $bugwarning;
- $bugerror = 1 if ($bug->severity_id->name =~ /important|serious|grave|critical/);
- $bugwarning = 1 if ($bug->severity_id->name =~ /normal/);
+ if ($bugsinfo->{$_}->{bugseverity_name} =~ /important|serious|grave|critical/) {
+ $bugerror = 1;
+ } elsif ($bugsinfo->{$_}->{bugseverity_name} =~ /normal/) {
+ $bugwarning = 1;
+ }
push @{$c->stash->{bugs}}, {
- id => $bug->id,
- name => $bug->name,
- severity => $bug->severity_id->name,
+ id => $bugsinfo->{$_}->{bug_id},
+ name => $bug_name,
+ severity => $bugsinfo->{$_}->{bugseverity_name},
error => $bugerror,
warning => $bugwarning }
}
-##########
-my $build = $c->model('SvnBuildStat::Model::DB::Build')->search({package_id => $package->id},{order_by => "id DESC"})->first;
-if ($build) {
- foreach (split $/, $build->lintian_log) {
- my $error;
- $error = 1 if /^E/;
- push @{$c->stash->{lintians}}, { text => $_, error => $error };
-}
-foreach (split $/, $build->linda_log) {
- my $error;
- $error = 1 if /^E/;
- push @{$c->stash->{lindas}}, { text => $_, error => $error } ;
-}
+ my $changelogsinfo = $dbh->selectall_hashref("
+SELECT
+ changelogentry.id AS changelogentry_id,
+ rev,
+ date,
+ text,
+ epoch,
+ version,
+ isnative,
+ debrevision,
+ userlogin.name AS userlogin_name
+FROM
+ changelogentry,
+ userlogin
+WHERE
+ changelogentry.userlogin_id=userlogin.id
+ AND
+ repositoryentry_id=".$packageinfo->{$vcs}->{'repositoryentry_id'}."
+ORDER BY
+ date DESC", 1);
-$c->stash->{piupartsisok} = $build->piupartsisok;
-}
-##############
+ $c->stash->{"changelogs"} = [];
+ foreach my $changelogentry_id (keys %$changelogsinfo) {
+ my %h;
+ $h{builds} = [];
+ foreach (keys %{$changelogsinfo->{$changelogentry_id}}) {
+ $h{$_} = $changelogsinfo->{$changelogentry_id}->{$_};
+ }
-my $build_rs = $c->model('SvnBuildStat::Model::DB::Build')->search({package_id => $package->id},{order_by => "id DESC"});
-my $cpt;
-while (($cpt++ < 10) && (my $build = $build_rs->next)) {
- my $failedstep;
- if (!$build->buildisok) {
- $failedstep = "build";
+ # Fetch the builds
+ my %t;
+ my $buildsinfo = $dbh->selectall_hashref("select build.id AS build_id, isbuildok, duration, time, arch.name AS arch_name from arch, build where build.arch_id=arch.id AND changelogentry_id=".$changelogentry_id." ORDER BY time DESC", 1);
+ foreach my $build_id (keys %{$buildsinfo}) {
+ $buildsinfo->{$build_id}->{qaresultentrys} = [];
+ my $qaresultentrysinfo = $dbh->selectall_hashref("
+SELECT
+ qaresultentry.id AS qaresultentry_id,
+ qaseverity.letter AS letter,
+ islogpresent,
+ qatag.name AS qatag_name,
+ qatool.name AS qatool_name,
+ qaresultentry.text
+FROM
+ qajob, qatool, qatag, qaresultentry, qaseverity
+WHERE
+ qajob.qatool_id=qatool.id
+ AND
+ qaresultentry.qajob_id=qajob.id
+ AND
+ qatag.id=qaresultentry.qatag_id
+ AND
+ qaresultentry.qaseverity_id=qaseverity.id
+ AND
+ qatag.isignored=false
+ AND
+ qajob.build_id=".$build_id."
+ORDER BY qatool_name", 1);
+ foreach my $qaresultentry_id (keys %{$qaresultentrysinfo}) {
+ push @{$buildsinfo->{$build_id}->{qaresultentrys}}, $qaresultentrysinfo->{$qaresultentry_id};
+ }
+ push @{$h{builds}}, $buildsinfo->{$build_id};
+ }
+
+ push @{$c->stash->{changelogs}}, \%h;
}
- push @{$c->stash->{builds}}, {
- id => $build->id,
- buildisok => $build->buildisok,
- rev => $build->rev,
- duration => $build->duration,
- arch => $build->arch_id->name,
- failedstep => $failedstep,
- time => $build->time,
+##########
+#my $build = $c->model('SvnBuildStat::Model::DB::Build')->search({package_id => $package->id},{order_by => "id DESC"})->first;
+#if ($build) {
+# foreach (split $/, $build->lintian_log) {
+# my $error;
+# $error = 1 if /^E/;
+# push @{$c->stash->{lintians}}, { text => $_, error => $error };
+#}
+#
+#foreach (split $/, $build->linda_log) {
+# my $error;
+# $error = 1 if /^E/;
+# push @{$c->stash->{lindas}}, { text => $_, error => $error } ;
+#}
+#
+#$c->stash->{piupartsisok} = $build->piupartsisok;
+#}
+###############
+#
+#my $build_rs = $c->model('SvnBuildStat::Model::DB::Build')->search({package_id => $package->id},{order_by => "id DESC"});
+#my $cpt;
+#while (($cpt++ < 10) && (my $build = $build_rs->next)) {
+# my $failedstep;
+# if (!$build->buildisok) {
+# $failedstep = "build";
+# }
+#
+# push @{$c->stash->{builds}}, {
+# id => $build->id,
+# buildisok => $build->buildisok,
+# rev => $build->rev,
+# duration => $build->duration,
+# arch => $build->arch_id->name,
+# failedstep => $failedstep,
+# time => $build->time,
+#}
+#}
}
-}
-}
=head1 AUTHOR
Modified: svnbuildstat/trunk/lib/SvnBuildStat/Controller/Teams.pm
===================================================================
--- svnbuildstat/trunk/lib/SvnBuildStat/Controller/Teams.pm 2008-08-25 16:47:46 UTC (rev 1127)
+++ svnbuildstat/trunk/lib/SvnBuildStat/Controller/Teams.pm 2008-08-25 20:10:43 UTC (rev 1128)
@@ -30,7 +30,7 @@
sub list : Local {
my ( $self, $c ) = @_;
- $c->stash->{teams} = [ $c->model('SvnBuildStat::Model::DB::Team')->search(undef,{order_by=>"name"}) ];
+ $c->stash->{teams} = [ $c->model('SvnBuildStat::Model::DB::Maintainer')->search({isateam => 'true'},{order_by=>"name"}) ];
$c->stash->{template} = 'teams/main.tt2';
Modified: svnbuildstat/trunk/root/src/packages/info.tt2
===================================================================
--- svnbuildstat/trunk/root/src/packages/info.tt2 2008-08-25 16:47:46 UTC (rev 1127)
+++ svnbuildstat/trunk/root/src/packages/info.tt2 2008-08-25 20:10:43 UTC (rev 1128)
@@ -1,7 +1,7 @@
[% # Provide a title to root/lib/site/header -%]
[% META title = 'Package overview' -%]
-<h1>[% package %]_[% svndebrelease %]</h1>
+<h1>[% sourcepackage_name %] [% IF epoch %][% epoch %]:[% END %][% version %][% IF ! isnative %]-[% debrevision %][% END %]</h1>
<h2>Maintainers</h2>
<table>
@@ -19,9 +19,7 @@
<div id="currentchangelogentry">
Current changelog entry:
<blockquote>
- [% FOREACH line IN currentchangelogentry -%]
- [% line %]<br />
- [% END -%]
+ [% debchangelogentry | html_line_break %]
</blockquote>
</div>
[% END %]
@@ -29,7 +27,7 @@
<h2>URI</h2>
<table>
<tr>
- <td>Repository location: <a href="[% uri %]">SVN</a> <a href="[% weburi %]">HTTP</a></td>
+ <td>Repository location: <a href="[% uri %][% subdir %]">raw</a><!-- <a href="[% %]">HTTP</a>--!></td>
</tr>
<tr>
<td [% IF iswatchfilebroken || !istarballpresent %]class="error"[% END %]>
@@ -54,9 +52,7 @@
<h2><a href="#" onclick="showhide('todo'); return(false);">TODO list</a></h2>
<div id="todo">
<blockquote>
- [% FOREACH line IN todo -%]
- [% line %]<br />
- [% END -%]
+ [% todo | html_line_break %]
</blockquote>
</div>
[% END -%]
@@ -82,80 +78,72 @@
</div>
[% END -%]
-[% IF builds %]
-<h2><a href="#" onclick="showhide('build'); return(false);">Builds</a></h2>
-<div id="build">
-<table>
- <tr><th>Status</th><th>Arch</th><th>Svn Rev.</th><th>Date</th><th>Build duration</th></tr>
- [% # Display each book in a table row %]
- [% FOREACH build IN builds -%]
- <tr [% IF ! build.isbuildok %]class="error"[% ELSE %]class="ok"[% END %]>
- <td>
- [% IF build.isbuildok %]
- <a href="[% Catalyst.uri_for('/logs/build/') _ build.id %]">Success</a>
- [% ELSE %]
- [% IF build.failedstep == "build" %]
- <a href="[% Catalyst.uri_for('/logs/build/') _ build.id %]">Build failed</a>
- [% ELSE %]
- failed during the "[% build.failedstep %]"
+[% IF changelogs %]
+ <h2><a href="#" onclick="showhide('changelog'); return(false);">Changelog</a></h2>
+ <div id="changelog">
+ [% FOREACH changelog IN changelogs -%]
+ <div class="changelogentry">
+ <a href="#" onclick="showhide('changelog-[[% changelog.changelogentry_id %]]'); return(false);">rev:[% changelog.rev %] by [% changelog.userlogin_name %]</a>
+ <div id="changelog-[[% changelog.changelogentry_id %]]" >
+ <div class="changelogtext" >
+ [% changelog.text %]
+ </div>
+ [% IF changelog.epoch %][% changelog.epoch %]:[% END %][% changelog.version %][% IF changelog.isnative %][% changelog.debrevision %][% END %][% changelog.date %]
+ [% IF changelog.builds %]
+ <table>
+ <tr><th>Status</th><th>Arch</th><th>Svn Rev.</th><th>Date</th><th>Build duration</th></tr>
+ [% # Display each book in a table row %]
+ [% FOREACH build IN changelog.builds -%]
+ <tr [% IF ! build.isbuildok %]class="error"[% ELSE %]class="ok"[% END %]>
+ <td>
+ [% IF build.isbuildok %]
+ <a href="[% Catalyst.uri_for('/logs/build/') _ build.id %]">Success</a>
+ [% ELSE %]
+ [% IF build.failedstep == "build" %]
+ <a href="[% Catalyst.uri_for('/logs/build/') _ build.id %]">Build failed</a>
+ [% ELSE %]
+ failed during the "[% build.failedstep %]"
+
+ [% END %]
+ [% END %]
+
+ </td>
+ <td>
+ [% build.arch %]
+ </td>
+ <td>
+ [% build.rev %]
+ </td>
+ <td>
+ [% build.time %]
+ </td>
+ <td>
+ [% IF build.duration %][% build.duration %]s[% END %]
+ </td>
+ </tr>
+ <tr>
+ <table>
+ <tr><th>tools</th><th>tags</th><th>messages</th></tr>
+ [% FOREACH qaresultentry IN build.qaresultentrys -%]
+ <tr
+ [% IF qaresultentry.letter == 'E' %]"class='error'"[% END %]: "class='warning'" %]
+ [% IF qaresultentry.letter == 'W' %]"class='warning'"[% END %]: "class='warning'" %]
+ [% IF qaresultentry.letter == 'I' %]"class='info'"[% END %]: "class='info'" %]
+ >
+ <td>[% qaresultentry.qatool_name %]</td>
+ <td>[% qaresultentry.qatag_name %]</td>
+ <td>[% qaresultentry.text %]</td>
+ </tr>
+ [% END -%]
+ </table>
+ </tr>
+ [% END -%]
- [% END %]
- [% END %]
-
- </td>
- <td>
- [% build.arch %]
- </td>
- <td>
- [% build.rev %]
- </td>
- <td>
- [% build.time %]
- </td>
- <td>
- [% IF build.duration %][% build.duration %]s[% END %]
- </td>
- </tr>
+ </table>
+ </div>
+ [% END %]
+ </div>
[% END -%]
-</table>
-</div>
-<h2>piuparts</h2>
-[% IF piupartsisok %]
-<a href="[% Catalyst.uri_for('/logs/piuparts/') _ build.id %]">piuparts checks successed</a>
-[% ELSE %]
-<a href="[% Catalyst.uri_for('/logs/piuparts/') _ build.id %]">piuparts checks failed (maybe a false negative?)</a>
+ </div>
[% END %]
-[% IF lintians %]
-<h2><a href="#" onclick="showhide('lintian'); return(false);">lintian</a></h2>
-<div id="lintian">
-<table>
- [% FOREACH lintian IN lintians %]
- <tr>
- <td [% IF lintian.error %]class="error"[% ELSE %]class="warning"[% END %]>
- [% lintian.text %]
- </td>
- </tr>
- [% END -%]
-</table>
-</div>
-[% END %]
-
-[% IF lindas %]
-<h2><a href="#" onclick="showhide('linda'); return(false);">linda</a></h2>
-<div id="linda">
-<table>
- [% FOREACH linda IN lindas %]
- <tr>
- <td [% IF linda.error %]class="error"[% ELSE %]class="warning"[% END %]>
- [% linda.text %]
- </td>
- </tr>
- [% END -%]
-</table>
-</div>
-[% END %]
-
-[% ELSE %]
-Never built yet.
-[% END -%]
Copied: svnbuildstat/trunk/root/src/packages/list.tt2 (from rev 1127, svnbuildstat/trunk/root/src/packages/listByMaintainer.tt2)
===================================================================
--- svnbuildstat/trunk/root/src/packages/list.tt2 (rev 0)
+++ svnbuildstat/trunk/root/src/packages/list.tt2 2008-08-25 20:10:43 UTC (rev 1128)
@@ -0,0 +1,134 @@
+[% # This is a TT comment. The '-' at the end "chomps" the newline. You won't -%]
+[% # see this "chomping" in your browser because HTML ignores blank lines, but -%]
+[% # it WILL eliminate a blank line if you view the HTML source. It's purely -%]
+[%- # optional, but both the beginning and the ending TT tags support chomping. -%]
+
+[% # Provide a title to root/lib/site/header -%]
+[% META title = 'Package list' -%]
+
+<h1>
+[% IF maintainer %]
+
+ [% IF maintainer.name %]
+ [% IF maintainer.email %]
+ <a href="http://qa.debian.org/developer.php?login=[% maintainer.email %]">
+ [% END %]
+
+ packages overview for [% maintainer.name %]
+
+ [% IF maintainer.email %]
+ </a>
+ [% END %]
+
+ [% END %]
+
+[% END %]
+</h1>
+
+<table>
+<tr><th>Packages</th><th>Status</th><th>Lintian</th><th>Bugs</th><!--<th>Piuparts--></th><th>Synced<br />with<br />Debian</th><th>Synced<br />with<br />Upstream</th></tr>
+[% # Display each book in a table row %]
+[% FOREACH package IN packages -%]
+ [% IF ! package.dscuri && ! package.isnative %]
+ [% buildstatus = 'no-src-pkg' %]
+ [% ELSE %]
+ [% IF ! package.buildallcount > 0 %]
+ [% buildstatus = 'need-build' %]
+ [% ELSE %]
+ [% IF package.buildallcount == package.buildokcount %]
+ [% buildstatus = 'ok' %]
+ [% ELSE %][% IF package.buildallcount > 0 %][% buildstatus = 'unknow' %][% END %][% END %]
+ [% IF package.buildallcount == 0 %][% buildstatus = 'failed' %][% END %]
+ [% END %]
+ [% END %]
+
+ [% bugcount = 0 %]
+ [% rcbugcount = 0 %]
+ [% bugstring = '' %]
+ [% FOREACH bug IN package.bugs -%]
+ [% bugcount = bugcount+1 %]
+ [% IF bug.severity == 'critical' %][% rcbugcount = rcbugcount+1 %][% END %]
+ [% IF bug.severity == 'grave' %][% rcbugcount = rcbugcount+1 %][% END %]
+ [% IF bug.severity == 'serious' %][% rcbugcount = rcbugcount+1 %][% END %]
+ [% IF bug.severity == 'important' %][% rcbugcount = rcbugcount+1 %][% END %]
+ [% bugstring = bugstring _ '<li>#' _ bug.id _ ': ' _ bug.severity _ ' ' _ bug.desc _ '</li>' %]
+ [% END %]
+
+
+ [% lintiancount = 0 %]
+ [% lintianerrcount = 0 %]
+ [% lintianstring = '' %]
+ [% FOREACH lintian IN package.lintians -%]
+ [% lintiancount = lintiancount+1 %]
+ [% IF lintian.letter == 'E' %][% lintianerrcount = lintianerrcount+1 %][% END %]
+ [% lintianstring = lintianstring _ '<li>#' _ lintian.letter _ ': ' _ lintian.tag _ ' ' _ lintian.text _ '</li>' %]
+ [% END %]
+
+ <tr>
+ <td>
+ <a href="[% Catalyst.uri_for('info/') _ package.sourcepackage_name %]"><strong>[% package.sourcepackage_name %]</strong></a>
+ </td>
+ <td
+ [% IF buildstatus == 'no-src-pkg' %]class="error"[% END %]
+ [% IF buildstatus == 'unknow' %]class="error"[% END %]
+ [% IF buildstatus == 'failed' %]class="error"[% END %]
+ [% IF buildstatus == 'ok' %]class="ok"[% END %]
+ >
+
+ <a href="[% Catalyst.uri_for('info/') _ package.sourcepackage_name %]">
+ [% buildstatus %]
+ </a>
+ </td>
+ <td [% IF lintianerrcount > 0 %]class="error"[% ELSE %][% IF lintiancount > 0 %]class="warning"[% ELSE %][% IF package.isbuildok %]class="ok"[% END %][% END %][% END %]>
+ <a href="[% Catalyst.uri_for('info/') _ package.sourcepackage_name %]" onMouseOver="ShowHelpbox('[% lintianstring | html | replace ("'", '`') %]')" onMouseOut="HideHelpBox()">
+ [% IF lintiancount > 0 %][% lintiancount %][% END %]
+ </a>
+ </td>
+
+
+ <td [% IF bugcount == 0 %]class="ok"[% ELSE %][% IF rcbugcount > 0 %]class="error"[% ELSE %]class="warning"[% END %][% END %]>
+ <A href="http://bugs.debian.org/[% package.sourcepackage_name %]" onMouseOver="ShowHelpbox('[% bugstring | html | replace ("'", '`') %]')" onMouseOut="HideHelpBox()">
+ [% IF bugcount > 0 %]bug:[% bugcount %][% END %]
+ [% IF rcbugcount > 0 %] ([% rcbugcount %] RC)[% END %]
+ </a>
+ </td>
+<!-- <td [% IF package.piupartsisok %]class="ok"[% ELSE %][% IF package.isbuildok %]class="error"[% END %][% END %]>
+ <a href="[% Catalyst.uri_for('info/') _ package.name %]">
+ [% IF ! package.needbuild && package.isbuildok %][% IF package.piupartsisok %]Succeed[% ELSE %]Failed[% END %][% END %]
+ </a>
+ </td>-->
+ <td [% IF package.isindebian %]class="ok"[% ELSE %]class="warning"[% END %]>
+ [% IF ! package.isindebian %]Not uploaded yet<br />
+[% FOREACH bug IN package.currentpendingbug.split(',') %]
+ <a href="http://bugs.debian.org/[% bug %]">Closes: #[% bug %]</a><br />
+ [% END %]
+
+[% END %]
+
+
+<div id="hoverpopup" style="visibility:hidden; position:absolute;">
+<table bgcolor="#0000FF">
+ <tr><td><font color="#FFFFFF">This is my popup</font></td></tr>
+ <tr><td bgcolor="#8888FF">Hello I am a popup table</td></tr>
+ </table>
+ </div>
+
+
+ </td>
+ <td [% IF package.iswatchfilebroken || package.issyncedwithupstream == 0 %]class="error"[% ELSE %][% IF package.issyncedwithupstream == 1 || package.isnative == 1 %]class="ok"[% ELSE %]class="warning"[% END %][% END %]>
+ <a href="[% Catalyst.uri_for('info/') _ package.name %]">
+ [% IF package.isnative == 1 %]
+ Native
+ [% ELSE %]
+ [% IF package.iswatchfilebroken == 1 %]
+ Broken watch file
+ [% ELSE%]
+ [% IF package.issyncedwithupstream == 0 %]New upstream release[% END %]
+ [% IF package.issyncedwithupstream == "" %]No watch file[% END %]
+ [% END %]
+ [% END %]
+ </a>
+ </td>
+ </tr>
+[% END -%]
+</table>
Deleted: svnbuildstat/trunk/root/src/packages/listByMaintainer.tt2
===================================================================
--- svnbuildstat/trunk/root/src/packages/listByMaintainer.tt2 2008-08-25 16:47:46 UTC (rev 1127)
+++ svnbuildstat/trunk/root/src/packages/listByMaintainer.tt2 2008-08-25 20:10:43 UTC (rev 1128)
@@ -1,134 +0,0 @@
-[% # This is a TT comment. The '-' at the end "chomps" the newline. You won't -%]
-[% # see this "chomping" in your browser because HTML ignores blank lines, but -%]
-[% # it WILL eliminate a blank line if you view the HTML source. It's purely -%]
-[%- # optional, but both the beginning and the ending TT tags support chomping. -%]
-
-[% # Provide a title to root/lib/site/header -%]
-[% META title = 'Package list' -%]
-
-<h1>
-[% IF maintainer %]
-
- [% IF maintainer.name %]
- [% IF maintainer.email %]
- <a href="http://qa.debian.org/developer.php?login=[% maintainer.email %]">
- [% END %]
-
- packages overview for [% maintainer.name %]
-
- [% IF maintainer.email %]
- </a>
- [% END %]
-
- [% END %]
-
-[% END %]
-</h1>
-
-<table>
-<tr><th>Packages</th><th>Status</th><th>Lintian</th><th>Bugs</th><!--<th>Piuparts--></th><th>Synced<br />with<br />Debian</th><th>Synced<br />with<br />Upstream</th></tr>
-[% # Display each book in a table row %]
-[% FOREACH package IN packages -%]
- [% IF ! package.dscuri && ! package.isnative %]
- [% buildstatus = 'no-src-pkg' %]
- [% ELSE %]
- [% IF ! package.buildallcount > 0 %]
- [% buildstatus = 'need-build' %]
- [% ELSE %]
- [% IF package.buildallcount == package.buildokcount %]
- [% buildstatus = 'ok' %]
- [% ELSE %][% IF package.buildallcount > 0 %][% buildstatus = 'unknow' %][% END %][% END %]
- [% IF package.buildallcount == 0 %][% buildstatus = 'failed' %][% END %]
- [% END %]
- [% END %]
-
- [% bugcount = 0 %]
- [% rcbugcount = 0 %]
- [% bugstring = '' %]
- [% FOREACH bug IN package.bugs -%]
- [% bugcount = bugcount+1 %]
- [% IF bug.severity == 'critical' %][% rcbugcount = rcbugcount+1 %][% END %]
- [% IF bug.severity == 'grave' %][% rcbugcount = rcbugcount+1 %][% END %]
- [% IF bug.severity == 'serious' %][% rcbugcount = rcbugcount+1 %][% END %]
- [% IF bug.severity == 'important' %][% rcbugcount = rcbugcount+1 %][% END %]
- [% bugstring = bugstring _ '<li>#' _ bug.id _ ': ' _ bug.severity _ ' ' _ bug.desc _ '</li>' %]
- [% END %]
-
-
- [% lintiancount = 0 %]
- [% lintianerrcount = 0 %]
- [% lintianstring = '' %]
- [% FOREACH lintian IN package.lintians -%]
- [% lintiancount = lintiancount+1 %]
- [% IF lintian.letter == 'E' %][% lintianerrcount = lintianerrcount+1 %][% END %]
- [% lintianstring = lintianstring _ '<li>#' _ lintian.letter _ ': ' _ lintian.tag _ ' ' _ lintian.text _ '</li>' %]
- [% END %]
-
- <tr>
- <td>
- <a href="[% Catalyst.uri_for('info/') _ package.sourcepackage_name %]"><strong>[% package.sourcepackage_name %]</strong></a>
- </td>
- <td
- [% IF buildstatus == 'no-src-pkg' %]class="error"[% END %]
- [% IF buildstatus == 'unknow' %]class="error"[% END %]
- [% IF buildstatus == 'failed' %]class="error"[% END %]
- [% IF buildstatus == 'ok' %]class="ok"[% END %]
- >
-
- <a href="[% Catalyst.uri_for('info/') _ package.sourcepackage_name %]">
- [% buildstatus %]
- </a>
- </td>
- <td [% IF lintianerrcount > 0 %]class="error"[% ELSE %][% IF lintiancount > 0 %]class="warning"[% ELSE %][% IF package.isbuildok %]class="ok"[% END %][% END %][% END %]>
- <a href="[% Catalyst.uri_for('info/') _ package.sourcepackage_name %]" onMouseOver="ShowHelpbox('[% lintianstring | html | replace ("'", '`') %]')" onMouseOut="HideHelpBox()">
- [% IF lintiancount > 0 %][% lintiancount %][% END %]
- </a>
- </td>
-
-
- <td [% IF bugcount == 0 %]class="ok"[% ELSE %][% IF rcbugcount > 0 %]class="error"[% ELSE %]class="warning"[% END %][% END %]>
- <A href="http://bugs.debian.org/[% package.sourcepackage_name %]" onMouseOver="ShowHelpbox('[% bugstring | html | replace ("'", '`') %]')" onMouseOut="HideHelpBox()">
- [% IF bugcount > 0 %]bug:[% bugcount %][% END %]
- [% IF rcbugcount > 0 %] ([% rcbugcount %] RC)[% END %]
- </a>
- </td>
-<!-- <td [% IF package.piupartsisok %]class="ok"[% ELSE %][% IF package.isbuildok %]class="error"[% END %][% END %]>
- <a href="[% Catalyst.uri_for('info/') _ package.name %]">
- [% IF ! package.needbuild && package.isbuildok %][% IF package.piupartsisok %]Succeed[% ELSE %]Failed[% END %][% END %]
- </a>
- </td>-->
- <td [% IF package.isindebian %]class="ok"[% ELSE %]class="warning"[% END %]>
- [% IF ! package.isindebian %]Not uploaded yet<br />
-[% FOREACH bug IN package.currentpendingbug.split(',') %]
- <a href="http://bugs.debian.org/[% bug %]">Closes: #[% bug %]</a><br />
- [% END %]
-
-[% END %]
-
-
-<div id="hoverpopup" style="visibility:hidden; position:absolute;">
-<table bgcolor="#0000FF">
- <tr><td><font color="#FFFFFF">This is my popup</font></td></tr>
- <tr><td bgcolor="#8888FF">Hello I am a popup table</td></tr>
- </table>
- </div>
-
-
- </td>
- <td [% IF package.iswatchfilebroken || package.issyncedwithupstream == 0 %]class="error"[% ELSE %][% IF package.issyncedwithupstream == 1 || package.isnative == 1 %]class="ok"[% ELSE %]class="warning"[% END %][% END %]>
- <a href="[% Catalyst.uri_for('info/') _ package.name %]">
- [% IF package.isnative == 1 %]
- Native
- [% ELSE %]
- [% IF package.iswatchfilebroken == 1 %]
- Broken watch file
- [% ELSE%]
- [% IF package.issyncedwithupstream == 0 %]New upstream release[% END %]
- [% IF package.issyncedwithupstream == "" %]No watch file[% END %]
- [% END %]
- [% END %]
- </a>
- </td>
- </tr>
-[% END -%]
-</table>
Modified: svnbuildstat/trunk/root/src/teams/main.tt2
===================================================================
--- svnbuildstat/trunk/root/src/teams/main.tt2 2008-08-25 16:47:46 UTC (rev 1127)
+++ svnbuildstat/trunk/root/src/teams/main.tt2 2008-08-25 20:10:43 UTC (rev 1128)
@@ -9,7 +9,7 @@
<table>
[% FOREACH team IN teams -%]
<tr>
-<td><a href="[% Catalyst.uri_for('/packages/listByTeam/') _ team.id %]"><strong>[% team.name %]</strong></a></td>
+<td><a href="[% Catalyst.uri_for('/packages/list/') _ team.email %]"><strong>[% team.name %]</strong></a></td>
</tr>
[% END -%]
</table>
Modified: svnbuildstat/trunk/root/src/ttsite.css
===================================================================
--- svnbuildstat/trunk/root/src/ttsite.css 2008-08-25 16:47:46 UTC (rev 1127)
+++ svnbuildstat/trunk/root/src/ttsite.css 2008-08-25 20:10:43 UTC (rev 1128)
@@ -261,6 +261,25 @@
}
*/
+
+.changelogentry
+{
+
+
+ padding: 0.5ex;
+ border: 1px dotted;
+ margin: 3ex;
+}
+
+.changelogtext
+{
+
+
+ padding: 0.5ex;
+ margin: 3ex;
+ background: #e6dede;
+}
+
.error
{
background-color: #e49797;
More information about the Collab-qa-commits
mailing list