* (bug 29342) Patrol preferences shouldn't be visible to users who don't have
patrol permissions
* (bug 29471) Exception thrown for files with invalid date in metadata
+* (bug 29492) Long-running steps in the installer (such as Upgrade and Install)
+ can sometimes timeout
=== API changes in 1.19 ===
* BREAKING CHANGE: action=watch now requires POST and token.
public function addInstallStep( $callback, $findStep = 'BEGINNING' ) {
$this->extraInstallSteps[$findStep][] = $callback;
}
+
+ /**
+ * Disable the time limit for execution.
+ * Some long-running pages (Install, Upgrade) will want to do this
+ */
+ protected function disableTimeLimit() {
+ wfSuppressWarnings();
+ set_time_limit( 0 );
+ wfRestoreWarnings();
+ }
}
$this->currentPageName = $page->getName();
$this->startPageWrapper( $pageName );
+ if( $page->isSlow() ) {
+ $this->disableTimeLimit();
+ }
+
$result = $page->execute();
$this->endPageWrapper();
$this->parent = $parent;
}
+ /**
+ * Is this a slow-running page in the installer? If so, WebInstaller will
+ * set_time_limit(0) before calling execute(). Right now this only applies
+ * to Install and Upgrade pages
+ */
+ public function isSlow() {
+ return false;
+ }
+
public function addHTML( $html ) {
$this->parent->output->addHTML( $html );
}
}
class WebInstaller_Upgrade extends WebInstallerPage {
+ public function isSlow() {
+ return true;
+ }
public function execute() {
if ( $this->getVar( '_UpgradeDone' ) ) {
}
class WebInstaller_Install extends WebInstallerPage {
+ public function isSlow() {
+ return true;
+ }
public function execute() {
if( $this->getVar( '_UpgradeDone' ) ) {