Black Lives Matter. Please consider donating to Black Girls Code today.

Plotly graphs are not showing up anymore in Jupyter notebook when running from command line

I am running a jupyter notebook from command line.
jupyter nbconvert --execute --to notebook --inplace <name>
MY jupyter version is this :

jupyter core : 4.5.0
jupyter-notebook : 6.0.1
qtconsole : 4.5.5
ipython : 7.8.0
ipykernel : 5.1.2
jupyter client : 5.3.1
jupyter lab : not installed
nbconvert : 5.6.0
ipywidgets : 7.5.1
nbformat : 4.4.0

After running when I see the output, it shows me nothing:
Screenshot from 2020-03-31 16-57-05

This is how i imported libraries. and my ployly version is 4.1.1'

# Import the necessaries libraries
import plotly
import plotly.offline as pyo
import plotly.graph_objs as go

from IPython import get_ipython
import IPython.core.display
import termcolor
import pandas as pd
import numpy as np
import matplotlib.pyplot as plt
import seaborn as sns
import plotly.graph_objects as go
from plotly.subplots import make_subplots
from IPython.core.display import display, HTML

%matplotlib inline
display(HTML("<style>.container { width:90% !important; }</style>"))
pyo.init_notebook_mode()

I did a little debugging
Screenshot from 2020-04-06 14-52-37
The red part is executed within the notebook/or from browser, where as the green part is executed with commandline tool. It can’t add the JS if we run from commandline. How can we force it to add JS script ?