Revision: 4528
Author: rotem
Date: 2007-11-11 13:51:14 +0000 (Sun, 11 Nov 2007)
Log Message:
-----------
Fix a KeyError when searching Whatlinkshere, that next_text could be a div (if 'next ' is not a link); check if it has the href attribute before getting it.
Modified Paths:
--------------
trunk/pywikipedia/wikipedia.py
Modified: trunk/pywikipedia/wikipedia.py
===================================================================
--- trunk/pywikipedia/wikipedia.py 2007-11-10 20:55:46 UTC (rev 4527)
+++ trunk/pywikipedia/wikipedia.py 2007-11-11 13:51:14 UTC (rev 4528)
@@ -1011,7 +1011,7 @@
convertEntities=BeautifulSoup.HTML_ENTITIES,
parseOnlyThese=content)
next_text = body.find(text=nextpattern)
- if next_text is not None:
+ if next_text is not None and next_text.has_key('href'):
path = next_text.parent['href'].replace("&", "&")
else:
path = ""
Bugs item #1829405, was opened at 2007-11-09 23:47
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=1829405&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: Nobody/Anonymous (nobody)
Assigned to: Nobody/Anonymous (nobody)
Summary: redirect.py says pages don't exist
Initial Comment:
When inputting "python redirect.py double", 120 redirects are found, and each is individually opened, but instead of fixing them, it returns "[[PAGENAME]] doesn't exist." instead.
See the attached screenshot
anotherpeteparker(a)gmail.com
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=603138&aid=1829405&group_…
Patches item #1820253, was opened at 2007-10-25 21:53
Message generated for change (Comment added) made by malafaya
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=603140&aid=1820253&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: Out of Date
Priority: 5
Private: No
Submitted By: André Malafaya Baptista (malafaya)
Assigned to: Nobody/Anonymous (nobody)
Summary: Correction to Swedish featured article category
Initial Comment:
Please replace line 130 of featured.py by:
'sv': (CAT, u"Kategori:Wikipedia:Utmärkta artiklar"),
This corrects the category link. Thanks.
----------------------------------------------------------------------
>Comment By: André Malafaya Baptista (malafaya)
Date: 2007-11-09 22:58
Message:
Logged In: YES
user_id=1037345
Originator: YES
Already fixed in r4523.
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=603140&aid=1820253&group_…
(I don't know what it is with Gmail. If you click "reply" it will only
send to the original sender, not to the mailing list)
---------- Forwarded message ----------
From: Huji <huji.huji(a)gmail.com>
Date: Nov 6, 2007 9:03 PM
Subject: Re: [Pywikipedia-l] Rewrite thoughts (includes replies to the
4507-thread)
To: Bryan Tong Minh <bryan.tongminh(a)gmail.com>
Someone spoke about democracy here?!
As a citizen (!) I vote for: camelCase for functions and variables and
CamelCase for class names. (The difference between the two is obvious,
isn't it?!)
About BOM, I hope every editor has a way to add it to the beginning of
the file. (In MediaWiki codes, when a BOM was added by notepad, I had
to remove it to make the code work correct, and it was a pain in ass;
now, I have this pessimistic feeling about adding it for Pywikipedia).
Moving to the API is great, but it has its limitations. For example,
to my knowledge, it is impossible to get a list of more than 500 pages
from the API, so perhaps we need to find a way to get a bigger list
(for example for autonomous tasks).
About the backward compatability issue some people notified
previously, I think it is a good idea to start tagging versions of
Pywikiedpiabot. For example, version 1.0 works with HTML parsing,
version 1.1 implements API only and works with MW 11.0 and above,
version 1.5 works with API only and MW 12.0 and above, and so on.
I strongly support the idea of separating the framework from the bots.
With that in mind, I think we should use a different approach about
i18n and l10n. Consequently, I'm making no changes to the
/pywikipedia/messages branch, untill we know how the new i18n system
is going to work.
Finally, as many of you may know or guess, I'm not a professional
programmer, so my comments may look a little silly, or worded in a way
you don't usually expect. So excuse me about that.
Hojjat (aka Huji)
Patches item #1828962, was opened at 2007-11-09 14:30
Message generated for change (Settings changed) made by valhallasw
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=603140&aid=1828962&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: None
Priority: 5
Private: No
Submitted By: Alleborgo (alleborgo)
Assigned to: Nobody/Anonymous (nobody)
Summary: interwiki.py - Uzbek language summary translation
Initial Comment:
patch to add edit summary translations for Uzbek language.
----------------------------------------------------------------------
Comment By: Filnik (filnik)
Date: 2007-11-09 17:20
Message:
Logged In: YES
user_id=1834469
Originator: NO
Patch committed.
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=603140&aid=1828962&group_…