Last modified: 2011-10-15 22:03:23 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T33445, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 31445 - Section edit links do not show
Section edit links do not show
Status: RESOLVED FIXED
Product: MediaWiki
Classification: Unclassified
Page editing (Other open bugs)
1.18.x
All All
: High normal (vote)
: ---
Assigned To: Nobody - You can work on this!
: need-integration-test
Depends on:
Blocks: 29876
  Show dependency treegraph
 
Reported: 2011-10-06 23:16 UTC by Mark A. Hershberger
Modified: 2011-10-15 22:03 UTC (History)
1 user (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Mark A. Hershberger 2011-10-06 23:16:58 UTC
From [[WP:VPT]]: http://en.wikipedia.org/w/index.php?oldid=454276984#Can.27t_edit_sections_of_semiprotected_articles

I now do not see an "edit" link next to the section titles of semiprotected articles, like [[Great Famine (Ireland)]], or [[Barack Obama]], although I am logged in.

Reporter mentions skin "if it matters" but it doesn't appear to matter.  I see edit links for the page, clicking them shows me a semi-protected warning, but I don't see section edit links.
Comment 1 Sam Reed (reedy) 2011-10-06 23:26:41 UTC
(In reply to comment #0)
> From [[WP:VPT]]:
> http://en.wikipedia.org/w/index.php?oldid=454276984#Can.27t_edit_sections_of_semiprotected_articles
> 
> I now do not see an "edit" link next to the section titles of semiprotected
> articles, like [[Great Famine (Ireland)]], or [[Barack Obama]], although I am
> logged in.
> 
> Reporter mentions skin "if it matters" but it doesn't appear to matter.  I see
> edit links for the page, clicking them shows me a semi-protected warning, but I
> don't see section edit links.

They're fine for me logged in...
Comment 2 Brion Vibber 2011-10-06 23:50:18 UTC
I could definitely reproduce that when logged in a few minutes ago, on both  [[Great Famine (Ireland)]] and [[Barack Obama]].

The logic calling $parserOptions->setEditSection(false) in Article seems the same as in 1.17... possibly it's getting dropped out of the parser cache key or something.

(We really shouldn't change that in the actual rendering, and should either be always adding them and then hiding them if not needed, or never add them and add them in postprocessing. :P)


https://en.wikipedia.org/wiki/Great_Famine_%28Ireland%29

logged in, no edit links
<!-- Saved in parser cache with key enwiki:pcache:idhash:14726-0!*!0!!en!4!* and timestamp 20111006191948 -->

reload, no change -- still no edit links visible.


https://en.wikipedia.org/wiki/Barack_Obama

logged in, no edit links
<!-- Saved in parser cache with key enwiki:pcache:idhash:534366-0!*!0!!en!4!* and timestamp 20111006232807 -->

reloaded, now shows with edit links:
<!-- Saved in parser cache with key enwiki:pcache:idhash:534366-0!*!0!!en!4!* and timestamp 20111006232807 -->

pcache key hasn't changed!
Comment 3 Brion Vibber 2011-10-07 01:02:45 UTC
I'm a bit suspicious of r92703 -- this forces the editSection setting off on OutputPage's own mParserOptions on first creation. Might it be getting used sometimes for some reason?

The 'editsection' user option appears in ParserOutput's legacyOptions() -- but won't get recorded if it's not used...

Aha! r90214 removes a $this->optionUsed('editsection') which would be necessary to record the use of the setting on the ParserOptions....

... which was only added in r88988 for bug 29123, and reverted for fragmenting cache and Platonides being unable to repro the problem.


I think the proper thing to do here is actually to remove all those $parserOptions->setEditSection(false) in Article::view etc -- rather it should always turn section edit links *on*, and we should make sure they're *hidden* for people without edit permissions.
Comment 4 Platonides 2011-10-07 19:08:09 UTC
They used to be only hidden, but have been removed from the actual output for several releases, due to issues with printable version.

Note that in 1.18 they *are* added in a postprocessing step (see r81583 & related revs). That's why you're not seeing a difference in the parsercache key.
Comment 5 Brion Vibber 2011-10-07 19:13:37 UTC
What sort of "issues with printable version"?
Comment 6 Platonides 2011-10-07 19:20:00 UTC
I had to dig a bit svn blaming, which lead me to r48544, and bug 11213.
Comment 7 Brion Vibber 2011-10-07 19:40:48 UTC
Aha!

Looks like another possibility I mentioned on bug 11213 was to do the removal from client-side JavaScript... we could either do it that way or make sure it consistently uses that post-processing step to make sure it doesn't produce cache issues.

Looks like I can reproduce the cache corruption easily by forcing a purge/recache on a printable view:

http://stormcloud.local/trunk/index.php?title=SecEdit&printable=yes&action=purge

Next view to the page without printable also shows no edit sections.
Comment 8 Platonides 2011-10-07 20:50:43 UTC
Confirmed. There were several small bits not prepared to interact. Should be fixed by r99250.
Comment 9 Brion Vibber 2011-10-07 21:04:36 UTC
Reopening as that fix isn't quite right yet. :)
Comment 10 Platonides 2011-10-07 21:30:58 UTC
Solved in r99252 & r99254
Comment 11 Mark A. Hershberger 2011-10-12 20:57:34 UTC
This fix seems to have caused Bug 31647 and reports on [[WP:VPT]]: http://en.wikipedia.org/w/index.php?diff=455150792
Comment 12 Mark A. Hershberger 2011-10-15 22:03:23 UTC
tagging bugs for Marcus to look at

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links