News for hackers. Stuff that matters.
Re:Reddit's website uses DRM for fingerprinting by jazzyjackson on Wednesday July 08, 2020 @10:30PM (#23776419)
Can't I just judge it on the basis of being broken?

- being an SPA prevents the browser from remembering the scrollheight of a page so if I click on the margin (why does the entire margin act as a back button closing the comments?) I lose my place in comments. How hard would it be to stick a "scrollheight = localstorage[url].scrollheight || 0" in the 6 megabyte javascript bundle?

- clicking "view more comments" does keep my scrollheight since its not a page reload, but since there's like 5 comments instead of 5000, I'm suddenly at the bottom of the page and have to scroll to the top

- it loads the top level comments before the subthreads, so while I start reading the 2nd or 3rd comment, everything gets pushed down to make room for more comments -- or even better I just get a "something went wrong" for like a half second and then the replies come in. I actually see this pattern a lot - SPA thinks that everyone has a megabit connection and if content.length = 0 then something must have gone wrong !

Or how about when it says "18 more replies" and I click on it and there's only one reply? Can't javascript count?

Re:Reddit's website uses DRM for fingerprinting by overlordalex on Thursday July 09, 2020 @09:31AM (#23779937)
> Or how about when it says "18 more replies" and I click on it and there's only one reply? Can't javascript count?

This one is actually a reddit quirk. The API reports the number of comments, however doesn't take into account removed comments, or users that have been shadow-banned.

However users notice and complain about this constantly, so it still needs to be improved

Re:Reddit's website uses DRM for fingerprinting by jazzyjackson on Sunday July 12, 2020 @04:12AM (#23809760)
Actually I just noticed this on Facebook too, especially comments on ads it will say "16 comments", but even when I select from the dropdown "All Comments" instead of "Most Relevant" I can count 10 comments.

So it's querying an API to ask how many comments there are, and getting a different result when it actually fetches the comments. So there's two different SQL queries somewhere I get that, but how can they diverge so much, is there a team assigned to "Queries that count comments before showing them" and a different team assigned to "queries that show comments" ?

It's just so frustrating as a developer to see the same broken behavior all over the largest web properties.