Wagtail is an open source content management system built on Django
 
 
 
 
 
Go to file
Matt Westcott bf870cecd3 Gracefully handle document links with missing ID attributes in rich text
Fixes #4791
Previously, our rich text conversion functions handled the case where a document link specified an ID which is not found in the database. However, they failed with a KeyError when the id attribute was missing completely; links of this second type would occur whenever a link of the first type was re-saved from the Draftail editor. The fix is two-fold:

1) Catch the "missing ID attribute" case - in this case, the resulting link will be missing both the href and id attributes
2) Update the handling of the "ID present but document not found" case so that the id attribute survives the round-trip to the editor and back. The final link as rendered on the front-end will still be an attribute-less <a> element, but the id will be retained in the database (and in the versions rendered within rich text editors) which may be useful for troubleshooting.
2018-10-10 12:54:52 +01:00
.circleci Specify file-based sqlite db for circleci 2018-08-21 17:17:04 +01:00
.github Ask issue openers to confirm that bugs are reproducible 2018-08-16 16:03:46 +01:00
.tx Fetch new translations from Transifex 2018-05-04 20:29:48 +01:00
client Only render tooltip link if there is a label for it 2018-10-07 22:27:51 +03:00
docs Gracefully handle document links with missing ID attributes in rich text 2018-10-10 12:54:52 +01:00
etc Fixed spelling error in uwsgi.conf.sample 2017-11-27 13:08:42 +01:00
gulpfile.js Convert the search query chooser to use static onload handlers 2018-06-20 15:35:40 +01:00
scripts Travis/tox configuration for Elasticsearch 6 2018-05-04 15:57:36 +01:00
wagtail Gracefully handle document links with missing ID attributes in rich text 2018-10-10 12:54:52 +01:00
.coveragerc
.editorconfig
.eslintignore Convert the document chooser modal to use static onload handlers 2018-06-20 15:35:41 +01:00
.eslintrc
.gitignore Add pytest cache directories to gitignore 2018-04-08 06:58:19 +02:00
.nvmrc
.stylelintrc.yaml Ignore build folder for CSS linting (#4264) 2018-02-10 01:39:44 +02:00
.travis.yml Trim down Travis test matrix 2018-08-14 15:17:26 +01:00
CHANGELOG.txt Gracefully handle document links with missing ID attributes in rich text 2018-10-10 12:54:52 +01:00
CODE_OF_CONDUCT.md
CONTRIBUTORS.rst missing quotation, not that it matters 2018-09-13 13:00:57 +01:00
LICENSE
MANIFEST.in README rewrite (#4372) 2018-06-28 17:27:55 +01:00
Makefile
README.md Update documentation to indicate Django 2.1 support 2018-08-09 00:34:38 +01:00
appveyor.yml
codecov.yml
conftest.py
package-lock.json Security audit of npm packages (#4709) 2018-08-08 01:43:58 +03:00
package.json Security audit of npm packages (#4709) 2018-08-08 01:43:58 +03:00
runtests.py Add rudimentary benchmarking code and a couple of benchmarks 2018-06-11 17:49:31 +01:00
setup.cfg Exclude wagtail/utils/l18n from linting 2018-08-06 12:39:45 +01:00
setup.py Update dependencies to include Django 2.1 2018-08-14 14:11:39 +01:00
tox.ini Specify file-based sqlite db in tox 2018-08-21 17:17:03 +01:00

README.md

Wagtail

Wagtail is an open source content management system built on Django, with a strong community and commercial support. It's focused on user experience, and offers precise control for designers and developers.

Wagtail screenshot

Features

  • A fast, attractive interface for authors
  • Complete control over front-end design and structure
  • Scales to millions of pages and thousands of editors
  • Fast out of the box, cache-friendly when you need it
  • Content API for 'headless' sites with de-coupled front-end
  • Runs on a Raspberry Pi or a multi-datacenter cloud platform
  • StreamField encourages flexible content without compromising structure
  • Powerful, integrated search, using Elasticsearch or PostgreSQL
  • Excellent support for images and embedded content
  • Multi-site and multi-language ready
  • Embraces and extends Django

Find out more at wagtail.io.

Getting started

Wagtail works with Python 3, on any platform.

    pip install wagtail
    wagtail start mysite
    cd mysite
    python manage.py migrate
    python manage.py createsuperuser
    python manage.py runserver

For detailed installation and setup docs, see docs.wagtail.io.

Whos using it?

Wagtail is used by NASA, Google, Oxfam, the NHS, Mozilla, MIT, the Red Cross, Salesforce, NBC, BMW, and the US and UK governments. Add your own Wagtail site to madewithwagtail.org.

Documentation

docs.wagtail.io is the full reference for Wagtail, and includes guides for developers, designers and editors, alongside release notes and our roadmap.

Compatibility

Wagtail supports:

  • Django 1.11.x, 2.0.x and 2.1.x
  • Python 3.4, 3.5 and 3.6
  • PostgreSQL, MySQL and SQLite as database backends

Previous versions of Wagtail (1.13 and earlier) additionally supported Python 2.7.


Community Support

There is an active community of Wagtail users and developers responding to questions on Stack Overflow. When posting questions, please read Stack Overflow's advice on how to ask questions and remember to tag your question "wagtail".

For topics and discussions that do not fit Stack Overflow's question and answer format, we have a Slack workspace and a Wagtail Support mailing list. Please respect the time and effort of volunteers by not asking the same question in multiple places.

We maintain a curated list of third party packages, articles and other resources at Awesome Wagtail.

Commercial Support

Wagtail is sponsored by Torchbox. If you need help implementing or hosting Wagtail, please contact us: hello@torchbox.com. See also madewithwagtail.org/developers/ for expert Wagtail developers around the world.

Contributing

If you're a Python or Django developer, fork the repo and get stuck in! We run a separate group for developers of Wagtail itself at https://groups.google.com/forum/#!forum/wagtail-developers (please note that this is not for support requests).

You might like to start by reviewing the contributing guidelines and checking issues with the good first issue label.

We also welcome translations for Wagtail's interface. Translation work should be submitted through Transifex.

Thanks

We thank BrowserStack, who provide the project with free access to their live web-based browser testing tool, and automated Selenium cloud testing.

Browserstack

Build Status License Version Coverage Slack