diff --git a/IPython/nbconvert/templates/rst.tpl b/IPython/nbconvert/templates/rst.tpl index fdabe2a..1dc7f69 100644 --- a/IPython/nbconvert/templates/rst.tpl +++ b/IPython/nbconvert/templates/rst.tpl @@ -8,7 +8,7 @@ {% endblock output_prompt %} {% block input %} -{%- if not cell.input.isspace() -%} +{%- if cell.input.strip() -%} .. code:: python {{ cell.input | indent}}