Closed
Bug 356435
Opened 18 years ago
Closed 18 years ago
VersionCheck.php does not compare versions correctly
Categories
(addons.mozilla.org Graveyard :: Public Pages, defect)
addons.mozilla.org Graveyard
Public Pages
Tracking
(Not tracked)
VERIFIED
FIXED
People
(Reporter: fligtar, Assigned: morgamic)
References
()
Details
(Keywords: fixed1.8.1, Whiteboard: [server side])
Attachments
(1 file)
6.48 KB,
patch
|
fligtar
:
first-review+
|
Details | Diff | Splinter Review |
http://lxr.mozilla.org/mozilla/source/webtools/update/update/VersionCheck.php
VersionCheck does not use our inc_version_comparison.php functions to compare versions, and as a result does not always show the latest available version to an add-on.
We have run into this problem frequently lately with minversions like 2.0b1, 2.0b2, Deer Park and a maxversion of 2.0.0.*. VersionCheck will return the latest "compatible" version, or if there is none, will be empty.
I can't provide a good example URL because I've been setting minversions to 2.0 as people complain so that they'll be fixed.
Assignee | ||
Updated•18 years ago
|
Severity: critical → blocker
Status: NEW → ASSIGNED
Flags: blocking-firefox2?
Updated•18 years ago
|
Severity: blocker → critical
Assignee | ||
Comment 1•18 years ago
|
||
This should fix the problems caused by version comparison in SQL. The assumption here is that pulling the latest overall version is desirable -- and I think it is in almost every case.
The edge case is when someone has an outdated version and they can only go up to a mid-way version for an extension. So, if someone had Fx 1.5 and they had updates for Flashgot, but the newest Flashgot required Fx 2.0 we'd have a problem. They couldn't update to, for example, 2 versions lower than the most recent. They could only update to the latest.
The alternative to fix this edge case would be to pull N versions from the database in order to loop through them and run NS_CompareVersions() on each instance. I don't think that scales, and I'm not interested in doing that because it's not worth the effort or the perf cost.
Assignee: nobody → morgamic
Attachment #242133 -
Flags: first-review?(fligtar)
Reporter | ||
Comment 2•18 years ago
|
||
Comment on attachment 242133 [details] [diff] [review]
Diff to remove dependence on SQL sorting of appVersion.
I think we should try to come up with a way to deal with exception you mentioned, but it's more important to get this bug's problem fixed ASAP.
r=fligtar
Attachment #242133 -
Flags: first-review?(fligtar) → first-review+
Updated•18 years ago
|
Flags: blocking-firefox2? → blocking-firefox2+
Whiteboard: [server side]
Assignee | ||
Comment 3•18 years ago
|
||
Guys -- you see any reason why we can't push this today?
Assignee | ||
Comment 4•18 years ago
|
||
This has been updated, and the case we were trying to solve looks good:
https://addons.mozilla.org/update/VersionCheck.php?reqVersion=1&id=de-DE@dictionaries.addons.mozilla.org&version=1.0.1&maxAppVersion=2.0b2&status=userEnabled,incompatible&appID=%7Bec8030f7-c20a-464f-9b0e-13a3a9e97384%7D&appVersion=2.0&appOS=Linux&appABI=x86-gcc3
Status: ASSIGNED → RESOLVED
Closed: 18 years ago
Resolution: --- → FIXED
Comment 5•18 years ago
|
||
Verified.
The case above works for both the case when I set 2.0b1-2.0.0.* and 2.0b1-3.0a1
Status: RESOLVED → VERIFIED
Reporter | ||
Comment 6•18 years ago
|
||
*** Bug 354890 has been marked as a duplicate of this bug. ***
Updated•18 years ago
|
Keywords: fixed1.8.1
Updated•9 years ago
|
Product: addons.mozilla.org → addons.mozilla.org Graveyard
You need to log in
before you can comment on or make changes to this bug.
Description
•