Skip to content

Get var descriptions from new dataclass structure#4216

Open
clmould wants to merge 1 commit intomainfrom
fix-dict-descriptions
Open

Get var descriptions from new dataclass structure#4216
clmould wants to merge 1 commit intomainfrom
fix-dict-descriptions

Conversation

@clmould
Copy link
Copy Markdown
Collaborator

@clmould clmould commented Apr 30, 2026

Description

Closes #4215

Checklist

I confirm that I have completed the following checks:

  • My changes follow the PROCESS style guide
  • I have justified any large differences in the regression tests caused by this pull request in the comments.
  • I have added new tests where appropriate for the changes I have made.
  • If I have had to change any existing unit or integration tests, I have justified this change in the pull request comments.
  • If I have made documentation changes, I have checked they render correctly.
  • I have added documentation for my change, if appropriate.

@codecov-commenter
Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 52.14%. Comparing base (14ef433) to head (c10b8f1).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #4216      +/-   ##
==========================================
+ Coverage   52.13%   52.14%   +0.01%     
==========================================
  Files         148      148              
  Lines       30419    30429      +10     
==========================================
+ Hits        15858    15868      +10     
  Misses      14561    14561              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@clmould clmould marked this pull request as ready for review May 1, 2026 09:06
@clmould clmould requested a review from a team as a code owner May 1, 2026 09:06
Comment on lines +489 to +493
if isinstance(node1, ast.AnnAssign) and not isinstance(
node2, ast.Expr
):
# if no docstring for variable, have a blank description
var_names_and_descriptions[node1.target.id] = ""
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Is this second condition needed? Surely any situation other than declaration->docstring should have a blank description so this could just be an else

@timothy-nunn timothy-nunn added the Data structure Issues related to the data structure label May 5, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Data structure Issues related to the data structure

Projects

None yet

Development

Successfully merging this pull request may close these issues.

🐛 DICT_DESCRIPTIONS dict is empty for data_structure files converted to dataclasses

3 participants