-
Notifications
You must be signed in to change notification settings - Fork 13
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
Fix one leg intern cells #595
Conversation
Signed-off-by: Florian Dupuy <florian.dupuy@rte-france.com>
Signed-off-by: Florian Dupuy <florian.dupuy@rte-france.com>
Signed-off-by: Florian Dupuy <florian.dupuy@rte-france.com>
Signed-off-by: Florian Dupuy <florian.dupuy@rte-france.com>
Signed-off-by: Florian Dupuy <florian.dupuy@rte-france.com>
Signed-off-by: Florian Dupuy <florian.dupuy@rte-france.com>
Signed-off-by: Florian Dupuy <florian.dupuy@rte-france.com>
Signed-off-by: Sophie Frasnedo <sophie.frasnedo@rte-france.com>
Signed-off-by: Sophie Frasnedo <sophie.frasnedo@rte-france.com>
List<LegPrimaryBlock> subBlocks = legParallelBlock.getSubBlocks(); | ||
if (subBlocks.size() == 2) { | ||
internCell.replaceOneLegByMultiLeg(subBlocks.get(0), subBlocks.get(1)); | ||
} else { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This else statement is never used (neither in unit tests nor in other tests I ran with French substations).
Shall we remove it?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Now there's one unit test which uses it. And I fixed the content of the else, adding comments to explain better what's done.
Signed-off-by: Sophie Frasnedo <sophie.frasnedo@rte-france.com>
Signed-off-by: Florian Dupuy <florian.dupuy@rte-france.com>
bc1ab03
to
356a1c8
Compare
Signed-off-by: Florian Dupuy <florian.dupuy@rte-france.com>
Quality Gate passedIssues Measures |
Please check if the PR fulfills these requirements
Does this PR already have an issue describing the problem?
No
What kind of change does this PR introduce?
Bug fix
What is the current behavior?
One-leg intern cells, which are intern cells which are displayed as a single vertical line, forces the corresponding busbars to be parallel, which used to lead to unexpected behaviour (mixing components on one of the two bars). Since PR #573, an exception is thrown.
Example of one-leg intern cell from unit tests:
What is the new behavior (if this is a feature change)?
MAYBE_ONE_LEG
ONE_LEG
UNDEFINED
orMAYBE_FLAT
UNDEFINED
orMAYBE_FLAT
ONE_LEG
ONE_LEG
Note that when splitting in two parts the subBlocks of the internCell, we favour the splitting based on LegBusSets as they can deal with complex subsections which contain more than one sectionIndex (e.g., two parallel busbars with different lengths).
Does this PR introduce a breaking change or deprecate an API?