Closed Beligertint closed 8 years ago
I wasn't even aware of a completely random search. Seems there actually aren't any pages for a random search and every request will be completely different...
If I were to patch things so that it's processed like a normal thumb listing (search, favorites, notes, etc.), it would:
The problem here is that basically the original thumbnails are lost since the API request will be a completely new set of posts. If you happened to see a post of interest in the original listing, you'd run the risk of not being able to view it since it would be replaced as soon as the API info was retrieved.
I think I will have to treat a random search as a special case and have it get processed under its own function like comments and parent/child relation notices are. The new method would:
Making it into its own special case will also prevent problems like endless pages not knowing what to do with this special search that just happens to not have any pages.
Any thoughts? Either way, I've at least made sure I won't lose my line of thought on this issue.
An example of an order random search can be seen here: https://danbooru.donmai.us/posts?utf8=%E2%9C%93&tags=rating%3Asafe++order%3Arandom&ms=1 It works partially, but settings can't open, blacklists stopped applying a few days back, and other weirdness. There's also no endless scrolling.
On Thu, Apr 21, 2016 at 1:51 PM, Moebius-Strip notifications@github.com wrote:
I wasn't even aware of a completely random search. Seems there actually aren't any pages for a random search and every request will be completely different...
If I were to patch things so that it's processed like a normal thumb listing (search, favorites, notes, etc.), it would:
- Detect if there are any missing thumbnails.
- Check if the user has chosen to display some hidden posts.
- If they have, request the API info for the page.
- Replace all thumbnails with thumbnails created from the API.
The problem here is that basically the original thumbnails are lost since the API request will be a completely new set of posts. If you happened to see a post of interest in the original listing, you'd run the risk of not being able to view it since it would be replaced as soon as the API info was retrieved.
I think I will have to treat a random search as a special case and have it get processed under its own function like comments and parent/child relation notices are. The new function would:
- Detect if there are any missing thumbnails.
- Check if the user has chosen to display some hidden posts.
- If they have, request the API info for the page.
- Try to append enough API thumbnails to the current thumbnails to make up for the hidden posts.
Making it into its own special case will also prevent problems like endless pages not knowing what to do with this special search that just happens to not have any pages.
— You are receiving this because you authored the thread. Reply to this email directly or view it on GitHub https://github.com/pseudonymous/better-better-booru/issues/63#issuecomment-213037085
Endless pages is the big reason order:random isn't working properly. The random search doesn't actually have pages to navigate through. You're just supposed to refresh or resubmit the search when you finish looking at the current batch of random posts. Endless pages only recognizes it as a regular search which usually has pages and runs into an error because of it.
Still pondering the random search, but you can get the current working version from the following: https://github.com/pseudonymous/better-better-booru/raw/the-fixening/better-better-booru.user.js
Changes can be viewed here: https://github.com/pseudonymous/better-better-booru/compare/the-fixening
Still not sure how feasible endless pages will be for order:random considering the lack of pagination and the way every request is randomized.
I can confirm BBB settings now works along with blacklists on order:random pages.
When doing an order:random search with another tag, BBB and the blacklist do not work.