Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

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

Sign up
Appearance settings

MNT: re-organize galleries under one subdir#25209

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
QuLogic merged 1 commit intomatplotlib:mainfromjklymak:mnt-reorg-galleries
Feb 24, 2023

Conversation

jklymak
Copy link
Member

@jklymakjklymak commentedFeb 14, 2023
edited
Loading

PR Summary

This reorganizes all the galleries (examples, tutorials, plot_types) under one subdirectory. Also renames examples->gallery so that it is the same name as the gallery it makes.

So now sphinx-gallery looks in/galleries/gallery,/galleries/tutorials/ and/galleries/plot_types.

The goal here is that now thatsphinx-gallery/sphinx-gallery#1071 is in, we may have more subdirectories run through sphinx gallery (perhaps many more), and it pollutes the top-level file hierarchy to have a bunch of these.

Note that no examples were changed by this, and there should be no difference on the doc page (except in the "writing Documentation" page where the file names have changed).

PR Checklist

Documentation and Tests

  • Has pytest style unit tests (andpytest passes)
  • Documentation is sphinx and numpydoc compliant (the docs shouldbuild without error).
  • New plotting related features are documented with examples.

Release Notes

  • New features are marked with a.. versionadded:: directive in the docstring and documented indoc/users/next_whats_new/
  • API changes are marked with a.. versionchanged:: directive in the docstring and documented indoc/api/next_api_changes/
  • Release notes conform with instructions innext_whats_new/README.rst ornext_api_changes/README.rst

files in :file:`plot_types/`, :file:`examples/` and :file:`tutorials/`.
These sources consist of python scripts that have ReST_ documentation built
into their comments. See :ref:`writing-examples-and-tutorials` below.
:file:`doc/tutorials` are generated by the `Sphinx Gallery`_ from python files
Copy link
MemberAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

This file is the only user-facing change.

@tacaswelltacaswell added this to thev3.8.0 milestoneFeb 14, 2023
@tacaswell
Copy link
Member

👍🏻 in principle.

@jklymakjklymakforce-pushed themnt-reorg-galleries branch 3 times, most recently from416364c to7fcc80aCompareFebruary 14, 2023 16:57
@jklymakjklymak marked this pull request as ready for reviewFebruary 14, 2023 17:29
@jklymakjklymak mentioned this pull requestFeb 14, 2023
6 tasks
@timhoffm
Copy link
Member

"examples" is a better name than "gallery", because it's more semantic (alsogalleries/Gallery is awkward). Can we go the other way and add a http redirect from gallery to example to preserve existing links working, so that we can use "example" consistently.

@jklymak
Copy link
MemberAuthor

The change here just makes the private name the same as the public. I'm not sure if there is a mechanism to change the public name. If there is, changing the private is just a one-line "git mv" and a few edit in the dev docs and the conf.py.

We could also keep the private and public names different (that was not really the point here) but I think it is needlessly confusing.

@timhoffm
Copy link
Member

We could also keep the private and public names different

Slight preference for doing this if you want to move forward without going into "changing the public name" right now. Having "gallery" as the internal name and url, but resulting in a page titled "Examples" which is under the menu entry "Examples" is still confusing. The only consistent naming option is all "examples".

@jklymak
Copy link
MemberAuthor

The structure is nowgalleries/examples ->doc/gallery. Redirectingdoc/gallery ->doc/examples via http redirect requires getting into the setup mechanisms for our web host

@ksunden
Copy link
Member

Unfortunately#25270 conflicted the animation examples (and a couple README's)... should be relatively trivial (probably for all of the animation ones at least it is the grammatical change fromgenerate togenerated on the note about the html viewer that was made on the backport.)

Also, am I misremembering the call? I thought the conclusion of that conversation was that we preferred the term "examples" over "gallery" for the repo paths (and desired doing redirects to make the url match as "examples", rather than its current "gallery", though I can acknowledge that much may be out of scope for now).

The extra level of heirarchy is fine, and I don't mind that being called "galleries", but for those called "examples" now, keeping it so was my impression of the consensus.

@jklymak
Copy link
MemberAuthor

Sorry, I somehow messed up the last push.

@jklymakjklymakforce-pushed themnt-reorg-galleries branch 2 times, most recently from03197dc toc5c7eebCompareFebruary 22, 2023 18:30
@jklymakjklymak marked this pull request as draftFebruary 22, 2023 18:30
@jklymakjklymak marked this pull request as ready for reviewFebruary 22, 2023 19:54
@QuLogic
Copy link
Member

It looks like.github/workflows/tests.yml,.gitignore,.pre-commit-config.yaml andpyproject.toml need updating.

@jklymak
Copy link
MemberAuthor

It looks like.github/workflows/tests.yml,.gitignore,.pre-commit-config.yaml andpyproject.toml need updating.

Phew, we sure repeat the same exceptions in a lot of places....

@jklymak
Copy link
MemberAuthor

The pre-commit isort block doesn't hitgalleries/plot_types. I didn't fix that because that directory fails isort, and didn't want to sidetrack this...

@QuLogicQuLogic merged commitc630505 intomatplotlib:mainFeb 24, 2023
@jklymak
Copy link
MemberAuthor

Thanks for everyone's patient reviews...

Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers

@QuLogicQuLogicQuLogic approved these changes

Assignees
No one assigned
Labels
None yet
Projects
None yet
Milestone
v3.8.0
Development

Successfully merging this pull request may close these issues.

5 participants
@jklymak@tacaswell@timhoffm@ksunden@QuLogic

[8]ページ先頭

©2009-2025 Movatter.jp