Welcome to Codidact Meta!
Codidact Meta is the meta-discussion site for the Codidact community network and the Codidact software. Whether you have bug reports or feature requests, support questions or rule discussions that touch the whole network – this is the site for you.
Comments on Answers order is changed when we access a specific answer by its direct link
Parent
Answers order is changed when we access a specific answer by its direct link
Not sure if this is a bug, or status-by-design (for now, tagged as bug just in case)
When accessing an answer by its direct link, its order (relative to all other answers) is changed.
Example: if I go to this question, the answers are displayed by Score (I guess this is the default?), with highest scores first. If I click on the sort options ("Score" or "Active"), it all works well.
But if I access that post using a direct link to a specific answer, that answer is displayed before all the others, even though it has the lowest score. That happens even if I explicitly choose to sort the answers by Score: clicking on "Score", the link changes to this, and it still shows that specific answer (which has a lower score) before the others with higher scores.
That happens only if the link contains an answer ID. Summary:
- Links to question: OK (answers displayed in correct order)
https://meta.codidact.com/posts/276161
https://meta.codidact.com/posts/276161?sort=score
- Links to specific answer: Not OK (the specific answer is displayed before the other answers, although it has a lower score)
https://meta.codidact.com/posts/276161/276162#answer-276162
https://meta.codidact.com/posts/276161/276162?sort=score
Is it intentional that the display order of answers is changed like that when we access it by an answer's direct link?
Post
This is by design. Sometimes, for example for the Code Golf scoreboard, we need to have a direct link to the answers. Since on questions with many answers the answers are paginated and the order is calculated "on the fly", it's not possible to say beforehand, on which page an answer would be.
Therefore we added that helper URL which forces the answer to be shown without regards to the pagination; especially as that's easier to do than doing complex (and inefficient) calculations about the page the answer is likely to be on.
To reduce confusion, we have now added a notice above the answer when it is shown out of order, like this:
0 comment threads