Page MenuHomePhabricator

pywikibot sleep
Closed, InvalidPublic

Description

I use Pywikibot-core to add description to wikidata but the sleep time is take long than one min every edit,
Sleeping for 67.8 seconds.
some time i get multi-sleep between every edit, is there something can be done to get rid of this?

Event Timeline

Jar triaged this task as Medium priority.Jul 13 2017, 7:23 PM
Jar added projects: Pywikibot, Wikidata.
Jar updated the task description. (Show Details)

Have you tried adding parameter -pt:xx where xx is the number of seconds between two edits?

Have you tried adding parameter -pt:xx where xx is the number of seconds between two edits?

Unrelated for this my comment. @Mpaa Thank you for help.

But -pt: is to force the sleep to a value. It's not normal to have this long timer.
@Jar It's only append on wikidata or on wikipedia too ?

zhuyifei1999 subscribed.

I bet too many instances of the bot are running.

Aklapper raised the priority of this task from Medium to Needs Triage.Jul 14 2017, 9:42 AM

Has this been discussed in a support forum already? If so, could you link to it?
I do not see a bug here (yet), and Phabricator is for bug reports and enhancement requests...

Xqt closed this task as Declined.EditedJul 14 2017, 10:07 AM
Xqt subscribed.

Most of this throttleling might be caused by the server maxlag lagtime which means the server is too busy. You may refer the log where you could find the corresponding message "Pausing due to database lag: ". The default value is 5 seconds. This could be overwritten by the -maxlag option but you shouldn't (without a very good reason) because this would priorize your request and impair other bots and increase the server lag further.

There is another thread in T144023 to use the retry-after value which gives a more accureate delay instead of just increasing the wait time.
The patch is ready but only tests fails due to some obsure test patches and I haven't found the trick yet. Maybe that patch may help for this issue.

Anyway it is required to throttle down bot action when server has a lagtime.

Xqt changed the task status from Declined to Invalid.Jul 14 2017, 10:57 AM