Skip to content
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 our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor: Deprecate 'selection' and 'rendering' YAML keys #420

Merged
merged 2 commits into from Apr 20, 2022

Conversation

pawamoy
Copy link
Member

@pawamoy pawamoy commented Apr 10, 2022

Commit message:

As seen in commit eb822cb, the separation of
the selection/collection and rendering configuration
is problematic. This commit further reduces this
separation by merging the two current YAML keys
'selection' and 'rendering' into a single
'options' key. It means both the 'collect' and
'render' methods have access to every option.

The old keys can still be used, but are deprecated,
and therefore a deprecation warning is emitted
if these keys are found in either global or local
configurations.


This was mentioned in #364.
Example diffs:

 # mkdocs.yml
 plugins:
 - mkdocstrings:
     handlers:
       python:
-        selection:
+        options:
           docstring_style: google
           docstring_options:
             ignore_init_summary: yes
-        rendering:
           merge_init_into_class: yes
           show_submodules: no
 # My Class

 ::: my_package.MyClass
-    rendering:
+    options:
       show_root_toc_entry: no

As seen in commit eb822cb, the separation of
the selection/collection and rendering configuration
is problematic. This commit further reduces this
separation by merging the two current YAML keys
'selection' and 'rendering' into a single
'options' key. It means both the 'collect' and
'render' methods have access to every option.

The old keys can still be used, but are deprecated,
and therefore a deprecation warning is emitted
if these keys are found in either global or local
configurations.
@pawamoy pawamoy mentioned this pull request Apr 10, 2022
31 tasks
@oprypin oprypin self-requested a review April 10, 2022 15:31
@pawamoy
Copy link
Member Author

pawamoy commented Apr 17, 2022

I intend to merge this in two days 🙂

@pawamoy
Copy link
Member Author

pawamoy commented Apr 20, 2022

Merging, we can always revise the changes before releasing them.

@pawamoy pawamoy merged commit 3335310 into master Apr 20, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant