I am auto-generating a LaTeX document. The input data can possibly generate empty data, so that I am left with something like this in the generated TeX source:
\begin{itemize}
\end{itemize}
This leads to lualatex complaining when compiling (of course):
Misplaced \item
Is there a way to make it ignore any empty list (no \item) silently?
For clarification: I do have a lot of itemize lists in the document and some can be empty depending on my data. I know I could filter that before generation, but that would be more cumbersome than a potential LaTeX solution.

enumitempackage, so the full error reads! Package enumitem Error: Misplaced \item.in my case, but it is a general TeX problem, right? – jœ. Oct 05 '19 at 12:26