Skip to content

chore: Extract allowed values #4342

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

Open
wants to merge 13 commits into
base: main
Choose a base branch
from
Open

Conversation

hpohekar
Copy link
Collaborator

@hpohekar hpohekar commented Aug 4, 2025

This pull request focuses on improving maintainability by extracting and explicitly defining allowed values for settings classes. The main change ensures that allowed values are clearly listed and type-annotated, which will help with code clarity and future maintenance.

Settings class allowed values extraction:

  • Added the _allowed_values attribute to settings classes in both implementation and stub files, making allowed values explicit and type-annotated (src/ansys/fluent/core/codegen/settingsgen.py).
  • Documented the extraction of allowed values in the changelog (doc/changelog.d/4342.maintenance.md).

@github-actions github-actions bot added the enhancement Improve any current implemented feature label Aug 4, 2025
@hpohekar hpohekar linked an issue Aug 4, 2025 that may be closed by this pull request
@seanpearsonuk
Copy link
Collaborator

@hpohekar Please can we have description text: images won't play well in the logs.

@hpohekar
Copy link
Collaborator Author

hpohekar commented Aug 6, 2025

@hpohekar Please can we have description text: images won't play well in the logs.

@seanpearsonuk Done. Thank you.

@prmukherj
Copy link
Collaborator

@hpohekar, for these things we can add a small test in test_codegen?

@hpohekar
Copy link
Collaborator Author

hpohekar commented Aug 6, 2025

@hpohekar, for these things we can add a small test in test_codegen?

@prmukherj Yes, we can. Will add one.

@hpohekar hpohekar enabled auto-merge (squash) August 6, 2025 09:59
@hpohekar
Copy link
Collaborator Author

hpohekar commented Aug 6, 2025

We need to wait for some more time as Fluent side changes are not available in the latest Fluent image. (Tests are failing due to this).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Improve any current implemented feature
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Extract allowed values in settings_*.py
5 participants