Skip to content

feature(RAO Result): convert to operator strategy#1633

Draft
bqth29 wants to merge 10 commits intomainfrom
experiment/rao-result-to-operator-strategy
Draft

feature(RAO Result): convert to operator strategy#1633
bqth29 wants to merge 10 commits intomainfrom
experiment/rao-result-to-operator-strategy

Conversation

@bqth29
Copy link
Copy Markdown
Collaborator

@bqth29 bqth29 commented Feb 20, 2026

Please check if the PR fulfills these requirements

  • The commit message follows our guidelines
  • Tests for the changes have been added (for bug fixes / features)
  • Docs have been added / updated (for bug fixes / features)
  • A PR or issue has been opened in all impacted repositories (if any)

Does this PR already have an issue describing the problem?

What kind of change does this PR introduce?
Allow to convert a RAO Result to a list of Operator Strategies and Actions to easily run a security analysis based on the outputs of the RAO.

Simply run RaoResult::getOperatorStrategies

What is the current behavior?

What is the new behavior (if this is a feature change)?

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

  • Yes
  • No

If yes, please check if the following requirements are fulfilled

  • The Breaking Change or Deprecated label has been added
  • The migration steps are described in the following section

What changes might users need to make in their application due to this PR? (migration steps)

Other information:

Signed-off-by: Thomas Bouquet <thomas.bouquet@rte-france.com>
Signed-off-by: Thomas Bouquet <thomas.bouquet@rte-france.com>
}

default StrategiesAndActions getOperatorStrategies(Crac crac, Network network) {
return OperatorStrategyConverter.getOperatorStrategies(this, crac, network);
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.

maybe let's accept once and for all that a RaoResult depends on a Crac (thus we can add a RaoResult.getCrac() method) and that a Crac depends on a Network (Crac.getNetwork())
@phiedw @Godelaine thoughts ?

Signed-off-by: Thomas Bouquet <thomas.bouquet@rte-france.com>
Signed-off-by: Thomas Bouquet <thomas.bouquet@rte-france.com>
@sonarqubecloud
Copy link
Copy Markdown

❌ The last analysis has failed.

See analysis details on SonarQube Cloud

bqth29 and others added 2 commits February 23, 2026 17:26
Signed-off-by: Thomas Bouquet <thomas.bouquet@rte-france.com>
…ao/data/raoresult/api/OperatorStrategyConverter.java

Co-authored-by: Peter Mitri <peter.mitri@rte-france.com>
Signed-off-by: Thomas Bouquet <thomas.bouquet@rte-france.com>
pet-mit
pet-mit previously approved these changes Feb 25, 2026
Signed-off-by: Thomas Bouquet <thomas.bouquet@rte-france.com>
@bqth29 bqth29 changed the title Experiment/rao result to operator strategy converter feature(RAO Result): convert to operator strategy Feb 27, 2026
@bqth29 bqth29 added feature New feature or request PR: waiting-for-review This PR is waiting to be reviewed labels Feb 27, 2026
@bqth29 bqth29 requested a review from pet-mit February 27, 2026 16:49
@bqth29 bqth29 marked this pull request as ready for review February 27, 2026 16:51
@bqth29
Copy link
Copy Markdown
Collaborator Author

bqth29 commented Feb 27, 2026

There is currently no way to serialize a Switch Pair Action because it is not part of PowSyBl core ecosystem. I see two ways of doing it:

  1. implement switch pairs in core
  2. remove switch pairs API in OpenRAO and replace it by two switch actions

@pet-mit do you have an opinion on this matter?

I guess a key point is to know whether a switch pai is to be considered as one elementary action or two

@sonarqubecloud
Copy link
Copy Markdown

Quality Gate Failed Quality Gate failed

Failed conditions
43.1% Coverage on New Code (required ≥ 80%)

See analysis details on SonarQube Cloud

@bqth29 bqth29 marked this pull request as draft March 2, 2026 10:22
@bqth29 bqth29 marked this pull request as draft March 2, 2026 10:22
@pet-mit
Copy link
Copy Markdown
Collaborator

pet-mit commented Mar 4, 2026

There is currently no way to serialize a Switch Pair Action because it is not part of PowSyBl core ecosystem. I see two ways of doing it:

  1. implement switch pairs in core
  2. remove switch pairs API in OpenRAO and replace it by two switch actions

@pet-mit do you have an opinion on this matter?

I guess a key point is to know whether a switch pai is to be considered as one elementary action or two

why do you need to serialize a switch pair action as one powsybl action ?
it should be enough to consider it as two elementary (powsybl) actions like it is done under the hood in the CracImpl

@phiedw phiedw closed this Mar 17, 2026
@phiedw phiedw deleted the experiment/rao-result-to-operator-strategy branch March 17, 2026 16:29
@bqth29 bqth29 restored the experiment/rao-result-to-operator-strategy branch March 17, 2026 16:38
@bqth29 bqth29 reopened this Mar 17, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

feature New feature or request PR: waiting-for-review This PR is waiting to be reviewed

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants