betty.extension.wikipedia package - Betty 0.4.0a1 documentation

Hide navigation sidebar
Hide table of contents sidebar
Skip to content
Back to top
View this page
Toggle table of contents sidebar

# betty.extension.wikipedia package

## Submodules

- betty.extension.wikipedia.config module
  - `WikipediaConfiguration`
    - `WikipediaConfiguration.__init__()`
    - `WikipediaConfiguration.dump()`
    - `WikipediaConfiguration.load()`
    - `WikipediaConfiguration.populate_images`
    - `WikipediaConfiguration.update()`
- betty.extension.wikipedia.gui module

## Module contents

Integrate Betty with Wikipedia.

class betty.extension.wikipedia.Wikipedia

  Bases: `ConfigurableExtension`[`WikipediaConfiguration`], `UserFacingExtension`, `Jinja2Provider`, `PostLoader`, `GuiBuilder`

  Integrates Betty with Wikipedia.

  Parameters:

    - args (`typing.Any`)

    - kwargs (`typing.Any`)

  __init__(*args: Any, **kwargs: Any)
    Parameters:

      - args (`typing.Any`)

      - kwargs (`typing.Any`)

  classmethod assets_directory_path() → pathlib.Path | None

    Return the path on disk where the extension’s assets are located.

    This may be anywhere in your Python package.

    Return type:

      `pathlib.Path` | `None`

  classmethod default_configuration() → betty.extension.wikipedia.config.WikipediaConfiguration

    Get this extension’s default configuration.

    Return type:

      `betty.extension.wikipedia.config.WikipediaConfiguration`

  classmethod description() → betty.locale.Localizable

    Get the human-readable extension description.

    Return type:

      `betty.locale.Localizable`

  property filters: dict[str, Callable[[...], Any]]

    Jinja2 filters provided by this extension.

    Keys are filter names, and values are the filters themselves.

  gui_build() → betty.extension.wikipedia.gui._WikipediaGuiWidget

    Build this extension’s Graphical User Interface component.

    Return type:

      `betty.extension.wikipedia.gui._WikipediaGuiWidget`

  classmethod label() → betty.locale.Localizable

    Get the human-readable extension label.

    Return type:

      `betty.locale.Localizable`

  classmethod name() → str

    The machine name.

    Return type:

      `str`

  async post_load() → None

    Act on the ancestry having been loaded.

    This method is called immediately after `betty.load.Loader.load()`.

    Return type:

      `None`