'Given the lines of a source string (including prompts and
leading indentation), check to make sure that every prompt is
followed by a space character.  If any line is not followed by
a space character, then raise ValueError.
Note: IPython-modified version which takes the input prompt length as a
parameter, so that prompts of variable length can be dealt with.'

def _check_prompt_blank(self, lines, indent, name, lineno, ps1_len):

    space_idx = (indent + ps1_len)
    min_len = (space_idx + 1)
    for (i, line) in enumerate(lines):
        if ((len(line) >= min_len) and (line[space_idx] != '    ')):
            raise ValueError(('line    %r    of    the    docstring    for    %s    lacks    blank    after    %s:    %r' % (((lineno + i) + 1), name, line[indent:space_idx], line)))
