jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/347896 )

Change subject: formatter: Increase log level of infobox message
......................................................................


formatter: Increase log level of infobox message

I61d20ea was only partially correct. The

  'mobile' => 'debug',

entry of $wmgMonologChannels sets the minimum log level for the udp2log
handler. Unless the minimum log level isn't DEBUG, the logstash handler
still has a minimum log level of INFO [0].

[0] 
https://github.com/wikimedia/operations-mediawiki-config/blob/master/wmf-config/logging.php#L216

Bug: T149884
Change-Id: I426409fcd39d39b5e6d1173eb8b5e0e2ebfdf70e
(cherry picked from commit f236a1d202e7e8cc0d57d1b611f4a8338234775a)
---
M includes/MobileFormatter.php
M tests/phpunit/MobileFormatterTest.php
2 files changed, 2 insertions(+), 2 deletions(-)

Approvals:
  Thcipriani: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/includes/MobileFormatter.php b/includes/MobileFormatter.php
index 0686414..7644c70 100644
--- a/includes/MobileFormatter.php
+++ b/includes/MobileFormatter.php
@@ -265,7 +265,7 @@
        private function logInfoboxesWrappedInContainers( $leadSectionBody, 
DOMXPath $xPath ) {
                $infoboxes = $xPath->query( 
'.//table[contains(@class,"infobox")]', $leadSectionBody );
                if ( $infoboxes->length > 0 ) {
-                       \MediaWiki\Logger\LoggerFactory::getInstance( 'mobile' 
)->debug(
+                       \MediaWiki\Logger\LoggerFactory::getInstance( 'mobile' 
)->info(
                                "Found infobox wrapped with container on 
{$this->title} (rev:{$this->revId})"
                        );
                }
diff --git a/tests/phpunit/MobileFormatterTest.php 
b/tests/phpunit/MobileFormatterTest.php
index 1e2973c..174ce23 100644
--- a/tests/phpunit/MobileFormatterTest.php
+++ b/tests/phpunit/MobileFormatterTest.php
@@ -838,7 +838,7 @@
 
                $loggerMock = $this->getMock( \Psr\Log\LoggerInterface::class );
                $loggerMock->expects( $this->once() )
-                       ->method( 'debug' )
+                       ->method( 'info' )
                        ->will( $this->returnCallback( function( $message ) use 
( $title ) {
                                // Debug message contains Page title
                                $this->assertContains( $title, $message );

-- 
To view, visit https://gerrit.wikimedia.org/r/347896
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I426409fcd39d39b5e6d1173eb8b5e0e2ebfdf70e
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/MobileFrontend
Gerrit-Branch: wmf/1.29.0-wmf.20
Gerrit-Owner: Thcipriani <tcipri...@wikimedia.org>
Gerrit-Reviewer: Phuedx <samsm...@wikimedia.org>
Gerrit-Reviewer: Thcipriani <tcipri...@wikimedia.org>
Gerrit-Reviewer: jenkins-bot <>

_______________________________________________
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to