http://www.mediawiki.org/wiki/Special:Code/pywikipedia/8881
Revision: 8881
Author: siebrand
Date: 2011-01-22 19:43:33 +0000 (Sat, 22 Jan 2011)
Log Message:
-----------
Temporarily fix issue in FFS used for Pywikipedia.
Modified Paths:
--------------
branches/rewrite/scripts/i18n/redirect.py
Modified: branches/rewrite/scripts/i18n/redirect.py
===================================================================
--- branches/rewrite/scripts/i18n/redirect.py 2011-01-22 18:54:57 UTC (rev 8880)
+++ branches/rewrite/scripts/i18n/redirect.py 2011-01-22 19:43:33 UTC (rev 8881)
@@ -265,9 +265,7 @@
'qqq': {
'redirect-fix-double': u'Edit summary when the bot fixes double redirects. %(to)s displays the new redirect target as a wiki link.',
'redirect-remove-loop': u'Edit summary when the bot tags a redirect loop for speedy deletion.',
- 'redirect-broken-redirect-template': u'Template for speedy deletion of broken redirect or redirect loops which the bot tags onto the redirect page. This message may contain additional informations like template parameters or reasons for the deletion request.
-
-NOTE: If this system message is not given for a language code, speedy deletion request by a bot is not supported on your site except there is a bot with sysop flag.',
+ 'redirect-broken-redirect-template': u'Template for speedy deletion of broken redirect or redirect loops which the bot tags onto the redirect page. This message may contain additional informations like template parameters or reasons for the deletion request. NOTE: If this system message is not given for a language code, speedy deletion request by a bot is not supported on your site except there is a bot with sysop flag.',
'redirect-remove-broken': u'Edit summary when the bot tags a deleted or non-existent page for speedy deletion.',
},
# Author: Minisarm
http://www.mediawiki.org/wiki/Special:Code/pywikipedia/8877
Revision: 8877
Author: valhallasw
Date: 2011-01-22 15:17:01 +0000 (Sat, 22 Jan 2011)
Log Message:
-----------
Partially: revert r8636, apply r8741,r8750.
r8636 introduced a temporary fix for unicode problem #3081100. In r8741, a
more permanent solution was introduced. This solution was slightly changed in
r8750. The last solution is ported to rewrite in this commit.
Modified Paths:
--------------
branches/rewrite/scripts/interwiki.py
Modified: branches/rewrite/scripts/interwiki.py
===================================================================
--- branches/rewrite/scripts/interwiki.py 2011-01-22 15:16:56 UTC (rev 8876)
+++ branches/rewrite/scripts/interwiki.py 2011-01-22 15:17:01 UTC (rev 8877)
@@ -2363,8 +2363,10 @@
fmt = lambda d, site: site.lang
head, add, rem, mod = pywikibot.translate(insite.lang, msg)
- if insite.lang=='de' and not globalvar.autonomous:
- head = u'Halbautomatischer %s' % head #prevents abuse filter blocking for hi-wiki
+ #Version info marks bots without unicode error
+ #This also prevents abuse filter blocking on de-wiki
+ if not pywikibot.unicode_error:
+ head = u'r%s) (%s' % (sys.version.split()[0], head)
colon = u': '
comma = u', '
http://www.mediawiki.org/wiki/Special:Code/pywikipedia/8872
Revision: 8872
Author: multichill
Date: 2011-01-22 11:40:04 +0000 (Sat, 22 Jan 2011)
Log Message:
-----------
Make screen bigger (1000 -> 1500)
Modified Paths:
--------------
trunk/pywikipedia/imagecopy_self.py
Modified: trunk/pywikipedia/imagecopy_self.py
===================================================================
--- trunk/pywikipedia/imagecopy_self.py 2011-01-21 21:22:45 UTC (rev 8871)
+++ trunk/pywikipedia/imagecopy_self.py 2011-01-22 11:40:04 UTC (rev 8872)
@@ -138,7 +138,8 @@
self.root=Tk()
#"%dx%d%+d%+d" % (width, height, xoffset, yoffset)
#Always appear the same size and in the bottom-left corner
- self.root.geometry("1000x400+100-100")
+ #FIXME : Base this on the screen size or make it possible for the user to configure this
+ self.root.geometry("1500x400+100-100")
self.root.title(imagepage.titleWithoutNamespace())
http://www.mediawiki.org/wiki/Special:Code/pywikipedia/8864
Revision: 8864
Author: purodha
Date: 2011-01-21 05:52:42 +0000 (Fri, 21 Jan 2011)
Log Message:
-----------
Comment clarified.
Modified Paths:
--------------
trunk/pywikipedia/wikipedia.py
Modified: trunk/pywikipedia/wikipedia.py
===================================================================
--- trunk/pywikipedia/wikipedia.py 2011-01-21 05:30:26 UTC (rev 8863)
+++ trunk/pywikipedia/wikipedia.py 2011-01-21 05:52:42 UTC (rev 8864)
@@ -1540,7 +1540,7 @@
if the user cannot do that.
Parameters:
- * action - the action done, which is the name of the right
+ * action - the action to be done, which is the name of the right
* restriction - the restriction level or an empty string for no restriction
* sysop - initially use sysop user?
"""
http://www.mediawiki.org/wiki/Special:Code/pywikipedia/8858
Revision: 8858
Author: xqt
Date: 2011-01-18 09:54:40 +0000 (Tue, 18 Jan 2011)
Log Message:
-----------
define twhas_key to check whether a specified translation is provided (needed for redirect.py for example)
Modified Paths:
--------------
branches/rewrite/pywikibot/i18n.py
Modified: branches/rewrite/pywikibot/i18n.py
===================================================================
--- branches/rewrite/pywikibot/i18n.py 2011-01-18 09:45:40 UTC (rev 8857)
+++ branches/rewrite/pywikibot/i18n.py 2011-01-18 09:54:40 UTC (rev 8858)
@@ -239,3 +239,17 @@
return trans % parameters
else:
return trans
+
+def twhas_key(code, twtitle):
+ """ Uses TranslateWiki files to to check whether specified translation
+ based on the TW title is provided. No code fallback is made.
+
+ @param code The language code
+ @param twtitle The TranslateWiki string title, in <package>-<key> format
+
+ The translations are retrieved from i18n.<package>, based on the callers
+ import table.
+ """
+ package = twtitle.split("-")[0]
+ transdict = getattr(__import__("i18n", fromlist=[package]), package).msg
+ return code in transdict and twtitle in transdict[code]