Skip to content

inequality: the plotly figure (fig:plotly-gini-gdppc-years) renders nothing on the website #871

Open

Description

@mmcky

The plotly figure in inequality.md (fig:plotly-gini-gdppc-years, lectures/inequality.md:767–:776) renders nothing on the website. On https://intro.quantecon.org/inequality.html the cell's output is empty (checked 2026-11-15).

Why. plotly 6's default renderer in a Jupyter kernel emits only application/vnd.plotly.v1+json. myst-nb has no renderer for that mimetype, so it drops the output with a mystnb.unknown_mime_type warning. lectures/_config.yml:79 suppresses that warning, and the build passes without a word.

The rm -r _build/.doctrees step in publish.yml plays no part in this: the figure is missing with or without it (QuantEcon/actions#98, where this was found).

Options

  • fig.show(renderer="notebook_connected"), which emits text/html. The Reorganize table of contents #98 repro's test page renders a figure this way, in every build.
  • Setting plotly.io.renderers.default once in the lecture, before the figure.
  • Either way, dropping mystnb.unknown_mime_type from suppress_warnings would turn the next such drop into a warning rather than a silent gap. Other pages may rely on that suppression, though.

Claude Code (on behalf of mmcky)

Activity

  1. added
    bug
    on Nov 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bug

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions