and btw: "Special cases aren't special enough to break the rules." Isn't it?
xqt
----- Original Nachricht ----
Von: info(a)gno.de
An: pywikipedia-l(a)lists.wikimedia.org
Datum: 30.08.2011 22:50
Betreff: Aw: Re: [Pywikipedia-l] 'wiki' as synonym for 'wikipedia' in
family?
> Hi DrTrigon,
>
> "wiki" is reserved by Family.known_families. You know you get the related
> dbName of a site just by Site.dbName() which returns "dewiki_p" for
> "wikipedia:de". Thereby for historic reasons, the databases are called
> xxwiki instead of xxwikipedia for Wikipedias.
>
> You are using side effects doing your dbname2wikilink() conversion and I am
> sure you are able to modificate this stuff with stuff.replace("wiki:",
> "wikipedia:") if needed. In other words (your wrote me) "There should be
> one-- and preferably only one --__obvious__ way to do it" and btw "Although
> that way may not be obvious at first unless you're Dutch" (again: PEP20, The
> Zen of Python)
>
> Sali ;)
>
> xqt
>
>
> ----- Original Nachricht ----
> Von: "Dr. Trigon" <dr.trigon(a)surfeu.ch>
> An: pywikipedia-l(a)lists.wikimedia.org
> Datum: 30.08.2011 19:02
> Betreff: Re: [Pywikipedia-l] 'wiki' as synonym for 'wikipedia' in family?
>
> > -----BEGIN PGP SIGNED MESSAGE-----
> > Hash: SHA1
> >
> > > "wiki" is being use as the interwiki link to the original wiki,
> > > WikiWikiWeb at http://c2.com/cgi/wiki, so you shouldn't use that
> > > for anything related to Wikipedia. You are getting it returned
> > > since Wikipedias can use it as an interwiki link to the
> > > WikiWikiWeb, i.e. [[:wiki:WelcomeVisitors]] becomes
> > > http://c2.com/cgi/wiki?WelcomeVisitors
> >
> > So this means essentially 'wiki' in toolserver DB (like e.g. 'dewiki')
> > does not refer to the same as 'wiki' in pywikipediabot and interwiki...
> > (strange...)
> >
> > But would also explain this 'inconsistency'... ;)
> >
> > Thanks and Greetings
> > -----BEGIN PGP SIGNATURE-----
> > Version: GnuPG v1.4.11 (GNU/Linux)
> > Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/
> >
> > iEYEARECAAYFAk5dF68ACgkQAXWvBxzBrDCi8ACg0YV5W6uEDDY61xcgxB9qsKq8
> > 8KsAn0kHTE6IwqZZxZI8Lb/9Dk6E7ciP
> > =dKzI
> > -----END PGP SIGNATURE-----
> >
> > _______________________________________________
> > Pywikipedia-l mailing list
> > Pywikipedia-l(a)lists.wikimedia.org
> > https://lists.wikimedia.org/mailman/listinfo/pywikipedia-l
> >
>
Hi!
I'm turning to you with request. Is it possible for you to make python
script, which would make compitation of articles (from :sl - Slovenian WP):
a) created by me (Username: Klemen Kocjancic) and
b) linked to http://sl.wikipedia.org/wiki/Portal:Vojaštvo<http://sl.wikipedia.org/wiki/>
The script should combined both search quiries (with removing duplicated
articles) and make a list of articles in following form:
yyyy xxxx
'''X'''Y
yyyy xxxx
'''X'''Y
yyyy xxxx
X = article's title
Y = article's text
Is this possible? Could you recommend someone, if you can't make it? Because
I'm using pyton (and AWB) for adding/maintence, I'm requesting script in
this language, but if any can write script in any other language, is also
fine with me.
Regards,
Klemen Kocjancic
admin, :sl WP
--
Klemen Kocjančič
Litostrojska 7
1000 Ljubljana
+386-31-352-161
Hi replace.py users,
I wrote a new chapter to Meta, mainly for beginners. I hope it will be
easier to start with this description. See
http://meta.wikimedia.org/wiki/Pywikipediabot/replace.py#Overview. Please
check it and complete is necessary.
(Article on fixes.py is the next important task.)
--
Bináris
Hello all!
I am searching desperately for a solution to following problem.
DrTrigonBot is written such that in case of an (not severe) error
the bot should send an email with a notification to me. BUT the
strange thing I do not understand is; userlib.py is not able to
send emails about 50% of the tries...
Some info can be found in (at the very end):
http://toolserver.org/~drtrigon/DrTrigonBot/20110724.log
The error raised is
'UserActionRefuse("You don't have permission to send mail",)'
Does anyone have an idea how to solve this? In my view this is
triggered by "if not self.site().isAllowed('sendemail'):" in
"userlib.sendMail" but WHY is this 'sendemail' flags sometimes
true and sometimes false...?!?
Thanks a lot for your help and time
Greetings to all!
DrTrigon
Hello xqt,
On 21 August 2011 15:49, <xqt(a)svn.wikimedia.org> wrote:
> + value. At the moment, we have only one plural_func = x: x!= 1 yet.
> Multiple
> + PLURAL tags are not supported (yet).
>
Good to see you're working on plural support. Have you seen
http://svn.wikimedia.org/viewvc/mediawiki/trunk/extensions/Translate/data/p…
,
which lists the plural possibilities for each language. Unfortunately,
python does not support the a ? b : c notation, so it's not possible to
copy the code 1-on-1.
Alternatively, there is
http://svn.wikimedia.org/viewvc/mediawiki/trunk/extensions/Translate/data/p…
,
but that is fairly unreadable IMO.
Good luck!
Best,
Merlijn
in my cosmetic_changes.py I have following lines:
text = pywikibot.replaceExcept(text, u' m. n. m.', u' m n.
m.', ['comment', 'math', 'nowiki', 'pre'])
text = pywikibot.replaceExcept(text, u' viz.', u' viz',
['comment', 'math', 'nowiki', 'pre'])
I think, that r in the beginning means regular expression, but u means
simple text.
But bot takes dot like any character, so i got e.g.
revize ->reviz
má na mále -> m na mále
http://cs.wikipedia.org/w/index.php?title=Ferrari_FF&action=historysubmit&d…
How to channge it to correct output?
JAnD
--
--
Ing. Jan Dudík
Dear pywiki-colleagues,today this error has happened to me - after I've
replaced about 1000 pages - as I was replacing a text by replace.py (as
can be seen). I can not understand what is wrong, some info?
================================
Traceback (most recent call last):
File "replace.py", line 818, in <module>
main()
File "replace.py", line 809, in main
bot.run()
File "replace.py", line 398, in run
new_text = self.doReplacements(new_text)
File "replace.py", line 341, in doReplacements
allowoverlap=self.allowoverlap)
File "/home/Marco/pywikipedia/pywikibot/textlib.py", line 176, in
replaceExcept
match.group(groupID) + \
IndexError: no such group
================================
Thanks, Marco.