[00:03:54] is the wiki public? If others can see the code, they might be able to suggest up to date or better ways to archive the code [00:05:44] Yes it's public, we're in the process of transitioning between hosts and upgrading so it's not 100% yet but you can see it at http://camera-wiki.org [00:06:36] I found some docs here that seem to solve the addOnloadHook - updated to jQuery usage https://www.mediawiki.org/wiki/ResourceLoader/Migration_guide_(users) [00:10:26] MediaWiki:Monobook.js and Vector.js look like duplicates that could just both be moved to Common.js [00:10:56] thanks, I'll add that to my ToDo list [00:11:46] I'm getting a new one "wgPageName is deprecated. Use mw.config" - need to find the docs on mw.config [00:13:16] mw.config.get( 'wgPageName' ) should do it [00:17:23] thanks, that seems to have fixed it [00:26:08] ha, here's another one: "mwCustomEditButtons is not defined". Looks like it's deprecated. Does mw.toolbar sound like what I should be replacing this with? [00:26:10] also that code is sorta broken, it tries to add the two mediawiki: pages i looked at [00:27:33] p858snake - which code, was that the Vector.js code? [00:41:12] mw.toolbar got removed from MediaWiki core in version 1.32 [00:55:53] ashley, so mw.toolbar is deprecated too? What should I be looking at to replace mwCustomEditButton then? [00:58:55] haha, I know, I'm just ripping out the custom edit buttons. I'll archive the old code, tell the users no special buttons for now, and look for a fix later! :P [01:05:19] https://www.mediawiki.org/wiki/ResourceLoader/Migration_guide_(users) in theory [01:18:14] steevithak: the old edit interface (usually referenced as "2006 editor" in docs) was removed entirely in 1.32 [01:18:37] so probably the custom toolbar code needs to be rewritten [01:38:50] Most popular removed feature appearently [01:43:10] bawolff: "Popular" and yet never got any patches and broke repeatedly and no-one has come forward to implement it in a repo despite my repeated offers. [01:43:59] James_F: yes. The usual definition of popular :P [01:45:12] Maybe yours. :-) [01:48:03] it's more of a question of how easy it is to figure out what happened and what the update path is, IMO [01:48:46] (relatedly, our policy is to keep deprecation messages for one release, which is almost entirely useless in the real world) [01:52:17] tgr: The "real world" of people who are misled into using the LTSes? Yeah. [01:53:31] I think deprecation notice is useful for ext devs [01:53:32] I hope in the magical future of docker image releases, we can do a better job of supporting users with faster releases and less upgrade risk. [01:54:07] bawolff: Sure, but a lot of code is bespoke per-install extension/configuration stuff, and they're lost when moving from LTS N to LTS N+1. [01:54:43] No way to have one solution for all use cases [01:54:50] Sadly. [02:21:09] I'm back with another glitch in my 1.19 to 1.31 upgrade. The HotCat Gadget isn't working after the update. Error is "Gadget "HotCat" was not loaded. Please migrate it to use ResourceLoader" [02:23:18] I tried replacing the code on MediaWiki:Gadget-HotCat.js page with latest I could find, which uses "mw.loader.load" (is that the "resourceloader" it's talking about?) but it still doesn't work [02:24:02] steevithak: upgrade to the latest version https://commons.wikimedia.org/wiki/MediaWiki:Gadget-HotCat.js https://commons.wikimedia.org/wiki/Help:Gadget-HotCat [02:24:29] steevithak: https://commons.wikimedia.org/wiki/Help:Gadget-HotCat#Installing_HotCat_on_another_wiki [02:25:40] Yeah, I found several conflicting explanations and code. The one I ended up trying is this one: https://www.mediawiki.org/wiki/ResourceLoader/Migration_guide_(users)#Keep_gadgets_central [02:26:07] But I guess that's not the right one. I'll ditch it and paste in the full pile of code from you link [02:28:42] Hmmm... still no go with the full v2.41 code in there... [02:29:19] Here's our Gadgets page with the error msg if that helps - http://camera-wiki.org/wiki/Special:Gadgets [05:36:04] anyone know the fastest way to check if a page exists via the API? [05:37:58] Hello enterprisey which page ? [05:38:25] Any page, Gopa [05:38:48] I'm looking for the fastest API endpoint that will tell me if a page exists [05:39:19] I know I can attempt to get the latest revision via prop=revisions, but I'm not sure if there's a faster way [05:41:14] I'm not sure about the fastest way enterprisey, Sorry :( [05:41:59] No problem [05:47:22] enterprisey: action=query? [05:47:58] well the fastest is probably not using the API at all [05:48:13] the second fastest is probably RESTBase [05:48:29] this is for a userscript, and I'm linking to another page [05:48:42] I'd like the link to be red when appropriate (i.e. the page doesn't exist) [05:50:20] tgr: so /page/title? [05:50:36] sending a non-authenticated HEAD request to /api/rest_v1/html/{title} would be my guess [05:50:53] uh yeah .../page/html/... [05:51:10] oh that's pretty cool [05:51:23] great idea, thanks tgr [07:08:19] Skizzerz: Nice job diagnosing the login issue! [07:11:16] If you were looking up hundreds of titles at once, you could render as HTML and check the HTML class. [17:59:53] hi guys, I think there is either bug or I can't find where to read about the change [18:01:53] my program uses the /w/api.php to get the url of the image using the form like {format: "json", action: "query", prop: "imageinfo", iiprop: "url", titles: CGI.unescape(id)} [18:04:04] also the online sandbox is weird because I add the "url" there to the "iiprop" field but I don't see it to be mentioned in Results tab: https://www.mediawiki.org/wiki/Special:ApiSandbox#action=query&format=json&prop=imageinfo&titles=File%3AAlbert%20Einstein%20Head.jpg [18:04:41] the sandbox gives me timestamp, user, but not url [18:05:34] The URL you posted doesn't include iiprop [18:05:41] https://www.mediawiki.org/wiki/Special:ApiSandbox#action=query&format=json&prop=imageinfo&titles=File%3AAlbert%20Einstein%20Head.jpg&iiprop=timestamp%7Cuser%7Curl [18:07:48] yes, it looks broken too, I've got this url by visiting the example link on this page https://www.mediawiki.org/wiki/API:Imageinfo [18:11:44] the first example link doesn't include iiprop, but the second does [18:12:06] your link seems to work in the way I want, but the real document I had an issue with was not the Albert Einstein that is just an example that I've tried after going into docs [18:13:12] I've got an issue with the https://en.wikipedia.org/wiki/File:Tyson_Lewis.jpg -- when I go to the "action=query" tab and put it there instead of Albert I get kind of empty response, tried both space and _ between the Lewis and Tyson [18:14:22] note that you need to use the api from the wiki where the image is uploaded. In this case, from the English Wikipedia and not mediawiki.org [18:14:50] https://en.wikipedia.org/wiki/Special:ApiSandbox#action=query&format=json&prop=imageinfo&titles=File%3ATyson%20Lewis.jpg&iiprop=timestamp%7Cuser%7Curl [18:15:54] wow, your links works, I'll look into how it's different from https://commons.wikimedia.org/w/api.php?format=json&action=query&prop=imageinfo&iiprop=url&titles=File%3ATyson_Lewis.jpg [18:17:23] files are usually uploaded to commons, but in that particular example, the file is not in commons, but on en.wikipedia [18:18:24] When the file is from commons, you'll see on the description page a notice about it being hosted on commons and a link to the description page there [18:18:33] that online Sandbox works weird -- I go to prop=imageinfo tab and delete two of three props, press checkbox, then "Make request" and see the "timestamp" and "user" instead of "url" that was the one field I left there [18:19:55] oh, I see, is the reverse case possible? when the file is in commons, but not in en.wiki? [18:21:13] Yes. I'm not sure if in this case en.wikipedia will give an empty result or full results pointing URL to commons [18:27:34] seems like I made it work, thank you! [18:28:23] yw [18:44:48] didn't know how else to report this: all the law firm links on https://wiki.creativecommons.org/wiki/CC_Friendly_Lawyers for Canada and the USA no longer exist; the last USA link leads to a company but that lawyer is no longer there. [18:48:35] Vulpix: FYI, here I've commited the fix for my issue I had https://github.com/Nakilon/directlink/commit/3f1accf [19:44:32] Vulpix: imageinfo does work with remote file repositories [19:45:10] IIRC there are bugs with recursive use (when the remote itself got the image from a remote) but you can't run into that on the Wikimedia cluster [19:46:35] ok. It's easy to test with an existing file, but I was lazy to do so [21:45:03] Do those wikipedia lists (by some category) happen automatically or there's a plugin or an extension for that? (Say, lists of people by nationality or lists of music pieces by tempo) [22:44:37] @LucasWerkmeister posted in Reliably embed MediaWiki page in tool - https://discourse-mediawiki.wmflabs.org/t/reliably-embed-mediawiki-page-in-tool/1111/1