Code to run the Python MediaWiki bot.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
jenkins-bot 36d21af5a0 Merge "[IMPR] Improvements for askForHints (3)" 7 months ago
docs [doc] Prepare next release 10 months ago
pywikibot Merge "[tests] Use assert_valid_iter_params for Site.blocks()" 7 months ago
scripts Merge "[IMPR] Improvements for askForHints (3)" 7 months ago
tests Merge "[tests] Use assert_valid_iter_params for Site.blocks()" 7 months ago
.appveyor.yml Merge "[tests] Remove 32-bit-tests for Python 2.7.4 and 3.4.1" 10 months ago
.codeclimate.yml [tests] Fix similar code checking in codeclimate 1 year ago
.codecov.yml [tests] remove from coverage 1 year ago
.coveragerc Add .coveragerc and codecov.yml 4 years ago
.gitignore Add .vscode in .gitignore 1 year ago
.gitmodules Fix url for .gitmodules 2 years ago
.gitreview Add .gitreview file for git migration 6 years ago
.svnprops update .svnprops 4 years ago
.travis.yml [tests] Update Travis tests configuration 1 year ago
CODE_OF_CONDUCT.rst [doc] use reStructuredText instead of markdown 2 years ago
CONTENT.rst [cleanup] Remove deprecated 1 year ago
CREDITS [bugfix] Remove link to /edithistory from page's edithistory summary. 1 year ago
ChangeLog Update ChangeLog for release 3.0.20170713 2 years ago
Dockerfile Install dev-requirements.txt into Docker image 4 years ago
HISTORY.rst [doc] Update HISTORY.rst 8 months ago
LICENSE [doc] Update licence 1 year ago
README-conversion.txt [cleanup] Nothing left to do for a deprecated method 10 months ago
README.rst [doc] Add Python version shield to README.rst 1 year ago
dev-requirements.txt [lib] werkzeug 0.15.5 was published 9 months ago [cleanup] Simpliy generate_family_file.getlangs 1 year ago [PY3] Make Python 2 more Python 3 compatible 10 months ago Merge "[IMPR] Enable global args with script" 9 months ago
requests-requirements.txt [IMPR] Reduce deprecated stuff in requests-requirements.txt 11 months ago
requirements.txt Merge "[bugfix] Drop library part" 1 year ago [tests] Add 'eventstreams' requirement to test_deps 8 months ago
tox.ini Merge "[cleanup] Put fandom defaults into FandomFamily" 8 months ago [doc] remove duplicate spaces inside doc strings 3 years ago Import unicode_literals in 3 years ago


.. image::
:alt: Travis Build Status
.. image::
:alt: AppVeyor Build Status
.. image::
:alt: Code coverage
.. image::
:alt: Maintainability
.. image::
:alt: Python
.. image::
:alt: Pywikibot release


The Pywikibot framework is a Python library that interfaces with the
`MediaWiki API <>`_
version 1.14 or higher.

Also included are various general function scripts that can be adapted for
different tasks.

For further information about the library excluding scripts see
the full `code documentation <>`_.

Quick start


git clone
cd core
git submodule update --init
python script_name

Or to install using PyPI (excluding scripts)

pip install -U setuptools
pip install pywikibot

Our `installation
guide <>`_
has more details for advanced usage.

Basic Usage

If you wish to write your own script it's very easy to get started:


import pywikibot
site = pywikibot.Site('en', 'wikipedia') # The site we want to run our bot on
page = pywikibot.Page(site, 'Wikipedia:Sandbox')
page.text = page.text.replace('foo', 'bar')'Replacing "foo" with "bar"') # Saves the page


For more documentation on pywikibot see our `docs <>`_.

.. include:: pywikibot/DIRECTORIES.rst

Required external programs

It may require the following programs to function properly:

* `7za`: To extract 7z files

.. include:: HISTORY.rst


Our code is maintained on Wikimedia's `Gerrit installation <>`_,
`learn <>`_ how to get

.. include:: CODE_OF_CONDUCT.rst