Last modified: 2014-05-06 23:30:56 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 T64250, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 62250 - CodeEditor activates in the absence of toggle cookie but does not recreate this cookie / critical problems with other editors such as wikEd
CodeEditor activates in the absence of toggle cookie but does not recreate th...
Status: RESOLVED FIXED
Product: MediaWiki extensions
Classification: Unclassified
CodeEditor (Other open bugs)
unspecified
All All
: Normal major (vote)
: ---
Assigned To: Derk-Jan Hartman
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2014-03-05 10:05 UTC by Cacycle
Modified: 2014-05-06 23:30 UTC (History)
3 users (show)

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


Attachments

Description Cacycle 2014-03-05 10:05:10 UTC
CodeEditor's cookie toggle mechanism is not implemented correctly and causes massive problems with other editors (such as missing edit areas with wikEd).

CodeEditor sets a cookie to signal that it is active on an edit page (wikiEditor-0-codeEditor-enabled = 1). This cookie is also used to toggle the editor's activation state.

Problem: CodeEditor is active by default, even if the the cookie is absent. However, CodeEditor does not recreate the missing cookie. CodeEditor is then active without the cookie and without an easy mechanism for other editors to detect its active presence. For wikEd, this leads to edit pages without any editing area (see https://en.wikipedia.org/wiki/User_talk:Cacycle/wikEd#WikEd_conflicts_with_code_editor).

Solution: Either CodeEditor has to recreate the cookie when it activates itself in the absence of the cookie or CodeEditor should stay inactive in the absence of the cookie.
Comment 2 Derk-Jan Hartman 2014-03-25 22:26:30 UTC
@Cacycle, do you prefer using a cookie for this ? I was considering adding a mw.hook event instead.. (and i actually have a patch that changes the cookie name, so it's good to know that you rely on that thing right now)
Comment 3 Cacycle 2014-03-25 22:31:58 UTC
Anything that wikEd can read when the script runs and installs itself would be fine. wikEd runs very late during the page loading process, possibly as the last script on the page. Therefore, a hook might not be the best solution for that.
Comment 4 Gerrit Notification Bot 2014-04-28 13:37:31 UTC
Change 130068 had a related patch set uploaded by TheDJ:
Persistent disabling of CodeEditor

https://gerrit.wikimedia.org/r/130068
Comment 5 Gerrit Notification Bot 2014-05-06 17:39:38 UTC
Change 130068 merged by jenkins-bot:
Persistent disabling of CodeEditor

https://gerrit.wikimedia.org/r/130068
Comment 6 Derk-Jan Hartman 2014-05-06 23:30:56 UTC
Next version has this persisted as a useroption, using:

mw.user.options.get( 'usebetatoolbar' ) + mw.user.options.get( 'usecodeeditor' )

usecodeeditor also defaults to enabled (0 and 1 are used as values). To be deployed in the next 1,5 weeks.

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


Navigation
Links