When exporting to html or html embed the equation numbering and references are lost

Hello all.

In jupyter lab I manage to get equation numbering with the code:

    TeX: { equationNumbers: { autoNumber: "AMS" } }
  ["resetEquationNumbers", MathJax.InputJax.TeX],
  ["PreProcess", MathJax.Hub],
  ["Reprocess", MathJax.Hub]

In the traditional notebook such code is not necessary, the equation numbering extension works just fine.
However, when I export the notebook to html or embedded html all the equation numbers are missing, and the references appear unknown.

I have tried exporting from the jupyter menu and also from command line using this script:

# -*- coding: UTF-8 -*-

import os
import sys

name= sys.argv[1]
command="jupyter nbconvert --no-prompt --to html_embed"
command +=""" {} --TagRemovePreprocessor.remove_input_tags='["hide-input"]'"""
command= command.format(name)

What am I missing?

Well, I just upgrade to the latest version of jupyter and nbconvert and now works just fine.