{"action":"created","issue":{"url":"https://api.github.com/repos/mceachen/closure_tree/issues/160","labels_url":"https://api.github.com/repos/mceachen/closure_tree/issues/160/labels{/name}","comments_url":"https://api.github.com/repos/mceachen/closure_tree/issues/160/comments","events_url":"https://api.github.com/repos/mceachen/closure_tree/issues/160/events","html_url":"https://github.com/mceachen/closure_tree/issues/160","id":86430505,"number":160,"title":"Ordering by an integer column that is not exclusively used for sorting is being filled with random numbers","user":{"login":"davidkpham","id":398149,"avatar_url":"https://avatars.githubusercontent.com/u/398149?v=3","gravatar_id":"","url":"https://api.github.com/users/davidkpham","html_url":"https://github.com/davidkpham","followers_url":"https://api.github.com/users/davidkpham/followers","following_url":"https://api.github.com/users/davidkpham/following{/other_user}","gists_url":"https://api.github.com/users/davidkpham/gists{/gist_id}","starred_url":"https://api.github.com/users/davidkpham/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/davidkpham/subscriptions","organizations_url":"https://api.github.com/users/davidkpham/orgs","repos_url":"https://api.github.com/users/davidkpham/repos","events_url":"https://api.github.com/users/davidkpham/events{/privacy}","received_events_url":"https://api.github.com/users/davidkpham/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-06-09T03:41:33Z","updated_at":"2015-06-09T04:28:53Z","closed_at":null,"body":"To give an example, I have a Comment model with a score attribute (integer) that is essentially the number of votes that Comment has received. I'm doing something like this:\r\n\r\n````\r\nclass Comment\r\n    has_closure_tree order: 'score ASC'\r\nend\r\n````\r\n\r\nNow whenever I create a new comment, the score attribute is set to a seemingly random number (doesn't correlate with number of Comments in the DB, which I thought it might be doing). Not only that, but all the other Comments also have their score attribute set to a unique and seemingly random number.\r\n\r\nI haven't had a chance to dig into this - but does anyone have an idea of what might be going on?"},"comment":{"url":"https://api.github.com/repos/mceachen/closure_tree/issues/comments/110220901","html_url":"https://github.com/mceachen/closure_tree/issues/160#issuecomment-110220901","issue_url":"https://api.github.com/repos/mceachen/closure_tree/issues/160","id":110220901,"user":{"login":"mceachen","id":216377,"avatar_url":"https://avatars.githubusercontent.com/u/216377?v=3","gravatar_id":"","url":"https://api.github.com/users/mceachen","html_url":"https://github.com/mceachen","followers_url":"https://api.github.com/users/mceachen/followers","following_url":"https://api.github.com/users/mceachen/following{/other_user}","gists_url":"https://api.github.com/users/mceachen/gists{/gist_id}","starred_url":"https://api.github.com/users/mceachen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mceachen/subscriptions","organizations_url":"https://api.github.com/users/mceachen/orgs","repos_url":"https://api.github.com/users/mceachen/repos","events_url":"https://api.github.com/users/mceachen/events{/privacy}","received_events_url":"https://api.github.com/users/mceachen/received_events","type":"User","site_admin":false},"created_at":"2015-06-09T04:28:53Z","updated_at":"2015-06-09T04:28:53Z","body":"I don't believe using deterministic ordering with a modifier is something people have done before."}}