[02:02:06] I know that LanguageConverter supports language variants, and there is a getPreferredVariant() method which among other things checks a user's preference value. but there doesn't seem to be anywhere in the interface that the user can *set* this preference... is that right? [02:02:39] some background here https://www.mediawiki.org/wiki/Manual:Language [02:03:34] maybe all they can do is set their language [02:10:45] you can set your preferred language variant via Special:Preferences if the language is a supported one (Serbian (sr) and Chinese (zh) being a few examples of languages that use LanguageConverter, but definitely not the only ones) [02:12:50] ashley: right but that gets stored under the 'language' keu [02:12:51] key* [02:12:55] so like sr-Cyrl or sr-Latn [02:13:12] there there is also a variant-sr preference key, which is what getPreferredVariant() looks for [02:13:15] but nothing seems to ever set it [02:14:47] hmm, fascinating! [18:21:55] hi, I have super basic developer questions: how do I set up the system so that the caches don't get in my way while developing? I have $wgMainCacheType = CACHE_NONE; set, but it still seems that some outdated code is running [18:22:05] (it's a docker setup) [18:24:39] is there something like a "standard localsettings.php for a developer"? [18:25:38] denny_wmf: there is indeed. for the most part the answer is: nothing, the default generated one will inherit all the default and is all you "need". but also yes, there is a preset for a bunch of common optional things developers tend to use: DeveloperSettings.php [18:26:28] add `require "$IP/includes/DevelopmentSettings.php";` to the top or bottom of your LS.php file. [18:26:55] thanks! I am asking because it seems to me that I go and change a PHP file, store it, refresh my page, and it seems that it doesn't run the changes I just stored, but some previous version [18:27:12] I will try that, thank you so much! [18:27:24] that might be a different issue. there is no caching by default except the browser cache [18:27:33] $wgMainCacheType = CACHE_NONE is already the stock default [18:28:17] what dev environment are you using. is "MediaWiki-Docker" from core.git/.docker, or "add.shore/mediawiki-docker-dev" or something else? [18:29:19] also - Welcome denny_wmf ! I just realised now which Denny I'm talking to :) [18:29:29] thanks for the welcome! :) [18:29:45] I am trying to remember what docker I used [18:32:30] docker-compose mediawiki [18:32:43] so I guess that's the core docker? [18:34:20] basically following whatever this README said: https://gerrit.wikimedia.org/r/plugins/gitiles/mediawiki/core/+/master/DEVELOPERS.md [18:41:49] I just reinstall the whole thing, and hope it works then again :) sorry for these basic questions, it has been a while since I did MediaWiki development [19:06:27] ah, thinks seem to work now. I feel the Zen flowing through me. thanks! [21:21:38] anyone here who knows about LanguageConverter? I'm trying to understand about user-configurable language variants. my understanding (from reading the code) is there are theoretically two user options: 'language' and 'variant'. so, theoretically, 'language' could be 'sr' (Serbian) and 'variant' could be 'sr-Cyrl' (Cyrillic Serbian) [21:22:12] however, in practice, the user language value you can set in Special:Preferences only sets 'language'. so 'language' would be set to 'sr-Cyrl' in this case, and 'variant' would not be set at all [21:22:21] see the code here for context: https://github.com/wikimedia/mediawiki/blob/master/languages/LanguageConverter.php#L316 [21:22:55] getUserVariant() looks at the 'variant' option values and uses them if they are set. but essentially nothing seems to set them, except perhaps manually setting &variant= in the url [21:23:31] can anyone provide more background on this? is there a reason the user interface doesn't seem to allow setting this variant value? [21:41:25] ningu: there is a separate preference for the variant, i can see it on https://sr.wikipedia.org/wiki/Посебно:Подешавања [21:41:48] "Варијанта језика" (language variant) [21:43:28] ningu: oh, i think i misunderstood your question [21:44:22] ningu: i believe the 'language' preference affects user interface language only, while the 'variant' preference affects the content (i.e. the wikitext of the pages) [21:44:34] does this help? i'm actually not sure what you're asking :) [21:48:46] MatmaRex: hmmmm ok [21:48:48] let me take a look [21:48:52] you understood correctly [21:54:44] ok, I think I kinda see what's happening here [21:55:01] it only shows that select control when the wiki's content language has variants [21:55:24] so, on a wiki with content language 'en' (English), it will not show it to you even if you set your user language to 'sr' [21:58:17] oh, indeed [21:58:29] ningu: this might help if you're trying to test in English: https://www.mediawiki.org/wiki/Manual:$wgUsePigLatinVariant [22:08:29] ok, I see. when it's not the content language, the variant is type "api" which doesn't show up in the form, but which presumably can still be set via api [22:23:22] ok awesome, so I can just set it via the api if I need to store it [22:23:31] this will actually work well for my purposes [22:23:43] since there's an interface where it can go [23:52:55] Well. I was a derp and bots managed to vandalize my Mediawiki. There's a ton of unrecognized junk accounts and hundreds, possibly thousands of trash pages and they're bloating my database and things like the externallinks table. [23:53:06] Is there a decent guide out there to cleaning this mess up? [23:53:50] Basically I'd love to just say 'nix every user created since X, undo every page creation/revision they did, purge all of this crap from the database'