Content deleted Content added
BrokenSegue (talk | contribs) →Design: Reply |
→Design: Reply |
||
Line 26:
:::::::ok now there are subCountNice and dateNice methods both of which format the outputs nicely and add the page to that category. you can see it in action at [[https://en.wikipedia.org/w/index.php?title=Wikipedia:Sandbox&action=edit&oldid=1142405856]]. [[User:BrokenSegue|''B''roken]][[User talk:BrokenSegue|''S''egue]] 05:56, 2 March 2023 (UTC)
::::::{{re|Sdkb}} Do you need anything from me to move this forward? [[User:BrokenSegue|''B''roken]][[User talk:BrokenSegue|''S''egue]] 00:29, 18 March 2023 (UTC)
:::::::@[[User:BrokenSegue|BrokenSegue]], sorry for the delay in following up. I just [https://en.wikipedia.org/wiki/Special:ComparePages?page1=Template%3AInfobox+YouTube+personality&rev1=1144113303&page2=Template%3AInfobox+YouTube+personality%2Fsandbox&rev2=1145354810&action=&unhide=&diffmode=source built out the functionality] in the template sandbox. It was...unfortunately more difficult than anticipated. My initial approach was to invoke the module only if it is error-free, just to be on the safe side, and to otherwise default to the old {{para|subscribers}} parameter.
:::::::This worked fine, but when I went to check on some examples from channels I follow, I realized that they quite often had data roughly two years out of date. I don't think this reflects the bot being broken, but rather that the conditions I proposed at [[wikidata:Wikidata:Requests for comment/Frequency of YouTube follower count data|the updating RfC]] had a loophole: If a channel with a WP page isn't growing much, as it seems many aren't these days, it won't be updated until it hits the next 10% threshold, even if that takes years, and even though channels without a WP page are updated yearly. I don't think the editors at e.g. [[PewDiePie]] are going to be happy to see the subscriber count from July 2021 used, even though it's similar to the current one (110M vs. 111M). What I should have proposed is that all items with WP pages be updated at minimum once a year if none of the other conditions are met.
:::::::To work around that, I explored having the template try to figure out whether the manually entered data is more recent than the Wikidata-derived data. Here I ran into a second snag, which is that {{t|Infobox YouTube personality}}, as a rather of a rather poor design decision made sometime in the mists of the past, actually has two different ways to specify when the subscriber count was last updated. The first, {{para|subscriber_date}}, applies only to the subscriber count, whereas the second, {{para|stats_update}}, applies to both the subscriber count and to {{para|views}}, the channel's total view count. (The [[:Category:GA-Class YouTube articles|highest-quality/most popular pages on YouTubers]] seem to prefer {{para|stats_update}}.) Trying to parse between three different values to figure out which is valid/most recent and get the template to behave accordingly tied my brain in knots and resulted in a code monstrosity that had at least a few bugs, so I eventually gave up.
:::::::It also made me realize that total views is something we should probably be pulling from Wikidata as well. Except...there's not a property for it currently. The closest one is {{wpl|P5436}}, which is different (because it would only count a given viewer once, whereas "views" counts all the video views of a given viewer). So that would need to be created first.
:::::::Despite all these snags, I don't want to give up after we've come this far. My impulse is to plunge ahead with the current implementation. This would also allow us to use the tracking category to see how many articles <em>would</em> have errors if we hadn't checked for those, to get a sense of the scale of that problem. If there are complaints, we'll roll back the implementation. Slightly longer-term, we can work toward improving the updating algorithm and fetching the total view count. Once those things are in place and we've minimized the errors, we'll be able to deprecate all the existing parameters around stats updating, which would make the infobox's code a lot simpler.
:::::::How does that sound? Sorry for the super long reply haha. And please lmk if any of the above is confusing. Cheers, <span style="color:#AAA"><small>{{u|</small><span style="border-radius:9em;padding:0 5px;background:#088">[[User:Sdkb|<span style="color:#FFF">'''Sdkb'''</span>]]</span><small>}}</small></span> <sup>[[User talk:Sdkb|'''talk''']]</sup> 19:33, 18 March 2023 (UTC)
|