Index: trunk/tools/editor_trends/etl/enricher.py |
— | — | @@ -348,7 +348,7 @@ |
349 | 349 | def count_edits(article, counts, bots): |
350 | 350 | title = article['title'].text |
351 | 351 | namespace = determine_namespace(title) |
352 | | - |
| 352 | + xml_namespace = 'http://www.mediawiki.org/xml/export-0.4/' |
353 | 353 | if namespace != False: |
354 | 354 | article_id = article['id'].text |
355 | 355 | revisions = article['revisions'] |
— | — | @@ -357,7 +357,7 @@ |
358 | 358 | #the entire revision is empty, weird. |
359 | 359 | continue |
360 | 360 | dump(revision) |
361 | | - contributor = revision.find('ns0:contributor') |
| 361 | + contributor = revision.find('%s:contributor' % xml_namespace) |
362 | 362 | contributor = parse_contributor(contributor, bots) |
363 | 363 | if not contributor: |
364 | 364 | #editor is anonymous, ignore |