Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Threads with unread posts sometimes open the wrong page (site bug) #642

Open
baka-kaba opened this issue Nov 3, 2018 · 2 comments
Open

Comments

@baka-kaba
Copy link
Contributor

Some threads have magical missing posts, which affects the replies count that we scrape to calculate the postcount for a thread (replies + 1 for the first post). When you've read a full page, clicking the thread should take you to the next unread post, i.e. the first one on the next page.

But because the postcount is 1 lower than it should be, the index of the next unread post is 1 lower too - so it's actually calculated as the last post on the page you already read. So it will always load that page, until you manually turn the page and view more posts (and if you view another full page, the problem will appear again)


I'm mostly adding this for information, in case anyone else runs into it like I did. Right now there's no other info we can scrape, so we have to rely on the (potentially incorrect) reply numbers.

I guess it would be possible to calculate a postcount from the actual thread view, when you're looking at the last page ((previousPages * postsPerPage) + postsOnThisPage) - which we already do - and compare that to the count on the thread list, updating a correction offset column in the thread database. But that's pretty complicated, especially ensuring no new posts arrived between loading one page and the other

@Sereri
Copy link
Member

Sereri commented Nov 3, 2018

The cause of this in most cases is Zen Death Robot's posts getting deleted by the post fairy

@baka-kaba
Copy link
Contributor Author

Yeah but I just saw it happening in the very new Trump thread, hasn't ZDR been missing a while?

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

No branches or pull requests

2 participants