Page MenuHomePhabricator

Review and deploy CodeEditor extension
Closed, ResolvedPublic

Description

The CodeEditor extension is currently used as a Scribunto dependency.

But according CommonSettings, the extension "core functionnality" shouldn't be enabled "it has been reviewed and approved".


Version: wmf-deployment
Severity: normal
URL: https://www.mediawiki.org/wiki/Extension:CodeEditor

Details

Reference
bz42577

Event Timeline

bzimport raised the priority of this task from to Medium.Nov 22 2014, 1:08 AM
bzimport set Reference to bz42577.
bzimport added a subscriber: Unknown Object (MLST).

Already added on [[MediaWiki:Review queue]].

  • This bug has been marked as a duplicate of bug 39654 ***

Reopening bug.

  • bug 42577 is to review the extension, and have it deployed for availability on wikis requesting it
  • bug 39654 is for universal deployment on every wiki

(In reply to comment #4)

Reopening bug.

  • bug 42577 is to review the extension, and have it deployed for availability

on wikis requesting it

  • bug 39654 is for universal deployment on every wiki

I'm sorry, I don't see the distinction you're making here. The extension is already reviewed and deployed. If it weren't, it would be live on MediaWiki.org (cf. https://www.mediawiki.org/wiki/Special:Version). We would never allow an un-reviewed extension to be deployed to a production site, surely.

I think there are a few usability bugs that need to be addressed first in the CodeEditor extension, but the step of reviewing and deploying the extension is already complete, isn't it?

(In reply to comment #0)

The CodeEditor extension is currently used as a Scribunto dependency.

But according CommonSettings, the extension "core functionnality" shouldn't be
enabled "it has been reviewed and approved".


if ( $wmgUseScribunto ) {
include( "$IP/extensions/CodeEditor/CodeEditor.php" );
// Don't enable core functionality until it has been reviewed and approved
$wgCodeEditorEnableCore = false;

include( "$IP/extensions/Scribunto/Scribunto.php" );
$wgScribuntoUseGeSHi = true;
$wgScribuntoUseCodeEditor = true;
$wgScribuntoDefaultEngine = 'luasandbox';
$wgScribuntoEngineConf['luasandbox']['cpuLimit'] = 10;

}

Hmm.

(In reply to comment #5)

(In reply to comment #4)

We would never allow an
un-reviewed extension to be deployed to a production site, surely.

You answered yourself to the question with this code:


if ( $wmgUseScribunto ) {

include( "$IP/extensions/CodeEditor/CodeEditor.php" );
// Don't enable core functionality until it has been reviewed and approved
$wgCodeEditorEnableCore = false;
[...]

}

We currently have Scribunto + the CodeEditor part used by Scribunto reviewed, not all the CodeEditor code.

$wgCodeEditorEnableCore seems to control the CodeEditor functionality only for CSS and JS pages:


class CodeEditorHooks {
static function getPageLanguage( $title ) {

		global $wgCodeEditorEnableCore;

		// Try CSS/JS
		if( $wgCodeEditorEnableCore && $title->isCssOrJsPage() ) {
			if( preg_match( '/\.js$/', $title->getText() ) )
				return 'javascript';
			if( preg_match( '/\.css$/', $title->getText() ) )
				return 'css';
		}

I still feel this bug is fundamentally a duplicate of bug 39654.

(In reply to comment #6)

We currently have Scribunto + the CodeEditor part used by Scribunto reviewed,
not all the CodeEditor code.

I don't believe this is accurate, given comment 7.

I added brion in cc, he will be able to comment on what has exactly been reviewed.

I don't know anything about review status... I originally wrote the extension so not sure if I can help with review other than feedback and fixes. :)

The CodeEditor extension has already been reviewed and deployed. The plan is for it to go out to all Wikimedia wikis on Thursday, August 29. I don't see anything that's actionable here, but feel free to revert the duplicate resolution if you feel otherwise.

  • This bug has been marked as a duplicate of bug 39653 ***