zulip/zerver
Rohitt Vashishtha 98f8d94b25 linkifiers: Add joint validation for linkifier urls and patterns.
We now validate the linkifier urls and patterns together, and add
the following additional checks:

1. All groups in the pattern must be used in the URL format string.
2. All groups in the URL format string must be declared in the pattern.

Linkifier pattern is now validated inside the `clean` method.
`filter_pattern_validator` is moved from `clean_fields` to `clean`
method as a safe check. As a result of this, a Puppeteer test case
is updated.

NOTE: The changes here are IN ADDITION to the existing validations.

Fixes #16482.

Co-authored-by: akshatdalton <akshat.dak@students.iiit.ac.in>
2021-06-16 17:51:33 -07:00
..
data_import data_import: Protect better against bad Slack tokens. 2021-05-27 22:46:58 -07:00
integration_fixtures/nagios tests: Add a test for fixtures for non-webhook integrations. 2021-04-28 08:16:51 -07:00
lib tests: Exclude another redirect from URL testing. 2021-06-16 16:25:49 -07:00
management python: Simplify stdio flushing using print(…, flush=True). 2021-06-09 14:05:31 -07:00
migrations linkifiers: Add joint validation for linkifier urls and patterns. 2021-06-16 17:51:33 -07:00
openapi settings: Add moderators and members options in edit_topic_policy. 2021-06-16 15:04:29 -07:00
tests linkifiers: Add joint validation for linkifier urls and patterns. 2021-06-16 17:51:33 -07:00
tornado process_message_event: Always calculate `online_push_enabled`. 2021-06-15 12:30:31 -07:00
views models: Replace allow_community_topic_editing with edit_topic_policy. 2021-06-16 14:59:36 -07:00
webhooks refactor: Convert `clean-unused-caches` to`clean_unused_caches.py`. 2021-06-12 07:28:16 -07:00
worker queue_processors: Log more detailed info when marking messages as read. 2021-05-26 11:17:21 -07:00
__init__.py django: Upgrade Zulip to Django 3.2 LTS. 2021-05-03 08:36:22 -07:00
apps.py python: Reformat with Black, except quotes. 2021-02-12 13:11:19 -08:00
context_processors.py context_processors: Add test for `get_apps_page_url`. 2021-06-16 07:49:03 -07:00
decorator.py web_public_view: Replace `web_public_visitor` with `spectator`. 2021-06-16 07:46:34 -07:00
filters.py python: Normalize quotes with Black. 2021-02-12 13:11:19 -08:00
forms.py billing: Enforce license limit for plans on manual license management. 2021-06-09 17:42:38 -07:00
logging_handlers.py docs: Capitalize “Markdown” consistently. 2021-04-26 09:31:08 -07:00
middleware.py docs: Fix capitalization mistakes. 2021-05-10 09:57:26 -07:00
models.py linkifiers: Add joint validation for linkifier urls and patterns. 2021-06-16 17:51:33 -07:00
signals.py python: Convert deprecated Django ugettext alias to gettext. 2021-04-15 18:01:34 -07:00