Originally Posted by st_albert
My first guess would be that Calibre is doing this. It may be seeing the <h2> and/or <h3> tags and trying to make pagebreaks before them.
That's the only guess necessary.
@OP: Check your structure detection settings in calibre's conversion dialog. Something in your toc's (x)html is matching the "Detect chapters at" xpath expression and the "Chapter mark" combo is set to "pagebreak." That's where the problem lies.
I've had that fool me so many times I've lost count. It's not Sigil, trust me.
If you have your chapter breaks exactly how you want them in your epub, just disable calibre's chapter detection by changing the "Detect chapters at" xpath expression to "/" (without the quotes of course).