Page MenuHomePhabricator

0 for the SQLite database name (as in 0.sqlite) breaks installation without warnings
Closed, ResolvedPublic

Description

Author: mediawiktor

Description:
When filling 0 for the SQLite database name and filling anything else in other fields, the installation breaks at "Creating tables..." without any warnings. "00" (two zeroes) work fine. I imagine this must depend on some PHP conditional statements, but just in case my PHP is 5.3.3 and my server is nanoweb.


Version: 1.22.0
Severity: major

Details

Reference
bz40966

Event Timeline

bzimport raised the priority of this task from to Normal.Nov 22 2014, 1:14 AM
bzimport added a project: MediaWiki-Installer.
bzimport set Reference to bz40966.
bzimport added a subscriber: Unknown Object (MLST).
bzimport created this task.Oct 11 2012, 8:19 PM

sumanah wrote:

Thanks for the bug report!

Confirming for 1.22alpha from git master. Stuck on "Install" page, displays

  • Creating tables...

From /var/log/httpd/error_log :

PHP Fatal error: Call to a member function query() on a non-object in /var/www/html/mediawiki/includes/db/DatabaseSqlite.php on line 231, referer: http://localhost/mediawiki/mw-config/index.php?page=Install

That's line

$res = $this->mConn->query( $sql );
Restricted Application added a subscriber: Aklapper. · View Herald TranscriptOct 24 2015, 2:10 AM
saper set Security to None.
saper added a subscriber: saper.

(not restricted env per se, but may need similar approach)

Restricted Application added a subscriber: TerraCodes. · View Herald TranscriptDec 31 2016, 1:34 PM
Krinkle closed this task as Resolved.Sep 29 2018, 3:14 AM
Krinkle claimed this task.
Krinkle edited projects, added MW-1.30-release-notes, Performance-Team; removed TestMe.
Krinkle moved this task from Usage problem to General library on the Wikimedia-Rdbms board.
Krinkle added a subscriber: Krinkle.

The code now uses a strlen() check, which should avoid any problems from 0 being interpreted as "nothing".

Krinkle reassigned this task from Krinkle to aaron.Sep 29 2018, 3:14 AM