File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -105,6 +105,7 @@ RST214 Inline literal start-string without end-string.
105105RST215 Inline interpreted text or phrase reference start-string without end-string.
106106RST216 Multiple roles in interpreted text (both prefix and suffix present; only one allowed).
107107RST217 Mismatch: both interpreted text role suffix and reference suffix.
108+ RST218 Literal block expected; none found.
108109RST299 Previously unseen warning, not yet assigned a unique code.
109110====== =======================================================================
110111
@@ -218,6 +219,7 @@ Version History
218219======= ========== ===========================================================
219220Version Released Changes
220221------- ---------- -----------------------------------------------------------
222+ v0.0.13 2019-12-26 - Adds ``RST218 ``.
221223v0.0.12 2019-11-18 - Adds ``RST213 `` to ``RST217 ``.
222224v0.0.11 2019-08-07 - Configuration options to define additional directives and
223225 roles (e.g. from Sphinx) for ``RST303 `` and ``RST304 ``.
Original file line number Diff line number Diff line change @@ -176,6 +176,7 @@ def tokenize_open(filename):
176176 "Inline interpreted text or phrase reference start-string without end-string." : 15 ,
177177 "Multiple roles in interpreted text (both prefix and suffix present; only one allowed)." : 16 , # noqa: E501
178178 "Mismatch: both interpreted text role suffix and reference suffix." : 17 ,
179+ "Literal block expected; none found." : 18 ,
179180}
180181
181182# Level 3 - error
Original file line number Diff line number Diff line change 1+ """Print 'Hello world' to the terminal.
2+
3+ RST uses double colons to indicate the following
4+ indented text is a literal block. The following
5+ code snippet is a typical usage::
6+
7+ $ flake8 --select RST RST218/no_literal_block.py
8+ RST218/no_literal_block.py:14:1: RST218 Literal block expected; none found.
9+
10+ This file triggers an error because this paragraph
11+ says there should be a following literal block, but
12+ there is none::
13+ """
14+
15+ print ("Hello world" )
You can’t perform that action at this time.
0 commit comments