Help wanted: Re: bugs.kde.org rejects tonight's CVS as outdated

Martijn Klingens klingens at kde.org
Thu Jul 4 12:51:50 BST 2002


On Thursday 04 July 2002 09:45, Rob Kaper wrote:
> On Thu, Jul 04, 2002 at 09:39:27AM +0200, Malte Starostik wrote:
> > just tried to submit a bug report about kmail. Both kdelibs and
> > kdenetwork were updated and compiled less than 12 hours ago, but it would
> > reject the version as obsolete alpha/beta. The version as reported in
> > "About KDE" is "3.0.6 (KDE 3.1 alpha1)". Complete kmail version string as
> > sent to bugs.kde.org: "1.4.5 (KDE 3.0.6 (KDE 3.1 alpha1)) (compiled
> > sources)". Only manually selecting the version helped.

The version string "1.4.5 (KDE 3.0.6 (KDE 3.1 alpha1)) (compiled sources)" 
doesn't properly pass the regexp

$version = ereg_replace( ".*\\((KDE.*)\\) \\(.*\\)", "\\1", $version );

in bugs/html/wizard/include/kdeversion.php.

It results in $version being "KDE 3.1 alpha1)", i.e. it starts matching on the 
last 'KDE' phrase instead of the first. I have no idea how to make the regexp 
more greedy though. I should probably learn to use preg one day, because you 
can control greedyness there. Also, having $version, $appVersion and 
$distribution in a single array and a single regexp (instead of using three 
separate regexps) would be useful.

I'll leave for a few days tomorrow with no access to email, CVS or whatsoever 
and I don't expect to find time to fix this today. Next opportunity for me is 
next tuesday to look into this, so I would very much like it if someone else 
who knows PHP regexps well could fix this for me and send a patch to someone 
with enough karma to commit to bugs/. If nobody picks this up before tuesday 
I'll fix it myself, but sooner is better here :-)

Anyone interested can checkout bugs/ from CVS and adjust 
html/wizard/config.php to his own local webserver's settings. Add some echo's 
to kdeversion.php, line 77 and beyond to see what the variables contain. 
$version is the culprit here.

Thanks,
-- 
Martijn





More information about the kde-core-devel mailing list