Last modified: 2014-10-17 11:31:18 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 T11911, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 9911 - Special:Import: "XML import parse failure" and wrong number of imported revisions
Special:Import: "XML import parse failure" and wrong number of imported revis...
Status: RESOLVED WORKSFORME
Product: MediaWiki
Classification: Unclassified
Export/Import (Other open bugs)
1.11.x
All All
: Low normal with 5 votes (vote)
: ---
Assigned To: Nobody - You can work on this!
aklapper-moreinfo
: testme
: 10504 (view as bug list)
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2007-05-14 16:24 UTC by Raimond Spekking
Modified: 2014-10-17 11:31 UTC (History)
3 users (show)

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


Attachments

Description Raimond Spekking 2007-05-14 16:24:35 UTC
I tried to transwiki [[en:Legion (demon)]] into de.wiki.

1st try: "No pages to import. Import failed: XML import parse failure at line
5270, col 12 (byte 546783; " "): Invalid document end"

2nd try: "No pages to import. Import failed: XML import parse failure at line
6677, col 12 (byte 694275; " "): Invalid document end"

3rd try: Success, but the log shows 27 revisions:
http://de.wikipedia.org/w/index.php?title=Spezial%3ALogbuch&type=import&user=Raymond&page=Legion+%28demon%29&uselang=en

in reality it's > 100 revisions:
http://de.wikipedia.org/w/index.php?title=Benutzer:Owly_K/Legion_%28D%C3%A4mon%29&action=history
Comment 1 Brion Vibber 2007-05-14 17:34:58 UTC
The first two failures may have been communications errors or some other kind of
problem, details uncertain.

Both would have imported some limited number successfully, but the log would not
have been updated.

The third would have imported the remaining entries which were not already
imported, and was thus correctly logged with the 27 remaining entries.
Comment 2 Raimond Spekking 2007-07-09 09:00:16 UTC
*** Bug 10504 has been marked as a duplicate of this bug. ***
Comment 3 Connel MacKenzie 2007-07-24 04:16:12 UTC
As requested on IRC, here is an import that fails the same way *every day* when my script runs:

From en.wiktionary Special:Import, importing [[w:Ignorance]] into the Wiktionary Transwiki: namespace.  (Checked: Copy all history versions for this page)


Import pages
From Wiktionary
Jump to: navigation, search

Importing pages...

    * No pages to import.

Import failed: XML import parse failure at line 6894, col 12 (byte 658379; " "): Invalid document end 

Next, when futzing with it manually, I un-check "Copy all history versions for this page" and try manually...

...and because Brion asked me to make this friggin' report today, it (for the first time) works.  No fair!

When I tried this manually, last, it was the same "cannot open log" thing.  Grrr.  OK, so re-checking the "copy all revisions" thing, I try it again.  And again.  WTF?  108 versions imported?  How dare it work, when I'm trying to demonstrate that it doesn't work?

Comment 4 Connel MacKenzie 2007-07-24 04:23:52 UTC
Fine.  Trying another example that has been failing for over a week, every day (two weeks?  Who knows.)  

From en.wikt:, importing [[w:List of SMS abbreviations]] to en.wikt's Transwiki: ns, all versions.

Import pages
From Wiktionary
Jump to: navigation, search

Importing pages...

    * No pages to import.

Import failed: XML import parse failure at line 43779, col 12 (byte 1400655; " "): Invalid document end 


Second try:

Import pages
From Wiktionary
Jump to: navigation, search

Importing pages...

    * No pages to import.

Import failed: XML import parse failure at line 87680, col 8 (byte 2843634; ""): Invalid document end 


Third try:

Import pages
From Wiktionary
Jump to: navigation, search

Importing pages...

    * Transwiki:List of SMS abbreviations 29 revisions

Import succeeded! 

STOP IT!  STOP IT I SAY!   Grrrrrrrrrrrrrrrr
Comment 5 Connel MacKenzie 2007-07-24 04:38:09 UTC
Trying again with [[w:List of French phrases used by English speakers]], I get "Couldn't open import file" the first four tries, then 

Import failed: XML import parse failure at line 85209, col 1 (byte 6059085; ""): Invalid document end 

