betty.wikipedia package

Submodules

Module contents

Fetch information from Wikipedia.

exception betty.wikipedia.NotAPageError[source]

Bases: ValueError

Raised when a URL does not point to a Wikipedia page.

betty.wikipedia.parse_page_url(url: str) tuple[str, str][source]

Parse the URL for a Wikipedia page.

Returns:

A 2-tuple with the page language and the page name.