Skip to content

Fix missing class members in generated documentation - #1230

Closed
yashwantbezawada wants to merge 1 commit into
NVIDIA:mainfrom
yashwantbezawada:fix/docs-device-properties-attributes
Closed

Fix missing class members in generated documentation#1230
yashwantbezawada wants to merge 1 commit into
NVIDIA:mainfrom
yashwantbezawada:fix/docs-device-properties-attributes

Conversation

@yashwantbezawada

Copy link
Copy Markdown

Description

Fixes#1215 and #1100

After switching to nvidia-sphinx-theme in PR #874, class members (properties, methods, attributes) were no longer being documented in the generated HTML pages. This affected DeviceProperties and other classes using the autosummary class template.

Root Cause

The autoclass directive in the template (cuda_core/docs/source/_templates/autosummary/class.rst) was not configured to document members. Without the :members: option, Sphinx's autodoc extension only generates the class signature but no member documentation.

Changes

Added three Sphinx autodoc options to the class template:

  • :members: - Include all class members in the documentation
  • :undoc-members: - Include members without docstrings
  • :show-inheritance: - Display base classes

Testing

This change affects all classes documented using the autosummary class template. The fix restores member documentation to how it appeared before the theme switch (compare with v0.3.2 documentation).

Example affected classes:

  • DeviceProperties (153 properties)
  • Device and other classes using the template

Before/After

Before (current): DeviceProperties page shows only the class docstring with no attributes listed.

After (with this fix): DeviceProperties page shows all 153 property attributes with their docstrings, matching the v0.3.2 documentation format.

FixesNVIDIA#1215 and NVIDIA#1100
After switching to nvidia-sphinx-theme in PR NVIDIA#874, class members
(properties, methods, attributes) were no longer being documented
in the generated HTML pages. This affected DeviceProperties and
other classes using the autosummary class template.
Root cause: The autoclass directive in the template was not
configured to document members. Added :members:, :undoc-members:,
and :show-inheritance: options to ensure all class members are
properly documented.
Changes:
- Added :members: option to include all class members
- Added :undoc-members: to include members without docstrings
- Added :show-inheritance: to display base classes
This restores the documentation to how it appeared before the
theme switch (see v0.3.2 for comparison).
@copy-pr-bot

Copy link
Copy Markdown
Contributor

This pull request requires additional validation before any workflows can run on NVIDIA's runners.

Pull request vetters can view their responsibilities here.

Contributors can view more details about this message here.

@cpcloudcpcloud left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Thanks!

@cpcloud

Copy link
Copy Markdown
Contributor

/ok to test

@copy-pr-bot

Copy link
Copy Markdown
Contributor

/ok to test

@cpcloud, there was an error processing your request: E1

See the following link for more information: https://docs.gha-runners.nvidia.com/cpr/e/1/

@cpcloud

Copy link
Copy Markdown
Contributor

/ok to test 1ae0ef0

@github-actions

Copy link
Copy Markdown

@cpcloudcpcloud left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

@leofangleofang added bug Something isn't working documentation Improvements or additions to documentation P0 High priority - Must do! cuda.core Everything related to the cuda.core module labels Nov 10, 2025
@leofang

Copy link
Copy Markdown
Member

Superseded by #1444. Closing.

@leofangleofang closed this Jan 12, 2026
github-actionsBot pushed a commit that referenced this pull request Jan 12, 2026
Removed preview folders for the following PRs:
- PR #1230
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bugSomething isn't workingcuda.coreEverything related to the cuda.core moduledocumentationImprovements or additions to documentationP0High priority - Must do!

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Device properties docs are broken

3 participants

@yashwantbezawada@cpcloud@leofang