GithubHelp home page GithubHelp logo

old-reddit-pfps's Introduction

Hi!

I'm Taniko Yamamoto.   She/They

I do mainly web development related things on this account, but I might do other things too.

Mainly, I crave to satisfy my autistic obsession with the internals of YouTube, so that's primarily what you'll see me do. I am a lead developer of the Rehike project, which implements a custom YouTube server that accurately and perfectly emulates the pre-2017 layout. That said, I'm not very secretive and if have any curiosities about the internals of YouTube yourself, please do not hesitate to contact me.

Check out things I'm involved with!

Rehike
Phroton
Old Reddit PFPs

Contacts

Email: [email protected]
Twitter: @kirasicecreamm

old-reddit-pfps's People

Contributors

ephemeralviolette avatar yukiscoffee avatar

Stargazers

 avatar  avatar

Watchers

 avatar

old-reddit-pfps's Issues

Suspended accounts display browser missing image

This is a general bug in the implementation; not client-specific.

The script is smart and avoids injecting profile pictures where users are ordinarily inaccessible (deleted accounts), however this approach does not work for suspended accounts. Suspended accounts still show up in the comments as usual, without any traits in the comment itself indicating that the user is suspended.

The browser missing image is avoided in the script for the sake of elegance; a pixel GIF is hardcoded to be displayed before the profile picture loads in order to only display the background colour of the profile picture container. However, it still shows up in the case of attempting to access a suspended user's profile picture.

The API requested by the script does return suspension status in the boolean data.is_suspended, so all that's needed is implementation. Additionally, in the case of a suspended user, the icon_img property that this script attempts to access is completely missing.

Example

Unstable loading and possible dependency on Reddit Enhancement Suite

Specs on my end:

  • Windows 10 20H2 (19042.685) amd64
  • Mozilla Firefox 91.8.0esr (64-bit)
  • Tampermonkey
  • RES (will clarify later)

The script sporadically fails to load every so often. At the moment, I'm not sure to what this behaviour can be attributed. I have similar issues with other Tampermonkey scripts without any dependencies, so it could be an issue with Tampermonkey itself, or it could be an issue with this script having dependencies.

An unstated dependency of this script seems to be RES, though it seems unintentional for that to be the case. If I disable RES on my setup, the script fails to load at all. With it enabled, it loads 99/100 times and otherwise fails to inject.

I speculate that the failed loads may not be a fault of Tampermonkey, however, and may be a fault of late RES injection. I said just that in my unofficial 3.0 pull request. However, after further debugging between that pull request and submitting this issue, I figured out that's probably not the case:

  • Uninjecting RES from a page that already has RES loaded and profile pictures injected maintains the profile pictures. This may not be a good candidate for any research, since it keeps all HTML injected by RES and only removes the CSS.
  • Injecting RES into a page that doesn't have RES loaded and lacks profile pictures loads both RES and profile pictures. This occurs even after the page is finished loading.

So while the loading of the script seems to be dependent on RES, it doesn't seem to matter the time at which RES is injected, as the script seems to pretty much always immediately follow RES injection.

That's why I bring up that second hypothesis: that it may be Tampermonkey itself causing the failed injections even when RES succeeds. I lack any documentation of this occurring, but I can say for one that Tampermonkey does cause similar issues on similar scripts I have installed (that run at document-start, notably; I cannot say if this behaviour occurs with scripts that have different load timings).

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.