Hm, I found a double Content-Lenght in the header calling site.getURL(): Content-Type: application/json; charset=utf-8 Connection: close Server: Nginx / Varnish X-Powered-By: PHP/5.2.17 Set-Cookie: PHPSESSID=5a0988aa9e6d3b9727485235b98b0318; path=/ Expires: Thu, 19 Nov 1981 08:52:00 GMT Pragma: no-cache Cache-Control: private Content-Encoding: gzip Vary: Accept-Encoding Content-Length: 151 Content-Length: 151
Maybe this causes that error. I'll investigate... Regards xqt ----- Original Nachricht ---- Von: Tom <[email protected]> An: Pywikipedia discussion list <[email protected]> Datum: 27.01.2012 22:20 Betreff: Re: [Pywikipedia-l] Was feeling lucky- "Not" - still error onother wiki > What is the form of the POST and GET from pywikiapedia? > > HTTP 1.0 or 1.1 and is there a host header URL in the header?? > > I tried a few things and POST works fine with web sniffer and the server > responds fine with HTTP 1.0 or 1.1 but in 1.0 without host header it fails, > not found, 404, no response. > > I tried same with other wikis, responses were not 404 but 401, authorization > required to access, which I think is right. > > Still looking to solve this issue. > > Thanks > Tom > > > On Jan 26, 2012, at 4:14 PM, <[email protected]> wrote: > > > Let us explore in that issue, please send us the dump file too: > > ApiGetDataParse_isoggbot_en__Thu_Jan_26_07-58-17_2012.dump > > > > Regards > > xqt > > Von: Tom Hutchison > > Gesendet: 26.01.2012 14:17 > > An: 'Pywikipedia discussion list' > > Betreff: Re: [Pywikipedia-l] Was feeling lucky- "Not" - still error > onother wiki > > > > Ok, now we're getting somewhere. Cookie issue I think. How to solve it? > > > > Microsoft Windows XP [Version 5.1.2600] > > (C) Copyright 1985-2001 Microsoft Corp. > > > > C:\ISOOGBot>login.py -v > > Config.py > > - base_dir: C:\ISOOGBot > > - done. > > unicode test: triggers problem #3081100 > > Pywikipediabot [http] trunk/pywikipedia (r9842, 2012/01/22, 00:51:55) > > Python 2.7 (r27:82525, Jul 4 2010, 09:01:59) [MSC v.1500 32 bit (Intel)] > > Password for user WikiBot on isoggbot:en: > > Logging in to isoggbot:en as WikiBot via API. > > ==== API action:login ==== > > lgname: WikiBot > > lgpassword: XXXXX > > ---------------- > > Requesting API query from isoggbot:en > > Error downloading data: invalid literal for int() with base 10: '147, > 147' > > Request en:/w/api.php? > > Retrying in 1 minutes... > > Error downloading data: invalid literal for int() with base 10: '147, > 147' > > Request en:/w/api.php? > > Retrying in 2 minutes... > > Error downloading data: invalid literal for int() with base 10: '147, > 147' > > Request en:/w/api.php? > > Retrying in 4 minutes... > > Error downloading data: invalid literal for int() with base 10: '147, > 147' > > Request en:/w/api.php? > > Retrying in 8 minutes... > > Error downloading data: invalid literal for int() with base 10: '147, > 147' > > Request en:/w/api.php? > > Retrying in 16 minutes... > > Error downloading data: invalid literal for int() with base 10: '147, > 147' > > Request en:/w/api.php? > > ERROR: ApiGetDataParse caused error invalid literal for int() with base > 10: '147, 147' > > www.isogg.org > > /w/api.php?. Dump > ApiGetDataParse_isoggbot_en__Thu_Jan_26_07-58-17_2012.dump created. > > Traceback (most recent call last): > > File "C:\ISOOGBot\login.py", line 436, in <module> > > main() > > File "C:\ISOOGBot\login.py", line 432, in main > > loginMan.login() > > File "C:\ISOOGBot\login.py", line 319, in login > > cookiedata = self.getCookie(api) > > File "C:\ISOOGBot\login.py", line 181, in getCookie > > response, data = query.GetData(predata, self.site, sysop=self.sysop, > back_response = True) > > File "C:\ISOOGBot\query.py", line 171, in GetData > > raise lastError > > ValueError: invalid literal for int() with base 10: '147, 147' > > > > C:\ISOOGBot> > > > > > > Thanks > > Tom > > > > -----Original Message----- > > From: [email protected] > > [mailto:[email protected]] On Behalf Of > [email protected] > > Sent: Thursday, January 26, 2012 3:23 AM > > To: [email protected] > > Subject: Re: [Pywikipedia-l] Was feeling lucky- "Not" - still error on > other wiki > > > > Additional to Merlijns mail please start again and wait until the bots api > request is finished. > > It tries I guess 5 times and should then raise an error with trace > informations. Also it > > creates a dump file named "ApiGetDataParse<something_else>". Please give > us that dump file > > (content). > > > > Regards > > xqt > > > > ----- Original Nachricht ---- > > Von: Merlijn van Deen <[email protected]> > > An: Pywikipedia discussion list <[email protected]> > > Datum: 26.01.2012 08:10 > > Betreff: Re: [Pywikipedia-l] Was feeling lucky- "Not" - still error on > other > > wiki > > > > > > > > > > Error downloading data: invalid literal for int() with base 10: '147, > > > 147' > > > > **** > > > > > > > > > > > > > > > could you try running login.py with the -v flag? This will give some > more > > > debug output, among others about the exact api.php queries and their > > > responses. > > > > > > Secondary to that, if you could give the url to the wiki (i.e. it's not > a > > > private or local wiki), that would help with debugging /a lot/. > > > > > > Best, > > > Merlijn > > > > > > > > > -------------------------------- > > > > > > _______________________________________________ > > > Pywikipedia-l mailing list > > > [email protected] > > > https://lists.wikimedia.org/mailman/listinfo/pywikipedia-l > > > > > > > _______________________________________________ > > Pywikipedia-l mailing list > > [email protected] > > https://lists.wikimedia.org/mailman/listinfo/pywikipedia-l > > > > > > > > _______________________________________________ > > Pywikipedia-l mailing list > > [email protected] > > https://lists.wikimedia.org/mailman/listinfo/pywikipedia-l > > _______________________________________________ > > Pywikipedia-l mailing list > > [email protected] > > https://lists.wikimedia.org/mailman/listinfo/pywikipedia-l > > > -------------------------------- > > _______________________________________________ > Pywikipedia-l mailing list > [email protected] > https://lists.wikimedia.org/mailman/listinfo/pywikipedia-l > _______________________________________________ Pywikipedia-l mailing list [email protected] https://lists.wikimedia.org/mailman/listinfo/pywikipedia-l