then

Import failed: XML import parse failure at line 121845, col 69 (byte 8493987; ""): Invalid document end 

Import failed: XML import parse failure at line 122327, col 24 (byte 8524352; ""): Invalid document end 

Import failed: XML import parse failure at line 150448, col 5 (byte 10355219; ""): Invalid document end 

Import failed: XML import parse failure at line 188653, col 241 (byte 13122542; ""): Invalid document end 

Import failed: XML import parse failure at line 145520, col 12 (byte 10026102; ""): Invalid document end

Import failed: XML import parse failure at line 179175, col 231 (byte 12384013; ""): Invalid document end

Import failed: XML import parse failure at line 131547, col 165 (byte 9106663; ""): Invalid document end

Import failed: XML import parse failure at line 185168, col 67 (byte 12846535; ""): Invalid document end

Import failed: XML import parse failure at line 136635, col 134 (byte 9435729; ""): Invalid document end

Import failed: XML import parse failure at line 132979, col 82 (byte 9198574; ""): Invalid document end

etc.

(Wish granted.  It went back to breaking.  :-(  )
Comment 6 Connel MacKenzie 2007-07-24 04:43:41 UTC
(cont.)

Import failed: XML import parse failure at line 184308, col 84 (byte 12778764;
""): Invalid document end

-- Served by srv136 in 5.508 secs. --

Import failed: XML import parse failure at line 190401, col 2 (byte 13262462;
""): Invalid document end

-- Served by srv125 in 6.480 secs. --
Comment 7 Connel MacKenzie 2007-07-24 04:52:43 UTC
Import failed: XML import parse failure at line 186904, col 91 (byte 12984078; ""): Invalid document end
-- Served by srv145 in 5.446 secs. --

then
Import failed: XML import parse failure at line 131059, col 171 (byte 9075779; ""): Invalid document end
-- Served by srv84 in 5.660 secs. --

Import failed: XML import parse failure at line 134832, col 18 (byte 9318267; ""): Invalid document end
-- Served by srv93 in 5.561 secs. --

Import failed: XML import parse failure at line 161222, col 47 (byte 11083452; ""): Invalid document end
-- Served by srv72 in 5.713 secs. --
Comment 8 Connel MacKenzie 2007-07-25 07:11:48 UTC
Import failed: XML import parse failure at line 86885, col 8 (byte 6169132; ""): EntityRef: expecting ';'
-- Served by srv41 in 4.611 secs. --
Comment 9 Mike.lifeguard 2007-11-09 00:07:59 UTC
At [[Help:Import#Large-scale transfer]] it says "For a large-scale transfer, somebody with sufficient system privileges can move data within the server, which is more practical than sending large XML files from the server to a user's local computer and then back to the server." Is this a potential workaround for failed imports?
Comment 10 Mike.lifeguard 2008-04-07 23:05:26 UTC
Using WhatLinksHere for Template:Import failed at en.wikibooks may yield some useful data on which pages made full-history import break and when.

http://en.wikibooks.org/wiki/Special:WhatLinksHere/Template:Import_failed
Comment 11 Siebrand Mazeland 2008-08-18 18:55:30 UTC
Mass compoment change: <some> -> Export/Import
Comment 12 This, that and the other (TTO) 2014-07-27 09:52:36 UTC
Note that this bug was filed when Import was using the expat-based "XML Parser" PHP framework.

Currently, Import uses XMLReader (a somewhat crappy libxml wrapper). The only way to get proper error handling from this is to call global config functions like libxml_use_internal_errors(true). Given that other XMLReader global config functions have other issues with thread safety, I would be very nervous about trying that.

Having said that, I notice no-one has commented here since 2008, and XMLReader has been implemented since then, so I wonder if this can be closed...
Comment 13 Andre Klapper 2014-10-17 11:31:18 UTC
(In reply to This, that and the other (TTO) from comment #12)
> I notice no-one has commented here since 2008, and XMLReader has been
> implemented since then, so I wonder if this can be closed...

Closing. If this is still a problem nowadays, anybody please file a new report.

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


Navigation
Links