• normalexit@lemmy.world
    link
    fedilink
    arrow-up
    0
    ·
    3 months ago

    From the NewPipe FAQ:

    Does NewPipe use the YouTube API?

    No. NewPipe does not rely on the YouTube API, as using it requires an API key bringing with it specific regulations and restrictions. YouTube would then have more options of tracking your YouTube usage at their disposal. Therefore, NewPipe Extractor gets the information by parsing YouTube websites.

    • shrugal@lemmy.world
      link
      fedilink
      arrow-up
      0
      ·
      edit-2
      3 months ago

      So that would mean it should be counted the same as a visit from a regular user, no? Unless YT tries to detect and filter out NP visits specifically.

      • normalexit@lemmy.world
        link
        fedilink
        arrow-up
        0
        ·
        edit-2
        3 months ago

        Using the API “correctly” is likely a requirement for the view to be counted. Their media extractor circumvents that by intentionally not using their API and instead parsing their website for content. Then it establishes a connection to the stream using an internal API.

        If you want a view to count you need to use an official client (or at least one with a legit API key). It not counting is a feature with NewPipe.

        (Google probably knows the content is being streamed, but if you could just create synthetic views with a third party project, that would be bad for YouTube stats)

        • rudyharrelson@lemmy.radio
          link
          fedilink
          arrow-up
          0
          ·
          edit-2
          3 months ago

          If you want a view to count you need to use an official client

          I would think that parsing the website would count the same as any browser-based page load, since parsing the website requires first fetching the page (probably using something like wget or curl under the hood). I dunno if non-logged-in page loads are generally counted toward the overall view count on a given video, though.

          • dan@upvote.au
            link
            fedilink
            arrow-up
            0
            ·
            3 months ago

            Page loads don’t count as a view though, because otherwise things like search engine indexing would count as a view. It’s only considered a view if the video is watched for at least 30 seconds.

            • shrugal@lemmy.world
              link
              fedilink
              arrow-up
              0
              ·
              3 months ago

              Search engines are easy to detect and filter out though, they have very distinct UA strings.

    • Dethronatus Sapiens sp.@calckey.world
      link
      fedilink
      arrow-up
      0
      ·
      3 months ago

      @kionite231@lemmy.ca @NONE_dc@lemmy.world

      As far as I know, there are two different domains in play here: YouTube dot com, and Googlevideo dot com. The first serves the main interface, as well as the API endpoints. The latter serves the stream.

      Both deal with geographical distribution (CDN) so the domain solves (via DNS) to a data center as closest as possible to the user (e.g. if I access YouTube, the domains will solve to Google data centers in Sao Paulo).

      This regionalization makes it difficult for real-time communication of video statistics, so the view count and other information is often delayed as they’re aggregated geographically and later communicated back to their main data center.

      That’s also why, for example, a video Id isn’t sequential (1,2,3,4,…), because it’d require the servers to communicate their machine states in real-time, thus leading to the same (or worse) delays from users accessing the main data center directly, which can be as farther as dozens of thousands of kilometers from the user if the said user is in, say, the middle east, because the main servers are USian and light can go as fast as circa 300.000km/s in vacuum, getting slower if light needs to go through glass, which is the case for optic cables: even though it seems fast, it’s actually slow in computing terms because information needs to arrive and go multiple times in order to carry all the network packets.

      Then, there’s another phenomenon: a video streaming can involve multiple reconnections, as the content is being streamed. This is even noticeable when there are thousands or millions of simultaneous viewers, and the user notices this as buffering delays. If each connection were to count a new view, it’d count the same viewer multiple times, so the view count is done through the main interface instead, through the main domain YouTube dot com. Even when people access the video through the app or through a smart TV, the device will request the YouTube domain which will return information regarding the stream, such as the exact URL for the said video on Googlevideo.

      Invidious, as far as I know, uses the main interface to retrieve the streaming information (web scraping, as the official API is restricted in this regard), so it’s as if some user were accessing it, so it should count as a view. The new view count isn’t instantaneous so that’s probably why you didn’t see the viewer count going up.

  • dan@upvote.au
    link
    fedilink
    arrow-up
    0
    ·
    3 months ago

    YouTube only counts a view if it’s longer than 30 seconds, but clients like Newpipe don’t send the tracking data to Google for them to track this.