Bug#1073562: qa.debian.org: popcon statistic graphs not updated since May

2024-06-28 Thread Sven Geuer
The issue is also mentioned on the debian-popcon mailing list [1].
According to the reply [2] the popcon data still get collected.

Also qa.debian.org/developer.php [3] only displays the popcon numbers
dating back to 2024-05-22.

[1] https://lists.debian.org/debian-popcon/2024/06/msg0.html
[2] https://lists.debian.org/debian-popcon/2024/06/msg1.html
[3] https://qa.debian.org/developer.php?gpg_key=F8ADD585&comaint=yes

Cheers,
Sven
-- 
GPG Fingerprint
3DF5 E8AA 43FC 9FDF D086 F195 ADF5 0EDA F8AD D585


signature.asc
Description: This is a digitally signed message part


Re: Popcon stats not updated

2024-06-28 Thread Lev Lazinskiy
On Tue, Jun 25, 2024 at 03:35:52PM +0200, Bill Allombert wrote:
> On Tue, Jun 25, 2024 at 10:34:15AM +0200, Fab Stz wrote:
> > Hello, 
> > 
> > Not sure that you are in charge of this, so please forward to whom it may 
> > concern. 
> > I noticed that the popcon stats haven't been updated for approximately a 
> > month now.
> 
> Hello Fab, 
> 
> I have just checked the server, the archive is complete, there is no holes:
> 
> So I assume the issue is within
> https://qa.debian.org/popcon.php
> itself, so this should be reported to qa.debian.org.
> When I go to
> https://qa.debian.org/popcon.php?package=freefilesync
> and click on "Raw data for the graph" I am lead to the following URL:
> https://qa.debian.org/cgi-bin/popcon-data?packages=freefilesync;from_date=2010-07-10;to_date=2024-05-22
> So I only get data up to the 2024-05-22 which is about one month ago, indeed.

I suspect that there is a cronjob or something that is running to update
the database. Looking at the code for this page [1], if the to_date is not
set explicitly then it will try to find the latest date for a given
package. 

```
$to_date = $dbh->selectrow_array('SELECT max(p.day) FROM popcon_package pp JOIN 
popcon p ON (pp.id = p.package_id) JOIN popcon_day pd ON (pd.day = p.day) WHERE 
package = ANY(?) AND in_debian AND (p.vote > 0 OR p.old > 0 OR p.recent > 0 or 
p.no_files > 0)', undef, \@packages) if !$to_date;
```

There is a perl script called popcon-import [2] that runs somewhere, can
someone who has access to these logs [3] take a look?


[1] 
https://salsa.debian.org/qa/qa/-/blob/master/cgi-bin/popcon-data?ref_type=heads#L45
 

[2]  
https://salsa.debian.org/qa/qa/-/blob/master/popcon-graphs/popcon-import?ref_type=heads#L55

[3] my $logfile = "/srv/qa.debian.org/log/popcon.log";

-- 
Best, 
Lev 

https://levlaz.org 



Bug#1073562: qa.debian.org: (Some?) popcon statistic graphs not updated since May

2024-06-28 Thread Lev Lazinskiy
On Mon, Jun 17, 2024 at 04:04:59PM +0200, Bastian Venthur wrote:
> Package: qa.debian.org
> Severity: normal
> X-Debbugs-Cc: vent...@debian.org
> 
> Dear Maintainer,
> 
> Hi,
> 
> browsing to:
> 
> https://qa.debian.org/popcon-graph.php?packages=python3-debianbts+python3-pysimplesoap&show_installed=on&want_legend=on&want_ticks=on&from_date=2024-05-15&to_date=&hlght_date=&date_fmt=%25m-%25d&beenhere=1
> 
> I've noticed that this graph hasn't been updated for almost a month. Not sure
> how often the graphs are supposed to be updated, but maybe some cron job is
> broken?
> 
> 
> Cheers,
> 
> Bastian
> 

I think this is the same bug that was reported here [4]. I did an
investigation based on the code, but I don't have access to any of the
logs. Could someone with access take a look please? 

This appears to be broken for all packages. 

I suspect that there is a cronjob or something that is running to update
the database. Looking at the code for this page [1], if the to_date is not
set explicitly then it will try to find the latest date for a given
package.

```
$to_date = $dbh->selectrow_array('SELECT max(p.day) FROM popcon_package pp JOIN 
popcon p ON
(pp.id = p.package_id) JOIN popcon_day pd ON (pd.day = p.day) WHERE package = 
ANY(?) AND
in_debian AND (p.vote > 0 OR p.old > 0 OR p.recent > 0 or p.no_files > 0)', 
undef,
\@packages) if !$to_date;
```

There is a perl script called popcon-import [2] that runs somewhere, can
someone who has access to these logs [3] take a look?


[1] 
https://salsa.debian.org/qa/qa/-/blob/master/cgi-bin/popcon-data?ref_type=heads#L45

[2]
https://salsa.debian.org/qa/qa/-/blob/master/popcon-graphs/popcon-import?ref_type=heads#L55

[3] my $logfile = "/srv/qa.debian.org/log/popcon.log";

[4] https://lists.debian.org/debian-qa/2024/06/msg00012.html