Take the 2-minute tour ×
Stack Apps is a question and answer site for apps, scripts, and development with the Stack Exchange API. It's 100% free, no registration required.

Resolution

Fix confirmed:

Tests.SortDupBug
Page 1 #100
Total 11066 api.serverfault.com /users?max=2147483647&min=99&page=1&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw

Page 2 #100
Total 11066 api.serverfault.com /users?max=2147483647&min=99&page=2&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw

Dupes
iteration 0

---------------------------------------


Page 1 #100
Total 11157 api.superuser.com /users?max=2147483647&min=99&page=1&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw

Page 2 #100
Total 11157 api.superuser.com /users?max=2147483647&min=99&page=2&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw


Dupes
iteration 0

---------------------------------------


Page 1 #100
Total 8909 api.meta.stackoverflow.com /users?max=2147483647&min=99&page=1&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw


Page 2 #100
Total 8909 api.meta.stackoverflow.com /users?max=2147483647&min=99&page=2&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw


Dupes
iteration 0

---------------------------------------


Page 1 #100
Total 1904 api.webapps.stackexchange.com /users?max=2147483647&min=99&page=1&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw


Page 2 #100
Total 1904 api.webapps.stackexchange.com /users?max=2147483647&min=99&page=2&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw

Dupes
iteration 0





Downgraded from red alert to "i wonder where else this will pop up".

It seems that the problem is grouping around short lists, or perhaps the end of lists.

Notice that some sites have a single odd dupe. This can be explained many ways and is to be expected.

The sites with less than 2 pages of users show significant anomalies.

Again, this could be due to a low user count or due to proximity to end of list.

Finding out why it is happening might shed light on other possible problems.



--------------------------------
Page 1 #100
Total 11024 api.serverfault.com /users?max=2147483647&min=99&page=1&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw

Page 2 #100
Total 11024 api.serverfault.com /users?max=2147483647&min=99&page=2&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw

Dupes
iteration 0
--------------------------------

Page 1 #100
Total 11111 api.superuser.com /users?max=2147483647&min=99&page=1&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw

Page 2 #100
Total 11111 api.superuser.com /users?max=2147483647&min=99&page=2&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw


Dupes
iteration 0

--------------------------------

Page 1 #100
Total 8867 api.meta.stackoverflow.com /users?max=2147483647&min=99&page=1&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw

Page 2 #100
Total 8867 api.meta.stackoverflow.com /users?max=2147483647&min=99&page=2&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw

Dupes
iteration 0

--------------------------------
Page 1 #100
Total 1866 api.webapps.stackexchange.com /users?max=2147483647&min=99&page=1&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw

Page 2 #100
Total 1866 api.webapps.stackexchange.com /users?max=2147483647&min=99&page=2&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw


Dupes
iteration 0

--------------------------------

Page 1 #100
Total 627 api.meta.webapps.stackexchange.com /users?max=2147483647&min=99&page=1&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw


Page 2 #100
Total 627 api.meta.webapps.stackexchange.com /users?max=2147483647&min=99&page=2&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw

Dupes
iteration 0

--------------------------------

Page 1 #100
Total 951 api.gaming.stackexchange.com /users?max=2147483647&min=99&page=1&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw


Page 2 #100
Total 951 api.gaming.stackexchange.com /users?max=2147483647&min=99&page=2&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw


Dupes
iteration 0

--------------------------------

Page 1 #100
Total 360 api.meta.gaming.stackexchange.com /users?max=2147483647&min=99&page=1&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw


Page 2 #100
Total 360 api.meta.gaming.stackexchange.com /users?max=2147483647&min=99&page=2&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw


Dupes
iteration 0

--------------------------------

Page 1 #100
Total 626 api.webmasters.stackexchange.com /users?max=2147483647&min=99&page=1&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw


Page 2 #100
Total 626 api.webmasters.stackexchange.com /users?max=2147483647&min=99&page=2&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw


Dupes
iteration 0

--------------------------------

Page 1 #100
Total 188 api.meta.webmasters.stackexchange.com /users?max=2147483647&min=99&page=1&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw


Page 2 #88
Total 188 api.meta.webmasters.stackexchange.com /users?max=2147483647&min=99&page=2&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw


Dupes
iteration 0
575, 

--------------------------------

Page 1 #100
Total 772 api.cooking.stackexchange.com /users?max=2147483647&min=99&page=1&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw


Page 2 #100
Total 772 api.cooking.stackexchange.com /users?max=2147483647&min=99&page=2&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw


Dupes
iteration 0
88, 

--------------------------------

Page 1 #100
Total 268 api.meta.cooking.stackexchange.com /users?max=2147483647&min=99&page=1&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw


Page 2 #100
Total 268 api.meta.cooking.stackexchange.com /users?max=2147483647&min=99&page=2&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw



