Skip Menu |

This queue is for tickets about the Parse-MediaWikiDump CPAN distribution.

Report information
The Basics
Id: 53361
Status: resolved
Priority: 0/
Queue: Parse-MediaWikiDump

People
Owner: Nobody in particular
Requestors: derhoermi [...] gmx.net
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: Incorrectly assigned usernames with anon edits
Date: Tue, 05 Jan 2010 00:57:26 +0100
To: bug-parse-mediawikidump [...] rt.cpan.org
From: Bjoern Hoehrmann <derhoermi [...] gmx.net>
Hi, Consider: <mediawiki xmlns="http://www.mediawiki.org/xml/export-0.4/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.mediawiki.org/xml/export-0.4/ http://www.mediawiki.org/xml/export-0.4.xsd" version="0.4" xml:lang="de"> <siteinfo> <sitename>Wikipedia</sitename> <base>http://de.wikipedia.org/wiki/Wikipedia:Hauptseite</base> <generator>MediaWiki 1.16alpha-wmf</generator> <case>first-letter</case> <namespaces> <namespace key="-2">Media</namespace> <namespace key="-1">Spezial</namespace> <namespace key="0" /> <namespace key="1">Diskussion</namespace> <namespace key="2">Benutzer</namespace> <namespace key="3">Benutzer Diskussion</namespace> <namespace key="4">Wikipedia</namespace> <namespace key="5">Wikipedia Diskussion</namespace> <namespace key="6">Datei</namespace> <namespace key="7">Datei Diskussion</namespace> <namespace key="8">MediaWiki</namespace> <namespace key="9">MediaWiki Diskussion</namespace> <namespace key="10">Vorlage</namespace> <namespace key="11">Vorlage Diskussion</namespace> <namespace key="12">Hilfe</namespace> <namespace key="13">Hilfe Diskussion</namespace> <namespace key="14">Kategorie</namespace> <namespace key="15">Kategorie Diskussion</namespace> <namespace key="100">Portal</namespace> <namespace key="101">Portal Diskussion</namespace> </namespaces> </siteinfo> <page> <title>Angela Merkel</title> <id>145</id> <revision> <id>38841</id> <timestamp>2002-09-08T22:15:32Z</timestamp> <contributor> <username>Ben-Zin</username> <id>9</id> </contributor> <minor/> <comment>en: </comment> <text id="38841" /> </revision> <revision> <id>38847</id> <timestamp>2002-10-31T14:53:37Z</timestamp> <contributor> <ip>62.104.212.74</ip> </contributor> <text id="38847" /> </revision> ... Here for the second revision "username" will be "Ben-Zin" which is incorrect (Parse-MediaWikiDump-1.0.3). regards, -- Björn Höhrmann · mailto:bjoern@hoehrmann.de · http://bjoern.hoehrmann.de Am Badedeich 7 · Telefon: +49(0)160/4415681 · http://www.bjoernsworld.de 25899 Dagebüll · PGP Pub. KeyID: 0xA4357E78 · http://www.websitedev.de/
Whoops! That's a legit bug. Sorry about that; I'll get a fix out before too long.

Tyler

On Mon Jan 04 18:57:45 2010, derhoermi@gmx.net wrote:
Show quoted text
> Hi,
>
> Consider:
>
> ..............
>
> Here for the second revision "username" will be "Ben-Zin" which is
> incorrect (Parse-MediaWikiDump-1.0.3).
>
> regards,


I created a test to reproduce and verify the bug then resolved the issue by removing the username and userid keys from the accumulator every time the revision element is started. 

I also added a new method to ::page to get the contents of the IP for anonymous editors. 

I pushed the fix out as 1.0.4 which will be propagating through CPAN as this ticket is closed. 

On Mon Jan 04 19:47:56 2010, TRIDDLE wrote:
Show quoted text
> Whoops! That's a legit bug. Sorry about that; I'll get a fix out before too
> long.
>
> Tyler
>
> On Mon Jan 04 18:57:45 2010, derhoermi@gmx.net wrote:
> > Hi,
> >
> > Consider:
> >
> > ..............
> >
> > Here for the second revision "username" will be "Ben-Zin" which is
> > incorrect (Parse-MediaWikiDump-1.0.3).
> >
> > regards,