Hi All,
I had set up system such that every day the pymediawiki would insert a page
into my local wiki (
csdms.colorado.edu). This worked fine for a year till I
updated to mediawiki 1.16.0 (from 1.15.4). Since than the pagefromfile.py
isn't working anymore for me.
I updated all the pywikipedia code, still no luck, the following error
message is created (See below).
I did a check to see if the family / user-config.py & password file is set
up correctly, with "python login.py" and that works fine, the bot is able to
log into the wiki.
Also, "$wgEnableWriteAPI" is added to the LocalSettings.php file.
Any idea what might go wrong?
Thanks Albert.
Error message after command:
python ~/web/pywikipedia/pagefromfile.py -v -file:<some wikicoded.txt>
-start:startpage -end:endpage -force
********ERROR***********
Requesting API query from csdms:en
error occured, code:writeapidenied
info:You're not allowed to edit this wiki through the API
status:200
response:OK
File "/home/faculty/kettner/web/pywikipedia/pagefromfile.py", line 348, in
?
main()
File "/home/faculty/kettner/web/pywikipedia/pagefromfile.py", line 344, in
main
bot.run()
File "/home/faculty/kettner/web/pywikipedia/pagefromfile.py", line 154, in
run
self.put(title, contents)
File "/home/faculty/kettner/web/pywikipedia/pagefromfile.py", line 211, in
put
page.put(contents, comment = comment, minorEdit = self.minor)
File "/data/home/faculty/kettner/web/pywikipedia/wikipedia.py", line 1710,
in put
newPage, self.site().getToken(sysop = sysop), sysop = sysop,
botflag=botflag, maxTries=maxTries)
File "/data/home/faculty/kettner/web/pywikipedia/wikipedia.py", line 1861,
in _putPage
output("OriginalData:%s" % faked)
File "/data/home/faculty/kettner/web/pywikipedia/wikipedia.py", line 7576,
in output
print traceback.print_stack()
OriginalData:{'maxlag': '5', 'title': u'Model download
Page',
'starttimestamp': '0', 'format': u'json',
'basetimestamp':
u'20101103200220', 'summary': 'Automated import of articles ***
existing
text overwritten ***', 'token':
u'864496fb7619522ce8cb49451cd856af+\\',
'bot': u'1', 'notminor': u'1', 'action':
'edit', 'nocreate': u'1'}
Unknown Error. API Error code:writeapidenied
Information:You're not allowed to edit this wiki through the API
End of file.
**********************
--
*******************************************************
Albert J. Kettner
Research Scientist
CSDMS, INSTAAR, Univ. of Colorado
P.O.Box 545
Boulder, CO, 80309, USA
http://csdms.colorado.edu/~kettner
http://csdms.colorado.edu
*****************************************************