How to query for repositories with a stable sort order? #121560
Unanswered
bcsgh
asked this question in
API and Webhooks
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Select Topic Area
Question
Body
The web API for querying for repositories has a sort option, but all the values that I can find for it generate a non-permenent order. That is the order of the results (assuming the set doesn't change) could be different in the future due to things outside my control.
That instability can result in unexpected results. (In my case, the
data github_repositories
resource in terraform saves the result in the provided order and changes in order show up as churn.)What I'd like to find is some sort option (like "name" or "creation data") where the sort order of any two items will be the same for the entire life of the items. For my case, what the order is doesn't actually matter, I'd even be happy with something like "sorted by the DB's UUID primary key", as long as that will persist even if the backed database is replaced with something else
Beta Was this translation helpful? Give feedback.
All reactions