Skip to content

Navigation Menu

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

[Doc]: clarify when and how to use boilerplate.py #27190

Copy link
Copy link
Open
@story645

Description

@story645
Issue body actions

Documentation Link

No response

Problem

Per this discussion #27158 (comment), I (maybe other folk) are a bit confused on what the "do not edit" comments in pyplot mean given that boilerplate.py is never run automatically. Consensus seems to be that the process should be when changing the signature of a pyplot function, run boilerplate.py and commit those changes but that's not documented anywhere.

Suggested improvement

More clearly document using boilerplate.py by:

  1. changing the Autogen message to "generated by biolerplate.py, do not edit"
    AUTOGEN_MSG = """
    # Autogenerated by boilerplate.py. Do not edit as changes will be lost."""
  2. change the comment at the top of pyplot to something like "plotting signatures are generated by boilerplate.py, rerun when changing signatures and commit the changes
    # Note: The first part of this file can be modified in place, but the latter
    # part is autogenerated by the boilerplate.py script.
  3. add something like (note: this rst may be incorrect) to the coding guideline.
When a function in the :doc:`pyplot  API<doc/api/pyplot_summary>`, run :file:`lib/matplotlib/test_pyplot.py::test_pyplot_up_to_date`. If the test fails and and you intended to change those signatures, run boilerplate.py and commit the changes

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      Morty Proxy This is a proxified and sanitized view of the page, visit original site.