Skip to content

Feature/#2/create enums for solver types#69

Open
olivierPigeon-RTE wants to merge 1 commit intomainfrom
feat/#2/create-enums-for-solver-types
Open

Feature/#2/create enums for solver types#69
olivierPigeon-RTE wants to merge 1 commit intomainfrom
feat/#2/create-enums-for-solver-types

Conversation

@olivierPigeon-RTE
Copy link
Contributor

@olivierPigeon-RTE olivierPigeon-RTE commented Dec 3, 2025

Does this PR already have an issue describing the problem?

Fixes #2

What kind of change does this PR introduce?

This PR replaces several string values bay enums to be more resilient and avoid typos

Does this PR introduce a breaking change or deprecate an API?

  • Yes
  • No

@olivierPigeon-RTE olivierPigeon-RTE linked an issue Dec 3, 2025 that may be closed by this pull request
@olivierPigeon-RTE olivierPigeon-RTE force-pushed the feat/#2/create-enums-for-solver-types branch from 79adb2b to 3e2e6e1 Compare December 22, 2025 10:39
@olivierPigeon-RTE olivierPigeon-RTE force-pushed the feat/#2/create-enums-for-solver-types branch from 3e2e6e1 to 2b92c3e Compare January 22, 2026 15:54
@olivierPigeon-RTE olivierPigeon-RTE force-pushed the feat/#2/create-enums-for-solver-types branch 3 times, most recently from ac15b1b to 97f2aaf Compare February 11, 2026 09:21
Delete Solver.Names and create enums instead to make the code more robust

BREAKING CHANGE: The solvers must be called with enums instead of strings from now

Signed-off-by: Olivier Pigeon <olivier.pigeon@rte-france.com>
@olivierPigeon-RTE olivierPigeon-RTE force-pushed the feat/#2/create-enums-for-solver-types branch from 97f2aaf to 1a3751f Compare February 13, 2026 10:48
@sonarqubecloud
Copy link


from enum import Enum

class SolverType(Enum):
Copy link
Member

Choose a reason for hiding this comment

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

Can you please add a docstring to this class?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Can you please provide a short description for each solver type anc their particularities so I can add it ?

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.

Gerer les modeles et les equations sous forme d'énumérés

2 participants