I am trying to display a plotly figure, and streamlit.plotly_chart is not displaying it correctly. When I include fig.show() at the end of my script, it appears correctly in a new window, so I know it is not a problem with the figure itself. Attached are images of how it appears from fig.show() vs from st.plotly_chart(fig)
fig.show():
st.plotly_chart(fig)
The figure is simple a bar chart with a horizontal line added:
Any help is much appreciated