I'm trying to use titlesec with LyX 2.2.2. When I add this line:


to my LaTeX preamble then run LaTeX I get this error:

Missing \endgroup inserted.

followed by complaints about missing }'s

The document class is Report (Standard class) and I have nothing selected in the Modules pane of the LyX settings. The preamble consists of just \usepackage{titlesec} and the entire document is just a title and a table. The error occurs only if \usepackage{titlesec} is in the preamble. Screenshots of the complete document, the preamble in Settings, and the error message follow. Document window LaTeX preamble enter image description here

  • Can you add a complete preamble (MWE), please? – Sebastiano Mar 20 '17 at 8:07
  • Load titlesec per se cannot produce any error in a simple article like \section{xx} foo so you must show what your are doing wrong. The way to do this is make a minimal working example (MWE). – Fran Mar 20 '17 at 8:12
  • I've updated the question with details of the minimal example to reproduce the error. – Clyde Mar 20 '17 at 22:23
  • @Clyde please add a minimal example .lyx file. Please read this LyX-specific page for an MWE. – scottkosty Mar 20 '17 at 23:26

Obviously there's more than what you described. Your caption is in Paragraph* formatting. Check what's in View>Source. The relevant part should read



  • Ok, thanks. When I originally added the table it was in Paragraph formatting, no idea why, that's just what LyX did. I changed it to Paragraph* but that had no effect. The error message didn't exactly point me in the right direction. – Clyde Mar 23 '17 at 2:01
  • Everything within the float:Table should be in "Plain Layout". I wonder why you ever had it as Paragraph. – PhilipPirrip Mar 23 '17 at 2:11

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.