I'm trying to place section headers in a column on the left with the content in another column on the right. I found a a question with exactly that, however there's one problem with the solution. If a section begins with a subsection, there's a space before the subsection, preventing the section header and the section content (the subsection) from aligning vertically. I can't seem to fix this in either solution presented in the other question. Can anyone help figure this out please?
\documentclass[a4paper]{article}
\usepackage[showframe]{geometry}
\usepackage{titlesec}
\usepackage{lipsum}
\geometry{left=6cm,right=3cm} % 3cm for the sections
\titleformat{\section}[leftmargin]
{\normalfont\bfseries\filright}
{\thesection}
{1em}
{}
\titlespacing*{\section}
{3cm}
{2ex plus .2ex minus .2ex}
{1sp}% should be 0, but it must be positive
\begin{document}
\lipsum[2]
\section{A title}
\subsection{A subsection}
\lipsum[3]
\section{A very very very very very long title}
\lipsum[3]
\end{document}

\titlespacing*{\subsection}{0pt}{0pt}{0.5cm}– Michael Fraiman Jun 26 '17 at 21:24\subsectionis that subsequent calls will have wrong spacing. So a solution should only modify the first one after each\section. – siracusa Jun 27 '17 at 05:32