Skip to content
This repository has been archived by the owner on Feb 7, 2024. It is now read-only.

sort_type="score" does not sort in either asc or desc #85

Open
mattpodolak opened this issue Oct 29, 2020 · 1 comment
Open

sort_type="score" does not sort in either asc or desc #85

mattpodolak opened this issue Oct 29, 2020 · 1 comment

Comments

@mattpodolak
Copy link

    posts = list(api.search_submissions(subreddit='hololive',
                                        before=before_date,
                                        after=after_date,
                                        filter = ['id', 'title', 'score'],
                                        sort_type ='score',
                                        limit=limit_per_period,
                                        is_video="false",
                                       ))

This should return the submissions sorted in desc order by score, instead it returns this:

created_utc: score
1603844036.0: 0
1603853459.0: 203
1603849689.0: 56
1603859316.0: 1
1603929485.0: 10304
1603860597.0: 2980
1603883911.0: 3898
1603870918.0: 36
1603844442.0: 43
1603870916.0: 6873
1603895132.0: 55
1603896392.0: 116
1603883919.0: 460
1603898269.0: 1507
1603857688.0: 1
1603870928.0: 30
1603907662.0: 666
1603864680.0: 137
1603896724.0: 126
1603889305.0: 33

As you can see this is now not sorted by either created_utc or score but instead seems to be in a random order

@mattpodolak
Copy link
Author

Could be an issue with pushshift:
https://api.pushshift.io/reddit/search/submission/?subreddit=hololive&limit=10&fields=title,score&sort_by=score

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant