Extension talk:SimpleChanges

About this board

Manually tweaking output

1
JoshuaJSlone (talkcontribs)

I see this hasn't been updated in many years, and I certainly don't trust myself to do a serious update adding new options for anyone to use, BUT if you do wish to tweak things a bit more it's not so bad to do it yourself. I wanted the output to not be in the form an HTML list, but just items on different lines, as this took up much less space when viewing the wiki on mobile. Near the bottom of the SpecialSimpleChanges.php you can easily enough see where it's opening and closing ul tags (lines 110, 143) and where for each item it's adding opening and closing li tags (lines 126, 135). For my purposes, I ditched the ul bits and replaced the li bits with a br.

Reply to "Manually tweaking output"

How to list simple changes only for a given namespace

1
Summary by Tosfos

Questioner discovered answers

Frank on MW (talkcontribs)

Q: (How) Can I list simple changes only for a given namespace?

A1: I can call the SimpleChanges and define a filter for a namespace and can include it in a wikipage.

A2: special pages allows me to add parameters like:

Special:RecentChanges/days=5,limit=40,hidebots,hideminor

... and if I want to add a namespace it would look like:

Special:SimpleChanges//days=5,limit=40,hidebots,hideminor,namespace=3000


So this seems to work - only that I had not any changes listed that meet the days and limit parameters ...


Note: I included those { { Special: ... }} when I added it to a page.

Error with Mediawiki 1.29.0

9
Summary by Reception123
Kyr (talkcontribs)

After upgrading to 1.29.0 and installing latest version of SimpleChanges REL1_29 from 2017-06-14 I received the following error:

[WXireMPqi-oAAMpyrjkAAAAQ] /xxx/pedia/index.php/Spezial:Vereinfachte_%C3%84nderungen Wikimedia\Rdbms\DBQueryError from line 1075 of /xxx/mediawiki-1.29.0/includes/libs/rdbms/database/Database.php: A database query error has occurred. Did you forget to run your application's database schema updater after upgrading?

Query: SELECT rc_id,rc_timestamp,rc_user,rc_user_text,rc_namespace,rc_title,rc_comment,rc_minor,rc_bot,rc_new,rc_cur_id,rc_this_oldid, rc_last_oldid,rc_type,rc_source,rc_patrolled,rc_ip,rc_old_len,rc_new_len,rc_deleted,rc_logid,rc_log_type,rc_log_action, rc_params,page_latest,wl_user,wl_notificationtimestamp,page_latest,(SELECT GROUP_CONCAT(ct_tag SEPARATOR ',') FROM `change_tag` WHERE ct_rc_id=rc_id ) AS `ts_tags` FROM `recentchanges` LEFT JOIN `page` ON ((rc_cur_id=page_id)) LEFT JOIN `watchlist` ON (wl_user = '3' AND (wl_title=rc_title) AND (wl_namespace=rc_namespace)) LEFT JOIN `page` ON ((rc_cur_id=page_id)) WHERE (rc_bot = 0) AND (rc_timestamp >= '20170719000000') AND (rc_type != 3) AND ((rc_namespace = 0)) AND (rc_this_oldid=page_latest) AND rc_new IN ('0','1') ORDER BY rc_timestamp DESC LIMIT 150

Function: SpecialRecentChanges::doMainQuery

Error: 1066 Not unique table/alias: 'page' (localhost)

Backtrace:

#0 /home/follow/html/interna/mediawiki-1.29.0/includes/libs/rdbms/database/Database.php(933): Wikimedia\Rdbms\Database->reportQueryError(string, integer, string, string, boolean)

#1 /home/follow/html/interna/mediawiki-1.29.0/includes/libs/rdbms/database/Database.php(1269): Wikimedia\Rdbms\Database->query(string, string)

#2 /home/follow/html/interna/mediawiki-1.29.0/includes/specials/SpecialRecentchanges.php(291): Wikimedia\Rdbms\Database->select(array, array, array, string, array, array)

#3 /home/follow/html/interna/mediawiki-1.29.0/includes/specialpage/ChangesListSpecialPage.php(545): SpecialRecentChanges->doMainQuery(array, array, array, array, array, FormOptions)

#4 /home/follow/html/interna/mediawiki-1.29.0/includes/specialpage/ChangesListSpecialPage.php(481): ChangesListSpecialPage->getRows()