Dupes
iteration 0
176, 

--------------------------------

Page 1 #100
Total 213 api.gamedev.stackexchange.com /users?max=2147483647&min=99&page=1&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw


Page 2 #100
Total 213 api.gamedev.stackexchange.com /users?max=2147483647&min=99&page=2&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw


Dupes
iteration 0

--------------------------------

Page 1 #100
Total 109 api.meta.gamedev.stackexchange.com /users?max=2147483647&min=99&page=1&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw


Page 2 #9
Total 109 api.meta.gamedev.stackexchange.com /users?max=2147483647&min=99&page=2&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw


Dupes
iteration 0
63, 60, 49, 16, 5, 4, 3, 2, 

--------------------------------

Page 1 #100
Total 172 api.gadgets.stackexchange.com /users?max=2147483647&min=99&page=1&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw

Page 2 #72
Total 172 api.gadgets.stackexchange.com /users?max=2147483647&min=99&page=2&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw

Dupes
iteration 0
41, 38, 37, 34, 32, 30, 29, 25, 18, 21, 7, 11, 10, 4, 

--------------------------------
Page 1 #87
Total 87 api.meta.gadgets.stackexchange.com /users?max=2147483647&min=99&page=1&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw

Page 2 #0
Total 87 api.meta.gadgets.stackexchange.com /users?max=2147483647&min=99&page=2&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw

Dupes
iteration 0

--------------------------------

Page 1 #100
Total 177 api.photo.stackexchange.com /users?max=2147483647&min=99&page=1&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw

124 

Page 2 #77
Total 177 api.photo.stackexchange.com /users?max=2147483647&min=99&page=2&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw

Dupes
iteration 0

--------------------------------

Page 1 #92
Total 92 api.meta.photo.stackexchange.com /users?max=2147483647&min=99&page=1&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw


Page 2 #0
Total 92 api.meta.photo.stackexchange.com /users?max=2147483647&min=99&page=2&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw

Dupes
iteration 0

--------------------------------

Page 1 #100
Total 142 api.stats.stackexchange.com /users?max=2147483647&min=99&page=1&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw


Page 2 #42
Total 142 api.stats.stackexchange.com /users?max=2147483647&min=99&page=2&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw


Dupes
iteration 0
135, 134, 35, 33, 30, 29, 21, 19, 18, 16, 12, 10, 7, 4, 3, 2, 43, 27, 53, 51, 50, 102, 94, 84, 76, 65, 64, 129, 127, 

--------------------------------

Page 1 #67
Total 67 api.meta.stats.stackexchange.com /users?max=2147483647&min=99&page=1&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw


Page 2 #0
Total 67 api.meta.stats.stackexchange.com /users?max=2147483647&min=99&page=2&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw


Dupes
iteration 0

--------------------------------

Page 1 #100
Total 122 api.math.stackexchange.com /users?max=2147483647&min=99&page=1&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw


Page 2 #22
Total 122 api.math.stackexchange.com /users?max=2147483647&min=99&page=2&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw

Dupes
iteration 0
98, 83, 81, 78, 77, 75, 71, 69, 68, 60, 46, 32, 27, 18, 15, 14, 7, 4, 2, 

--------------------------------

Page 1 #77
Total 77 api.meta.math.stackexchange.com /users?max=2147483647&min=99&page=1&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw


Page 2 #0
Total 77 api.meta.math.stackexchange.com /users?max=2147483647&min=99&page=2&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw


Dupes
iteration 0

--------------------------------

Page 1 #100
Total 1766 api.stackapps.com /users?max=2147483647&min=99&page=1&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw


Page 2 #100
Total 1766 api.stackapps.com /users?max=2147483647&min=99&page=2&pagesize=100&key=qgAq_KfDu0KYzlNG-qaTuw


Dupes
iteration 0


share|improve this question
    
Wow. You've really found a big one here. –  Nathan Osman Jul 21 '10 at 14:19
    
@george - after writing some targeted tests not quite as bad as I feared, but may be a fair warning for something else. time will tell. –  Sky Sanders Jul 21 '10 at 22:04
    
I noticed that the API is going down for maintenance tonight. Maybe that will be fixed. –  Nathan Osman Jul 21 '10 at 22:10
add comment

1 Answer 1

up vote 0 down vote accepted

Guaranteeing sort stability is... tricky in terms of performance.

For instance, /search is basically never going to be stable.

However, in this case (reputation sorting on users) a stable sort isn't too bad.

In short, this should be fixed now.

share|improve this answer
2  
yes, I agree that for an arbitrary query like /search, predictable results should not be expected because what are you going to compare them to? but for getting fixed (mostly fixed) resources like users, a stable sort should be expected. Thanks for taking care of this. I will run some test later to confirm. –  Sky Sanders Jul 22 '10 at 17:44
add comment

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .