Without the screenshot this time....

> On Mar 28, 2023, at 2:01 PM, Roy Smith <r...@panix.com> wrote:
> 
> Hmmm.  What I'm doing requires Page.expand_text(), which looks like it does a 
> Page.get() followed by a Site.expand_text(), and it's the later which 
> actually takes most of the time.  That becomes an action=expandtemplates API 
> call 
> <https://www.mediawiki.org/w/api.php?action=help&modules=expandtemplates>, 
> which I don't see any way to batch.
> 
> 
> 
> 
> <Screen Shot 2023-03-28 at 1.55.55 PM.png>
> 
>> On Mar 28, 2023, at 1:04 PM, Kunal Mehta <lego...@debian.org 
>> <mailto:lego...@debian.org>> wrote:
>> 
>> Hi,
>> 
>> On 3/27/23 15:57, Roy Smith wrote:
>>> I need to issue a bunch of Page.get() requests in parallel. 
>> 
>> Please don't. From 
>> <https://www.mediawiki.org/wiki/API:Etiquette#Request_limit 
>> <https://www.mediawiki.org/wiki/API:Etiquette#Request_limit>>:
>> 
>> "Making your requests in series rather than in parallel, by waiting for one 
>> request to finish before sending a new request, should result in a safe 
>> request rate."
>> 
>> Instead of making parallel requests, you should make batched requests, which 
>> is how the preloading stuff Xqt mentioned works.
>> 
>> -- Kunal / Legoktm
>> _______________________________________________
>> pywikibot mailing list -- pywikibot@lists.wikimedia.org 
>> <mailto:pywikibot@lists.wikimedia.org>
>> Public archives at 
>> https://lists.wikimedia.org/hyperkitty/list/pywikibot@lists.wikimedia.org/message/RXANREWJYNQ3AI2MDU4K4WR67D5W4KCH/
>>  
>> <https://lists.wikimedia.org/hyperkitty/list/pywikibot@lists.wikimedia.org/message/RXANREWJYNQ3AI2MDU4K4WR67D5W4KCH/>
>> To unsubscribe send an email to pywikibot-le...@lists.wikimedia.org 
>> <mailto:pywikibot-le...@lists.wikimedia.org>
>> 
> 

_______________________________________________
pywikibot mailing list -- pywikibot@lists.wikimedia.org
Public archives at 
https://lists.wikimedia.org/hyperkitty/list/pywikibot@lists.wikimedia.org/message/BAMF4HHIKC3FNQHM56L4PUOBY25R2J3M/
To unsubscribe send an email to pywikibot-le...@lists.wikimedia.org

Reply via email to