#5 /home/follow/html/interna/mediawiki-1.29.0/includes/specials/SpecialRecentchanges.php(69): ChangesListSpecialPage->execute(NULL)

#6 /home/follow/html/interna/mediawiki-1.29.0/includes/specialpage/SpecialPage.php(522): SpecialRecentChanges->execute(NULL)

#7 /home/follow/html/interna/mediawiki-1.29.0/includes/specialpage/SpecialPageFactory.php(578): SpecialPage->run(NULL)

#8 /home/follow/html/interna/mediawiki-1.29.0/includes/MediaWiki.php(287): SpecialPageFactory::executePath(Title, RequestContext)

#9 /home/follow/html/interna/mediawiki-1.29.0/includes/MediaWiki.php(862): MediaWiki->performRequest()

#10 /home/follow/html/interna/mediawiki-1.29.0/includes/MediaWiki.php(523): MediaWiki->main()

#11 /home/follow/html/interna/mediawiki-1.29.0/index.php(43): MediaWiki->run()

#12 {main}

MySQL documentation says something like:

you can't refer to the PAGE table twice in the same query without giving it an alias in at least one of the joins.

Tosfos (talkcontribs)

Just confirming, did you run update.php or the web updater after upgrading?

Kyr (talkcontribs)

Sorry, for the late replay.

Yes, I run update.php. After running update.php it seems to work, but after some time the error occurs again. I'm not sure what "some time" is, maybe the next change to the database. Running update.php again fixed it till the next change.

I removed the extension for now from my wiki - it is only a "nice to have".

Coradriaan (talkcontribs)

After upgrading to 1.29 on Miraheze.org I have an error on my wikipage which has the extension in the code:

-

MediaWiki internal error.

Original exception: [e048d054ab5d083d5d8bcc37] 2017-08-14 06:10:12: Fatal exception of type "Wikimedia\Rdbms\DBQueryError"

Exception caught inside exception handler.

Set $wgShowExceptionDetails = true; and $wgShowDBErrorBacktrace = true; at the bottom of LocalSettings.php to show detailed debugging information

-

The error happens only when I am logged in. Visitors with read only rights don't see a fault. I removed the extension from the page.

Tosfos (talkcontribs)

Thank you for the bug reports. The bug has been fixed in the latest master branch of the extension.

Reception123 (talkcontribs)
Aimednovac (talkcontribs)

Hello, Or then I download the corrected version. Thank you in advance.

Tosfos (talkcontribs)

The patch on the REL1_29 branch was merged.

62.110.177.36 (talkcontribs)

hello,

I edit my .php file with two extension and I have found this error:

[a620f90a7b260d6c501e2d68] 2017-10-05 09:42:59: Fatal exception of type "Wikimedia\Rdbms\DBQueryError"

Does anyone know what it is for?

Thank you

Reply to "Error with Mediawiki 1.29.0"

$wgSimpleChangesOnlyLatest doesn't work

2
Summary by Kghbln

Upgrade to master of this extension

Miles Fides (talkcontribs)

Hey there,

I wanted to transclude the SimpleChanges-Page on my Mainpage and noticed, that the displayed Pages aren't distinct. In fact some pages showed up 5 times.

So I searched for the Variable $wgSimpleChangesOnlyLatest in the PHP-Files and wasn't able to find it anywhere...

Does this variable even exist?

If yes, why doesn't it work?...

Thanks :)

Tosfos (talkcontribs)

That variable does indeed exist, and it was introduced in version 1.0. I'm guessing that you're using an older version of the extension. Try downloading from the master branch.

Dcianf (talkcontribs)

My users requested including the comment after the title, just like the editor. Because I'm afraid of using new variable names I kept the same structure as the ShowUser block, but someone who understands scope could easily make this another global variable and also pass a maximum string length.

#global $wgSimpleChangesShowUser;

#if ( $wgSimpleChangesShowUser ) {

# from ChangesList::insertUserRelatedLinks()

$user = ' <i>' . substr($rc->mAttribs['rc_comment'] ,0,60). ' </i>';

$changeLine .= Html::rawElement( 'span', array( 'class' => 'simplechanges-comment' ), $user );

#}

The result looks like this:

  • Main Page‎ (Dcianf) Changed Recent Changes to 90 days
Reply to "Include Comment"
There are no older topics