Patches item #1896070, was opened at 2008-02-18 13:49
Message generated for change (Tracker Item Submitted) made by Item Submitter
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=603140&aid=1896070&group_…
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: None
Group: None
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: NicDumZ — Nicolas Dumazet (nicdumz)
Assigned to: Nobody/Anonymous (nobody)
Summary: Redirect.py : Fixing namespace handling
Initial Comment:
"namespaces" is a list : Its init. is not None but [], hence it has no reason to be None.
Redirect.py was testing the namespace even when no -namespace arg. was provided
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=603140&aid=1896070&group_…
Bugs item #1894621, was opened at 2008-02-15 21:09
Message generated for change (Comment added) made by nicdumz
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=603138&aid=1894621&group_…
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: None
Group: None
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: NicDumZ — Nicolas Dumazet (nicdumz)
Assigned to: Nobody/Anonymous (nobody)
Summary: interwiki.py wp.Error "Invalid title '' "
Initial Comment:
r5030 :
interwiki.py -autonomous -start:"Parti whig"
Stack :
Sleeping for 5.0 seconds, 2008-02-15 20:32:59
NOTE: [[Particule (grammaire)]]: [[fr:Mot-outil]] gives duplicate interwiki on same site [[de:Synsemantikum]]
NOTE: [[Particule (grammaire)]]: [[fr:Mot-outil]] gives duplicate interwiki on same site [[br:Ger goullo]]
Getting 60 pages from wikipedia:en...
[[Partis politiques sous la Restauration]]: [[en:Bourbon Restoration]] gives new interwiki [[ro:Restauraţia franceză]]
[[Partis politiques sous la Restauration]]: [[en:Bourbon Restoration]] gives new interwiki [[fa:بازگشت بوربونها به سلطنت فرانسه]]
[[Partis politiques sous la Restauration]]: [[en:Bourbon Restoration]] gives new interwiki [[he:הרסטורציה]]
[[Partis politiques sous la Restauration]]: [[en:Bourbon Restoration]] gives new interwiki [[no:Restaurasjonen i Frankrike]]
[[Partis politiques sous la Restauration]]: [[en:Bourbon Restoration]] gives new interwiki [[es:Restauración Francesa]]
[[Partis politiques sous la Restauration]]: [[en:Bourbon Restoration]] gives new interwiki [[ja:フランス復古王政]]
[[Partis politiques sous la Restauration]]: [[en:Bourbon Restoration]] gives new interwiki [[nl:Restauratie (Frankrijk)]]
[[Partis politiques sous la Restauration]]: [[en:Bourbon Restoration]] gives new interwiki [[sv:Bourbonska restaurationen]]
NOTE: [[Partis politiques sous la Restauration]]: [[en:Bourbon Restoration]] gives duplicate interwiki on same site [[fr:Restauration française]]
[[Partis politiques sous la Restauration]]: [[en:Bourbon Restoration]] gives new interwiki [[de:Restauration (Frankreich)]]
[[Partis politiques sous la Restauration]]: [[en:Bourbon Restoration]] gives new interwiki [[it:Restaurazione]]
[[Partis politiques sous la Restauration]]: [[en:Bourbon Restoration]] gives new interwiki [[sr:Бурбонска рестаурација]]
[[Partis politiques sous la Restauration]]: [[en:Bourbon Restoration]] gives new interwiki [[ru:Реставрация Бурбонов]]
[[Partis politiques sous la Restauration]]: [[en:Bourbon Restoration]] gives new interwiki [[tr:Restorasyon (Fransa)]]
[[Partition d'un entier]]: [[en:Partition (number theory)]] gives new interwiki [[zh:整數分拆]]
[[Partition d'un entier]]: [[en:Partition (number theory)]] gives new interwiki [[he:פונקציית החלוקה (תורת המספרים)]]
[[Partition d'un entier]]: [[en:Partition (number theory)]] gives new interwiki [[ja:整数分割]]
[[Partition d'un entier]]: [[en:Partition (number theory)]] gives new interwiki [[sv:Partitionsfunktionen]]
NOTE: [[Partition d'un entier]]: [[en:Partition (number theory)]] gives duplicate interwiki on same site [[fr:Partage d'un entier]]
[[Partition d'un entier]]: [[en:Partition (number theory)]] gives new interwiki [[de:Partitionsfunktion]]
[[Partition d'un entier]]: [[en:Partition (number theory)]] gives new interwiki [[it:Partizione di un intero]]
[[Partition d'un entier]]: [[en:Partition (number theory)]] gives new interwiki [[ru:Разбиение числа]]
Dump fr (wikipedia) saved
Traceback (most recent call last):
File "interwiki.py", line 1644, in <module>
bot.run()
File "interwiki.py", line 1408, in run
self.queryStep()
File "interwiki.py", line 1382, in queryStep
self.oneQuery()
File "interwiki.py", line 1378, in oneQuery
subject.workDone(self)
File "interwiki.py", line 679, in workDone
redirectTargetPage = wikipedia.Page(page.site(), arg.args[0])
File "/home/nico/projets/pywikipedia/wikipedia.py", line 346, in __init__
raise Error(u"Invalid title '%s'" % title )
wikipedia.Error: Invalid title ''
Cheers !
----------------------------------------------------------------------
>Comment By: NicDumZ — Nicolas Dumazet (nicdumz)
Date: 2008-02-18 13:45
Message:
Logged In: YES
user_id=1963242
Originator: YES
My patch apparently solves the first issue, but I just raised again the
same error, working on a dump :
python redirect.py double
-xml:/media/hda5/frwiki-20080216-pages-articles.xml
Checked for running processes. 2 processes currently running, including
the current process.
Reading XML dump...
10000 pages read...
20000 pages read...
30000 pages read...
40000 pages read...
50000 pages read...
60000 pages read...
70000 pages read...
80000 pages read...
90000 pages read...
100000 pages read...
110000 pages read...
120000 pages read...
130000 pages read...
Traceback (most recent call last):
File "redirect.py", line 398, in <module>
main()
File "redirect.py", line 394, in main
bot.run()
File "redirect.py", line 349, in run
self.fix_double_redirects()
File "redirect.py", line 260, in fix_double_redirects
for redir_name in self.generator.retrieve_double_redirects():
File "redirect.py", line 204, in retrieve_double_redirects
dict = self.get_redirects_from_dump()
File "redirect.py", line 128, in get_redirects_from_dump
if wikipedia.Page(site, entry.title).namespace() not in
self.namespaces:
File "/home/nico/projets/pywikipedia/wikipedia.py", line 346, in
__init__
raise Error(u"Invalid title '%s'" % title )
This came from a very particular page, entitled " " (a non-breaking space)
: http://fr.wikipedia.org/w/index.php?title=%C2%A0&redirect=no
I'm thinking of using strip(" ") instead of strip(). I tried, and it works
for me now.
Index: wikipedia.py
===================================================================
--- wikipedia.py (révision 5044)
+++ wikipedia.py (copie de travail)
@@ -332,7 +332,9 @@
while u" " in t:
t = t.replace(u" ", u" ")
# Strip spaces at both ends
- t = t.strip()
+ # strip(" ") *is* different of strip() because strip()
+ # also removes non breaking spaces
+ t = t.strip(" ")
# Remove left-to-right and right-to-left markers.
t = t.replace(u'\u200e', '').replace(u'\u200f', '')
# leading colon implies main namespace instead of the
default
@@ -627,6 +629,9 @@
self._getexception = NoPage
raise
except IsRedirectPage, arg:
+ if not arg[0]:
+ output(u"WARNING: %s contains an empty redirect tag,
ignoring it" % self.aslink())
+ pass
self._getexception = IsRedirectPage
self._redirarg = arg
if not get_redirect and not nofollow_redirects:
----------------------------------------------------------------------
Comment By: NicDumZ — Nicolas Dumazet (nicdumz)
Date: 2008-02-16 12:06
Message:
Logged In: YES
user_id=1963242
Originator: YES
This simple patch will certainly solve the issue :
Index: wikipedia.py
===================================================================
--- wikipedia.py (révision 5036)
+++ wikipedia.py (copie de travail)
@@ -627,8 +627,11 @@
self._getexception = NoPage
raise
except IsRedirectPage, arg:
+ if not arg[0]:
+ output(u"WARNING: %s contains an empty redirect tag,
ignoring it" % self.aslink())
+ pass
self._getexception = IsRedirectPage
self._redirarg = arg
if not get_redirect and not nofollow_redirects:
raise
except SectionError:
(I don't think that modifying the redirectRegex would be a good idea,
since it would not allow us to remove an empty redirect using that Regex)
Also, per http://fr.wikipedia.org/wiki/Utilisateur:DumZiBoT/Temp, pages
such as :
#REDIRECT [[]]
#REDIRECT [[Page]]
Are not considered by mediawiki as a redirect page, so it's OK to ignore
the first redirect :)
Cheers !
----------------------------------------------------------------------
Comment By: NicDumZ — Nicolas Dumazet (nicdumz)
Date: 2008-02-15 21:51
Message:
Logged In: YES
user_id=1963242
Originator: YES
Actually, this was caused by an empty redirect tag (#REDIRECT [[]])
inserted in that diff :
http://en.wikipedia.org/w/index.php?title=Louisiana_Waterthrush&diff=190851…
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=603138&aid=1894621&group_…
Patches item #1895925, was opened at 2008-02-18 10:36
Message generated for change (Settings changed) made by wikipedian
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=603140&aid=1895925&group_…
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: None
Group: None
>Status: Closed
>Resolution: Accepted
Priority: 5
Private: No
Submitted By: Uberfuzzy (uberfuzzy)
Assigned to: Nobody/Anonymous (nobody)
Summary: added missing console colors to terminal_interface.py
Initial Comment:
adds the missing windows console color names
----------------------------------------------------------------------
>Comment By: Daniel Herding (wikipedian)
Date: 2008-02-18 12:31
Message:
Logged In: YES
user_id=880694
Originator: NO
Applied, thank you.
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=603140&aid=1895925&group_…
Bugs item #1895795, was opened at 2008-02-18 05:48
Message generated for change (Settings changed) made by wikipedian
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=603138&aid=1895795&group_…
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: None
Group: None
>Status: Closed
>Resolution: Fixed
Priority: 5
Private: No
Submitted By: Alex S.H. Lin (lin4h)
Assigned to: Nobody/Anonymous (nobody)
Summary: All codes response "Token not foun on...."
Initial Comment:
WARNING: Token not found on wikipedia:zh. You will not be able to edit any page.
I have no idea why any codes response this and my script can edit page, maybe the regex have bug?
----------------------------------------------------------------------
Comment By: Rotem Liss (rotemliss)
Date: 2008-02-18 07:20
Message:
Logged In: YES
user_id=1327030
Originator: NO
Fixed in r5043.
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=603138&aid=1895795&group_…
Bugs item #1895986, was opened at 2008-02-18 05:43
Message generated for change (Tracker Item Submitted) made by Item Submitter
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=603138&aid=1895986&group_…
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: None
Group: None
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: Uberfuzzy (uberfuzzy)
Assigned to: Nobody/Anonymous (nobody)
Summary: wikipedia.py infinite loop
Initial Comment:
prints the getting page...
then hangs (only in output, network activity reveals otherwise)
ctrl+c prints out a ton of this (assumed it was printed during the loop where its stuck)
File "E:\pybot\wikipedia.py", line 4112, in getUrl
self._getUserData(text, sysop = sysop)
File "E:\pybot\wikipedia.py", line 4139, in _getUserData
blocked = self.mediawiki_message('blockedtitle') in text
File "E:\pybot\wikipedia.py", line 4245, in mediawiki_message
key))
see attached log for -v output
i cut out most of the looped text, but left 3 of the above in.
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=603138&aid=1895986&group_…
Patches item #1895925, was opened at 2008-02-18 04:36
Message generated for change (Tracker Item Submitted) made by Item Submitter
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=603140&aid=1895925&group_…
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: None
Group: None
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: Uberfuzzy (uberfuzzy)
Assigned to: Nobody/Anonymous (nobody)
Summary: added missing console colors to terminal_interface.py
Initial Comment:
adds the missing windows console color names
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=603140&aid=1895925&group_…
Support Requests item #1885569, was opened at 2008-02-03 01:43
Message generated for change (Comment added) made by uberfuzzy
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=603139&aid=1885569&group_…
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: None
Group: None
Status: Open
Priority: 5
Private: No
Submitted By: Xwing328 (xwing328)
Assigned to: Nobody/Anonymous (nobody)
Summary: Replace.py adds wikia-credits text
Initial Comment:
Whenever replace.py makes a change to an article, it adds the following text to the very end of the article: <div id="wikia-credits"><br /><br /><small>From [[wikia:c:starwars|Wookieepedia]], a [[wikia:|Wikia]] wiki.</small></div>
You can see a test of this on Wookieepedia, the Star Wars wiki, here: http://starwars.wikia.com/index.php?title=%22Rachet%22_Gramzee&diff=1780117…
This seems to be related to a MediaWiki upgrade. I've tried it on both my old version of Pywikipedia, and several of the new snapshots, with the same problem occurring. Any help with this would be greatly appreciated.
----------------------------------------------------------------------
Comment By: Uberfuzzy (uberfuzzy)
Date: 2008-02-18 04:24
Message:
Logged In: YES
user_id=1976885
Originator: NO
i was told by staff that this is not a bug.
when data is exported and taken to other wikis (both internal to wikia and
external), this linkback will show where its from.
the problem is, it also affects every bot page get.
i patched my wikipedia.py file to auto filter this out.
down around line 640ish (may move depending on patches)
there is a line "return self._contents"
this is the line returning the raw wiki text for other scripts.
on the line before it add this
self._contents = re.sub('<div id="wikia-credits">.*</div>', '',
self._contents)
make sure to keep the same indenting, and make sure its done with spaces
and not tabs.
----------------------------------------------------------------------
Comment By: Xwing328 (xwing328)
Date: 2008-02-04 11:29
Message:
Logged In: YES
user_id=1999124
Originator: YES
OK, thank you for you replies. I will talk to our wikia contact soon to
see if they can fix the problem.
Also, if this has been discussed before, I couldn't find it when I
searched through the support and bug pages.
----------------------------------------------------------------------
Comment By: Daniel Herding (wikipedian)
Date: 2008-02-04 03:45
Message:
Logged In: YES
user_id=880694
Originator: NO
This is not only a Wookieepedia problem, but also occurs on (probably all)
other Wikia wikis, for example on
http://aachen.wikia.com/wiki/Spezial:Exportieren/Hauptseite .
I would also say that this is a Wikia bug and that they should fix it. By
the way, haven't we discussed this issue some time before already?
----------------------------------------------------------------------
Comment By: Andre Engels (a_engels)
Date: 2008-02-03 16:26
Message:
Logged In: YES
user_id=843018
Originator: NO
I don't know what to do about it, but I can tell you what the cause is:
The cause is that the bot gets its text from [[Special:Export]], and on
Wookieepedia this text has been added to all pages on the export page. If
you have contact with the people who can change that, you can ask them to
change it back or to create a special 'raw' export page for the bot.
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=603139&aid=1885569&group_…
Bugs item #1895795, was opened at 2008-02-18 06:48
Message generated for change (Comment added) made by rotemliss
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=603138&aid=1895795&group_…
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: None
Group: None
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: Alex S.H. Lin (lin4h)
Assigned to: Nobody/Anonymous (nobody)
Summary: All codes response "Token not foun on...."
Initial Comment:
WARNING: Token not found on wikipedia:zh. You will not be able to edit any page.
I have no idea why any codes response this and my script can edit page, maybe the regex have bug?
----------------------------------------------------------------------
>Comment By: Rotem Liss (rotemliss)
Date: 2008-02-18 08:20
Message:
Logged In: YES
user_id=1327030
Originator: NO
Fixed in r5043.
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=603138&aid=1895795&group_…