Thanks to visit codestin.com
Credit goes to github.com

Skip to content

[Bug]: New plot directive error in 3.5.0 #21668

Closed
@dstansby

Description

@dstansby

Bug summary

In sunpy we have a doctest that is inside a plot directive, that also has some doctest flags, in particular doctest: +REMOTE_DATA. Building the docs with matplotlib 3.4.3 works fine, but with 3.5.0 it fails.

Code for reproduction

.. plot::
   :include-source:

   sunpy Map uses coordinates to specify locations on the image, and to plot
   overlays on plots of maps. When a Map is created, a coordinate frame is
   constructed from the header information. This can be accessed using
   ``.coordinate_frame``:

   >>> import sunpy.map
   >>> from sunpy.data.sample import AIA_171_IMAGE   # doctest: +REMOTE_DATA
   >>> m = sunpy.map.Map(AIA_171_IMAGE)  # doctest: +REMOTE_DATA

Actual outcome

/Users/dstansby/github/sunpy/docs/guide/units-coordinates.rst:200: WARNING: line 7 of the doctest for <string> has an invalid option: '+REMOTE_DATA'

Expected outcome

No warning raised.

Additional information

No response

Operating system

macOS

Matplotlib Version

3.5.0

Matplotlib Backend

No response

Python version

3.9.6

Jupyter version

No response

Installation

pip

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions