Working with patrol.py script..

Here, I have described a sum up of the different suggestions and guidelines I had been directed for porting..

Dependencies : patrol.py is dependent on mwlib.uparser ..

Basic in general guidelines:

  • Do the scripting according to pep8 , pep257 , flake8 and pyflakes guidelines..
  • Make minute changes based on the present version, date, author etc.. details.
  • Retain it’s functionality based on the pywikibot module.

Specific to patrol.py :

  • .verbose issue to be replaced by .config.verbose_output
  • Became familiar with site.py functions meant for patrolling (patrol).
  • I needed to prepare patrol whitelists for testing purpose on test.wikipedia, wikisource and mediawiki (for future reference) using list .
  • On testing, I encountered “pywikibot.data.api.APIError: permissiondenied: Permission denied” error which meant to get additional rights to patrol as per instructions been provided here.
  • From this, I came to know about Patrol permission right given to specific users. So, I needed to generate request here.
  • Once received the rights, proper testing is done in conventional way i.e. using : “python pwb.py scripts/patrol.py -family:’test’ -lang:’test'”
  • Finally it seems to work as I received expected output : here.

Leave a comment