mirror of https://github.com/zulip/zulip.git
8764e15599
The Slack text regexes match specific characters before and after the formatted string to prevent cases like reformatting already formatted text and test like `invlaid_bold_test` in `slack_message_conversion.json`. However, because the capture groups consume each matching character, two formatted strings separated by a single matching character result in one string not being matched, as the character is used to match the other string. e.g., (`*abc*b*def*` → **abc**b*def*) in this case, "b" is consumed to match *abc*. This prep commit modifies the Slack text regex in `slack_message_conversion.py` to use a non-greedy quantifier for the last capture group. |
||
---|---|---|
.. | ||
actions | ||
data_import | ||
integration_fixtures/nagios | ||
lib | ||
management | ||
migrations | ||
models | ||
openapi | ||
tests | ||
tornado | ||
transaction_tests | ||
views | ||
webhooks | ||
worker | ||
__init__.py | ||
apps.py | ||
context_processors.py | ||
decorator.py | ||
filters.py | ||
forms.py | ||
logging_handlers.py | ||
middleware.py | ||
signals.py |