Lucas_Werkmeister_WMDE added a subscriber: hashar.
Lucas_Werkmeister_WMDE added a comment.


  Hm, the production SAL suggests that @hashar upgraded Jenkins:
  
  > 13:12 <https://sal.toolforge.org/log/2A1UPXYBgTbpqNOmxCt9>  <hashar>        
Upgrading Jenkins 2.252 > 2.263.1 on contint2001 / contint1001  [production]
  
  Is it at all possible that this caused the error? That seems unlikely, but 
it’s the only possibility I have so far.
  
  ---
  
  At the PHP level, the main error seems to be:
  
  > FlaggablePageView has no context article!
  
  This happens in `FlaggablePageView::load()`:
  
        private function load() {
                if ( !$this->loaded ) {
                        $this->loaded = true;
                        $this->article = self::globalArticleInstance();
                        if ( $this->article == null ) {
                                throw new Exception( 'FlaggablePageView has no 
context article!' );
                        }
                        $this->out = $this->getOutput(); // convenience
                }
        }
  
  Where `self::globalArticleInstance()` looks like this:
  
        public static function globalArticleInstance() {
                $title = RequestContext::getMain()->getTitle();
                if ( $title ) {
                        return FlaggableWikiPage::getTitleInstance( $title );
                }
                return null;
        }
  
  And `RequestContext::getMain()->getTitle()` tries to get the title from the 
global variable:
  
        public function getTitle() {
                if ( $this->title === null ) {
                        global $wgTitle; # fallback to $wg till we can improve 
this
                        $this->title = $wgTitle;
                        $logger = LoggerFactory::getInstance( 'GlobalTitleFail' 
);
                        $logger->info(
                                __METHOD__ . ' called with no title set.',
                                [ 'exception' => new Exception ]
                        );
                }
    
                return $this->title;
        }
  
  but in the debugger I can see that `$wgTitle` is null when the test runs.

TASK DETAIL
  https://phabricator.wikimedia.org/T269608

EMAIL PREFERENCES
  https://phabricator.wikimedia.org/settings/panel/emailpreferences/

To: Lucas_Werkmeister_WMDE
Cc: hashar, Lucas_Werkmeister_WMDE, Aklapper, Akuckartz, Iflorez, alaa_wmde, 
DannyS712, Nandana, Lahi, Gq86, Pablo-WMDE, GoranSMilovanovic, QZanden, 
LawExplorer, _jensen, rosalieper, Scott_WUaS, Jonas, Wikidata-bugs, aude, 
Lydia_Pintscher, Jdforrester-WMF, Mbch331
_______________________________________________
Wikidata-bugs mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikidata-bugs

Reply via email to