[wpkg-users] error when comparing version strings of different length

Rainer Meier r.meier at wpkg.org
Tue Sep 11 16:30:38 CEST 2012


Hello,

On 11.09.2012 14:14, jurgen.depicker at let.be wrote:
> I have a problem comparable to the libreoffice problem from this morning.

I think it's unrelated. (apart that you're both comparing version strings).


> 2012-09-11 14:00:02, DEBUG   : Comparing version fragments: '4' <=> ''
> 2012-09-11 14:00:02, ERROR   : Message:    'length' is null or not an
> object|Description:  'length' is null or not an object|Error number:
> 800a138f|Stack:  undefined|Line:         undefined|
> 2012-09-11 14:00:02, DEBUG   : No locale language definition found for message
> ID 'notifyUserFail' (language LCID '813').
> 2012-09-11 14:00:02, INFO    : User notification suppressed. Message: The
> software installation has failed.

In your case it looks like WPKG clearly fails because it tries to parse another 
version digit which does not exist (dot at the end). This perhaps can be fixed 
in the code (I will have to check).

A work-around to fix it on all clients would be to just increment the revision 
of the package to something which increments on third digit (e.g. 6.0.341.4).

Thus WPKG would start comparing
6 <=> 6
0 <=> 0
341 <=> 340

And then stop since the new revision seems to be higher. So the questionable 
code which compares
4 <=> ''

would not even be executed. After successful upgrade then WPKG would insert the 
new package with updated revision (without trailing dot) into wpkg.xml and you 
can continue as usual.


br,
Rainer



More information about the wpkg-users mailing list