[00:41:54] How can I have a named parameter into a template which can be specified multiple times? [00:41:56] https://www.mediawiki.org/wiki/Help:Templates#Named_parameters [00:47:34] you can't [00:47:43] What do you mean multiple times? [00:47:43] Only the last definition is used regardless how many times you specify it [00:55:09] the usual way around that is to add a numerical suffix to the parameter names, e.g. row1, row2, ..., rowN [01:05:12] Or Extension:Variables/Arrays [01:32:55] After updating to 1.38.x the sidebar disappears, how can I debug that? [01:33:35] What do you mean by disappears? [01:33:44] (this feels dejavu/we've had a few "reports" like this) [01:34:45] I get the default sidebar, but the one I've setup is gone. [01:35:30] !sidebar [01:35:30] To edit the navigation menu on the left, edit page [[MediaWiki:Sidebar]] on your wiki using its special syntax (see https://www.mediawiki.org/wiki/Manual:Interface/Sidebar for details). If you need more control, you can use the SkinBuildSidebar hook (https://www.mediawiki.org/wiki/Manual:Hooks/SkinBuildSidebar). [01:35:42] What do you see if you visit MediaWiki:Sidebar [01:36:12] The sidebar menu I've set up of course. [01:38:23] I'd like to see some log output, some error message that gives me a hint on what's going wrong. [01:39:57] There's caches around it [01:40:08] A null edit may be enough to unstick it [01:40:19] Yes, I cleared the caches ?purge [01:40:45] I also tried editing it. [01:40:57] Have you updated your skin as well as MW too? [01:41:02] I tried bisecting it. [01:41:17] I tried various skins [01:41:31] I just use default skins [01:42:40] Consider everything you can find in the mediawiki help forums concerning the sidebar done. [01:43:00] I'd like to see some log output, some error message that gives me a hint on what's going wrong. [01:43:15] There's not guaranteed to be log output that can/will help [01:43:20] !debug [01:43:20] For information on debugging (including viewing errors), see https://mediawiki.org/wiki/Manual:How_to_debug . A list of related configuration variables is at https://mediawiki.org/wiki/Manual:Configuration_settings#Debug.2Flogging Also see https://mediawiki.org/wiki/Manual:Errors_and_symptoms [01:51:03] Ah... wguser is deprecated, and there is a hack in the config which uses that variable, hiding the sidebar for not logged in users. [01:51:39] And that code is no longer necessary. [01:55:37] There's this extension that does that: https://www.mediawiki.org/wiki/Extension:HideSidebar [02:21:01] Reedy, thanks for help. It's working now. [15:20:07] Is it possible to get specific details about a users edits in a specified time for an extension? Eg, the amount of edits in X space of time? [15:20:49] You can do almost whatever you want in an extension.. including your own SQL queries [17:51:52] Hi, when I try to use this type of internal link, nothing displays when I save the page: [[Help:Editing pages|editing help]] Thanks for help! [17:52:29] I am using a category I created: [[Category:Authors|Authors]] [17:58:03] The skin I am using is timeless, if that may cause an effect? Thanks again! [18:04:00] Is your wiki public? [18:04:30] yes [18:04:44] https://archaix.wiki/index.php/Main_Page [18:04:51] thanks! [18:10:08] jojo: Are you trying to link to the category. In that case you need to do [[:Category:Authors|Authors]] [18:10:37] As [[Category:Authors|Authors]] puts the page into the Authors category, filed under Authors (instead of its normal page name) [18:10:47] Its one of the more confusing parts of wikitext [18:12:36] bawolff, that did it! thanks so much for clarifying that! much appreciated! :D [18:12:56] Same thing applies when linking to files [18:14:58] roger that too! [18:15:28] cheers for this help to all! ;D [21:54:45] Hello everyone, I have been using mediawiki for years but is new to the IRC, sorry if I am asking for help in wrong channel. I have been trying to get OAuth work for REST API, but neither 1.0 or 2.0 works for me. I was able to create the "4 strings" if I choose oauth 1.0, but when I try that in Postman, it says "You need read permission to use this [21:54:45] module."; for oauth 2.0, i could not successfully create one, it gives this error: "Fatal error: Method MediaWiki\Extensions\OAuth\Entity\AccessTokenEntity::__toString() must not throw an exception, caught ParseError: syntax error, unexpected 'Parser' (T_STRING), expecting function (T_FUNCTION) or const (T_CONST) in [21:54:46] /home/servidz8/public_html/mpwiki/extensions/OAuth/src/Frontend/SpecialPages/SpecialMWOAuthConsumerRegistration.php on line 0". Can someone help to take a look or point me to the right place for a fix? BTW my wiki is on 1.35.0 [21:55:55] Sounds like you've got PHP code that only works on a newer PHP version than you're running... [21:56:10] read permission probably means you are using it with the wrong grant (OAuth 1) / scope (OAuth 2) [21:57:02] Did you download the correct version of OAuth for MW 1.35? [21:57:35] (also, you should really upgrade from 1.35.0 to 1.35.9 to fix various known security issues) [21:58:03] Reedy yes I downloaded from here https://www.mediawiki.org/wiki/Extension:OAuth, and confirmed I choosed the 1.35 version [21:59:14] Reedy yup that is one reason I considering upgrade too, and actually I did it on my test instance, however that runs into another problem... after the upgrade, when I try to create a new page, I got this error: "[Y9boxYsooUjazkr_JdzM6AAAAFI] /index.php?title=User:Ywsz&action=edit Wikimedia\Rdbms\DBQueryError: A database query error has occurred. [21:59:14] Did you forget to run your application's database schema updater after upgrading or after adding a new extension?" [21:59:25] !debug [21:59:26] For information on debugging (including viewing errors), see https://mediawiki.org/wiki/Manual:How_to_debug . A list of related configuration variables is at https://mediawiki.org/wiki/Manual:Configuration_settings#Debug.2Flogging Also see https://mediawiki.org/wiki/Manual:Errors_and_symptoms [21:59:32] Can't tell you what it means without more info :P [22:00:12] what does `php -l /home/servidz8/public_html/mpwiki/extensions/OAuth/src/Frontend/SpecialPages/SpecialMWOAuthConsumerRegistration.php` say from a shell? [22:00:14] I did turned on debug , this is the full error: [22:00:16] [Y9boxYsooUjazkr_JdzM6AAAAFI] /index.php?title=User:Ywsz&action=edit Wikimedia\Rdbms\DBQueryError: A database query error has occurred. Did you forget to run your application's database schema updater after upgrading or after adding a new extension? [22:00:16] Please see https://www.mediawiki.org/wiki/Special:MyLanguage/Manual:Upgrading and https://www.mediawiki.org/wiki/Special:MyLanguage/Manual:How_to_debug for more information. [22:00:16] Error 1146: Table 'servidz8_mw2.mwmp_linktarget' doesn't exist [22:00:17] Function: MediaWiki\Linker\LinkTargetStore::getLinkTargetIdFromCache [22:00:17] Query: SELECT lt_id,lt_namespace,lt_title FROM `mwmp_linktarget` WHERE lt_namespace = 2 AND lt_title = 'Ywsz' LIMIT 1 [22:00:18] Backtrace: [22:00:18] from /home/servidz8/public_html/middlepathwiki/includes/libs/rdbms/database/Database.php(1618) [22:00:19] #0 /home/servidz8/public_html/middlepathwiki/includes/libs/rdbms/database/Database.php(1602): Wikimedia\Rdbms\Database->getQueryException(string, integer, string, string) [22:00:19] #1 /home/servidz8/public_html/middlepathwiki/includes/libs/rdbms/database/Database.php(1576): Wikimedia\Rdbms\Database->getQueryExceptionAndLog(string, integer, string, string) [22:00:20] #2 /home/servidz8/public_html/middlepathwiki/includes/libs/rdbms/database/Database.php(952): Wikimedia\Rdbms\Database->reportQueryError(string, integer, string, string, boolean) [22:00:20] #3 /home/servidz8/public_html/middlepathwiki/includes/libs/rdbms/database/Database.php(1708): Wikimedia\Rdbms\Database->query(string, string, integer) [22:00:21] #4 /home/servidz8/public_html/middlepathwiki/includes/libs/rdbms/database/Database.php(1717): Wikimedia\Rdbms\Database->select(string, array, array, string, array, array) [22:00:22] #5 /home/servidz8/public_html/middlepathwiki/includes/libs/rdbms/database/DBConnRef.php(103): Wikimedia\Rdbms\Database->selectRow(string, array, array, string) [22:00:22] #6 /home/servidz8/public_html/middlepathwiki/includes/libs/rdbms/database/DBConnRef.php(343): Wikimedia\Rdbms\DBConnRef->__call(string, array) [22:00:22] #7 /home/servidz8/public_html/middlepathwiki/includes/linker/LinkTargetStore.php(258): Wikimedia\Rdbms\DBConnRef->selectRow(string, array, array, string) [22:00:23] #8 /home/servidz8/public_html/middlepathwiki/includes/libs/objectcache/wancache/WANObjectCache.php(1689): MediaWiki\Linker\LinkTargetStore->MediaWiki\Linker\{closure}(boolean, integer, array, NULL, array) [22:00:24] #9 /home/servidz8/public_html/middlepathwiki/includes/libs/objectcache/wancache/WANObjectCache.php(1522): WANObjectCache->fetchOrRegenerate(string, integer, Closure, array, array) [22:00:24] #10 /home/servidz8/public_html/middlepathwiki/includes/linker/LinkTargetStore.php(273): WANObjectCache->getWithSetCallback(string, integer, Closure) [22:00:24] #11 /home/servidz8/public_html/middlepathwiki/includes/libs/objectcache/BagOStuff.php(216): MediaWiki\Linker\LinkTargetStore->MediaWiki\Linker\{closure}(integer) [22:00:29] !pastebin [22:00:29] To avoid overflowing the channel with inane amounts of text, use https://dpaste.org or https://phabricator.wikimedia.org/paste/edit/form/14/ or other awesome pastebin sites to share code, errors, and other large texts. [22:01:14] sorry, here is the pastebin link for above erros: https://dpaste.org/fH7s9#L7 [22:01:39] linktarget was added in 1.38... [22:01:44] Did you run update.php as it suggested? [22:01:57] yes I did [22:03:57] Did it complete without any error? [22:04:58] Cause I'm not sure I quite believe it was run and ran successfully and then fails like that.. [22:06:34] just tried php -l and it said No syntax errors detected [22:09:32] Reedy this is the screen I got after run update.php: https://pasteboard.co/0YO1x8bbYqVk.png [22:10:00] not sure if that is normal.. [22:10:45] Yeah, that didn't run succesffully then [22:11:19] I filed https://phabricator.wikimedia.org/T324226 about that [22:11:21] ok what is the problem? it did not say anything [22:11:35] It should be telling you your version of mysql is too old [22:12:39] You need at least 5.7.0 (of mysql) [22:12:50] I see [22:13:06] if OAuth dies with a parse error, chances are the update script dies with that too? [22:13:06] https://www.mediawiki.org/wiki/Compatibility#Database [22:13:25] you should probably check your error reporting settings [22:13:34] https://www.mediawiki.org/wiki/Manual:How_to_debug [22:15:31] ok I just checked it is 5.6.51 [22:15:53] tgr_ thank you! [22:18:33] this answers the issue about the upgrade. Thank you! How about the oauth 1.0 issue on 1.35? any thoughts? [22:19:48] The "on line 0" does make it look odd [22:27:01] I think that's normal for parsing errrors. [22:27:25] Either you are using the wrong PHP version / wrong extension version, or the file is messed up somehow. [22:28:07] I guess my suggestion to use php -l doesn't necessarily mean the same version was run on the CLI as is run via the webserver [22:28:12] that error is from oauth 2.0, any thoughts on oauth 1.0 issue? here is the return I got in postman: [22:29:39] https://postimg.cc/bs89s0D3 [22:31:10] I was able to created the consumer registration successfully using 1.0, but it is denying Postman to connect [22:31:39] [21:56:10] read permission probably means you are using it with the wrong grant (OAuth 1) / scope (OAuth 2) [22:36:47] The "basic access" grant gives read permission, "identification only" doesn't. [22:40:49] Yes I choosed "Basic access" [22:41:20] "Basic rights" I mean [22:41:49] I also created another registration with all checkbox checked, still not working [22:42:53] see image: https://pasteboard.co/hk4srbv5Y1LN.png [22:43:34] Then either the user doesn't actually have read permission (OAuth cannot give rights the user doesn't already have), or the wiki didn't see the request as OAuth-authenticated at all. [22:45:30] (For OAuth 1, you need an Authorization: header starting with 'OAuth') [22:45:36] I also checked the checkbox that says "This consumer is for use only by ", so I assume that means the consumer will get my adimn permissions [22:47:27] Yes it starts with OAuth, see screenshot: https://pasteboard.co/T64u6EnKgtpu.png [22:47:29] It does not. But basic should be enough to avoid the readapidenied error. [22:49:38] Yeah, those look correct. Not sure why it's not working - check the 'OAuth' and 'session' log channels, maybe they have something useful. [22:51:41] ok, thank you, how to get to the OAuth channel? sorry first time using iRC... [22:52:55] It's a log stream within MediaWiki. See https://www.mediawiki.org/wiki/Manual:How_to_debug#Logging and https://www.mediawiki.org/wiki/Manual:Structured_logging [22:53:13] Sadly the default logging configuration is kinda useless. [22:54:49] oh okie, sorry i thought it is a diffenent IRC channel