resourceloader: Bump severity of style queue violation to Warning
authorTimo Tijhof <krinklemail@gmail.com>
Tue, 2 May 2017 00:28:32 +0000 (17:28 -0700)
committerTimo Tijhof <krinklemail@gmail.com>
Tue, 2 May 2017 00:39:08 +0000 (17:39 -0700)
Previously it was only in debug logs (which are enabled in Jenkins,
MediaWiki-Vagrant, Beta, and for mwdebug hosts in wmf-production).

Turning it into a warning() will log it for regular requests as well
which is the last step before we can consider hard enforcement.

Bug: T92459
Change-Id: I87c7794c5cfe35521bf76cc42f94907001e9d24b

RELEASE-NOTES-1.29
includes/resourceloader/ResourceLoaderClientHtml.php

index 12f9b54..9a86f94 100644 (file)
@@ -335,6 +335,8 @@ changes to languages because of Phabricator reports.
   MediaWiki release tarball and in Wikimedia production by the WikiEditor
   extension in 2010. It is only shown to users if no other editor was
   installed, and leads to confusion.
+* (T92459) Loading ResourceLoader modules containing JavaScript through
+  addModuleStyles() is deprecated and will log a warning server-side.
 
 == Compatibility ==
 
index 8c792ad..b8f2fa5 100644 (file)
@@ -170,7 +170,7 @@ class ResourceLoaderClientHtml {
 
                        if ( $module->getType() !== ResourceLoaderModule::LOAD_STYLES ) {
                                $logger = $rl->getLogger();
-                               $logger->debug( 'Unexpected general module "{module}" in styles queue.', [
+                               $logger->warning( 'Unexpected general module "{module}" in styles queue.', [
                                        'module' => $name,
                                ] );
                        } else {