You're Invited:Meet the Socket Team at BlackHat and DEF CON in Las Vegas, Aug 4-6.RSVP
Socket
Book a DemoInstallSign in
Socket

wagtail-localize

Package Overview
Dependencies
Maintainers
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

wagtail-localize

Translation plugin for Wagtail CMS

1.12.2
Source
pipPyPI
Maintainers
4

Wagtail localize

Version License codecov Ruff pre-commit.ci status

Wagtail Localize is a translation plugin for the Wagtail CMS. It allows pages or snippets to be translated within Wagtail's admin interface. It also provides integrations with external translations services such as Pontoon or DeepL, and importing/exporting translations with PO files.

Documentation Changelog

Join the Community at Wagtail Space!

We'll be at Wagtail Space US this year! The Call for Participation and Registration for both Wagtail Space 2024 events is open. We would love to have you give a talk, or just us as an attendee in June.

  • Wagtail Space NL, Arnhem, The Netherlands. 2024-06-14
  • Wagtail Space US, Philadelphia, PA. 2024-06-20 to 2024-06-22

Requirements

Wagtail Localize requires the following:

  • Python (3.9, 3.10, 3.11, 3.12, 3.13)
  • Django (4.2, 5.1, 5.2)
  • Wagtail (5.2 - 7.0) with internationalisation enabled
  • wagtail-modeladmin if using wagtail_localize.modeladmin and Wagtail >= 5.2

Installation

Before you start, follow Wagtail's configuration guide to enable internationalisation in Wagtail and Django.

Install using pip:

pip install wagtail-localize

Add wagtail_localize and wagtail_localize.locales to your INSTALLED_APPS setting:

INSTALLED_APPS = [
    # ...
    "wagtail_localize",
    "wagtail_localize.locales",  # This replaces "wagtail.locales"
    # ...
]

wagtail-localize loads additional assets for the editing interface. Run the collectstatic management command to collect all the required assets.

python manage.py collectstatic

Contributing

All contributions are welcome!

Install

To make changes to this project, first clone this repository:

git clone git@github.com:wagtail/wagtail-localize.git
cd wagtail-localize

With your preferred virtualenv activated, install testing dependencies:

Using pip

pip install "pip>=21.3"
pip install -e '.[testing]' -U

Using flit

pip install "flit>=3.8.0"
flit install

pre-commit

Note that this project uses pre-commit. To set up locally:

# go to the project directory
$ cd wagtail-localize
# initialize pre-commit
$ pre-commit install

# Optional, run all checks once for this, then the checks will run only on the changed files
$ pre-commit run --all-files

How to run tests

Now you can run tests as shown below:

tox

or, you can run them for a specific environment tox -e python3.13-django5.2-wagtail7.0 or specific test tox -e python3.13-django5.2-wagtail7.0-sqlite -- wagtail_localize.tests.test_edit_translation.TestGetEditTranslationView

To run the test app interactively, use tox -e interactive, visit http://127.0.0.1:8020/admin/ and log in with admin/changeme.

Support

For support, please use GitHub Discussions or ask a question on the #multi-language channel on Wagtail's Slack instance.

Thanks

Many thanks to all of our supporters, contributors, and early adopters who helped with the initial release. In particular, to The Mozilla Foundation and Torchbox who sponsored the majority of the initial development and Wagtail core's internationalisation support.

FAQs

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts