Last modified: 2006-07-24 22:21:53 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T8732, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 6732 - Import Does Not Work With PostgreSQL
Import Does Not Work With PostgreSQL
Status: RESOLVED FIXED
Product: MediaWiki
Classification: Unclassified
Database (Other open bugs)
1.8.x
PC Linux
: Normal major (vote)
: ---
Assigned To: Nobody - You can work on this!
:
Depends on:
Blocks: postgres
  Show dependency treegraph
 
Reported: 2006-07-18 21:44 UTC by Robert Treat
Modified: 2006-07-24 22:21 UTC (History)
1 user (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments
make errno conditional based on an actual error. (485 bytes, patch)
2006-07-18 21:47 UTC, Robert Treat
Details

Description Robert Treat 2006-07-18 21:44:32 UTC
The import feature (Special::Import) breaks on PostgreSQL with the following error:

A database error has occurred Query: SELECT page_namespace,page_title FROM
templatelinks,page WHERE (page_id=tl_from) AND tl_namespace = '0' AND tl_title =
'Async_Unlisten' Function: Object id #96 Error: 1

Backtrace:

#0 /home/rob/devel/mediawiki/phase3/includes/DatabasePostgres.php(551):
DatabasePostgres::reportQueryError()
#1 /home/rob/devel/mediawiki/phase3/includes/Database.php(1644):
DatabasePostgres->reportQueryError('', 1, 'SELECT page_na...', Object(WikiRevision))
#2 /home/rob/devel/mediawiki/phase3/includes/SpecialImport.php(502):
DatabasePostgres->deadlockLoop(Array)
#3 /home/rob/devel/mediawiki/phase3/includes/SpecialImport.php(732):
WikiImporter->importRevision(Object(WikiRevision), Object(WikiImporter))
#4 /home/rob/devel/mediawiki/phase3/includes/SpecialImport.php(732):
call_user_func_array(Array, Array)
#5 /home/rob/devel/mediawiki/phase3/includes/SpecialImport.php(418):
WikiImporter->out_revision(Resource id #97, 'revision')
#6 /home/rob/devel/mediawiki/phase3/includes/SpecialImport.php(418):
xml_parse(Resource id #97, '<mediawiki xmln...', 1)
#7 /home/rob/devel/mediawiki/phase3/includes/SpecialImport.php(76):
WikiImporter->doImport()
#8 /home/rob/devel/mediawiki/phase3/includes/SpecialPage.php(499):
wfSpecialImport(NULL, Object(SpecialPage))
#9 /home/rob/devel/mediawiki/phase3/includes/SpecialPage.php(368):
SpecialPage->execute(NULL)
#10 /home/rob/devel/mediawiki/phase3/includes/Wiki.php(156):
SpecialPage::executePath(Object(Title))
#11 /home/rob/devel/mediawiki/phase3/includes/Wiki.php(47):
MediaWiki->initializeSpecialCases(Object(Title), Object(OutputPage),
Object(WebRequest))
#12 /home/rob/devel/mediawiki/phase3/index.php(47):
MediaWiki->initialize(Object(Title), Object(OutputPage), Object(User),
Object(WebRequest))
#13 {main}

The problem is that the implementation of lastErrno is hardcoded to always
return 1, which is interpreted as an error even if no error has occured.
Comment 1 Robert Treat 2006-07-18 21:47:11 UTC
Created attachment 2124 [details]
make errno conditional based on an actual error.

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links