Skip to content

Handle rendering errors from reStructuredText

What does this MR do and why?

Contributes to #385712 (closed)

Sentry error: https://new-sentry.gitlab.net/organizations/gitlab/issues/1594

Problem

Unlike other renderers 'reStructuredText' can raise an exception if the context does not follow the required structure.

Solution

Use a simpler renderer instead of raising 500 error.

Screenshots or screen recordings

Before After
Screenshot_2023-02-15_at_20.51.24 Screenshot_2023-02-15_at_20.45.49

How to set up and validate locally

  1. Create file test.rst with invalid content
####
PART
##
  1. Try to open this file

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Edited by Vasilii Iakliushin

Merge request reports

Loading