Here I found a similar question with horizontal rule, which answer I don't understand to a degree I could use it to solve my problem:
Adding a horizontal rule between caption and lstlisting inside a tcolorbox
I am looking for a separator rule for line numbers when the frame rule has already been extended to include the line numbers (Would be nice if it was possible with just the listings package). See this example:
Listings: recognize numbers and `1e-3`

Minimal working example:
\documentclass{report}
\usepackage{xcolor}
\definecolor{halfgray}{gray}{0.55}
\definecolor{ipython_frame}{RGB}{207, 207, 207}
\usepackage{listings}
\lstdefinelanguage{iPython}{
commentstyle=\color{cyan}\ttfamily,
stringstyle=\color{red}\ttfamily,
keepspaces=true,
showspaces=false,
showstringspaces=false,
%
rulecolor=\color{ipython_frame},
frame=single,
frameround={t}{t}{t}{t},
framexleftmargin=6mm,
numbers=left,
numberstyle=\tiny\color{halfgray},
%
basicstyle=\scriptsize\ttfamily,
keywordstyle=\color{green}\ttfamily,
}
\begin{document}
\begin{lstlisting}[language=iPython]
import math
import numpy as np
from lib.analytical import csa
sin2_theta = np.sin(theta)**2
+= -= *= /= + - * / ? < > & % == <=
# += -= *= /= + - * / ? < > & % == <=
def test(a=100, b=True):
<= >= == 2 + 3j * 7e-3
\end{lstlisting}
\end{document}

\documentclass{...}and ending with\end{document}. – jub0bs Mar 30 '15 at 01:101e-3. I added the words "minimal working" so it might become more of an eye-catcher. – BadAtLaTeX Mar 30 '15 at 09:31frame=leftlinewould overwrite these settings. – BadAtLaTeX Mar 30 '15 at 13:38