Skip to content
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 exception for connectable not found in Network Modification connection and disconnection #3069

Merged
merged 4 commits into from
Jun 20, 2024

Conversation

rolnico
Copy link
Member

@rolnico rolnico commented Jun 19, 2024

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)

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?
If you use for example a ConnectableConnection on a non-existing connectable or on a TieLine (which is not a Connectable), the application of the NetworkModification will crash due to a null pointer exception

What is the new behavior (if this is a feature change)?
You will now get a PowsyblException if you apply with throwException==true or the Network Modification will not be applied and the error will be logged

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

  • Yes
  • No

rolnico added 2 commits June 19, 2024 11:59
…found

Signed-off-by: Nicolas Rol <nicolas.rol@rte-france.com>
Signed-off-by: Nicolas Rol <nicolas.rol@rte-france.com>
@rolnico rolnico added the bug label Jun 19, 2024
@rolnico rolnico self-assigned this Jun 19, 2024
@rolnico rolnico requested a review from annetill June 19, 2024 10:05
Signed-off-by: Nicolas Rol <nicolas.rol@rte-france.com>
@rolnico
Copy link
Member Author

rolnico commented Jun 19, 2024

#3072 could also be another solution

Copy link

@annetill annetill merged commit c227d08 into main Jun 20, 2024
7 checks passed
@annetill annetill deleted the nro/fix_exception_for_connection_on_non_connectable branch June 20, 2024 13:03
olperr1 pushed a commit that referenced this pull request Jun 24, 2024
…ction and disconnection (#3069)

Signed-off-by: Nicolas Rol <nicolas.rol@rte-france.com>
(cherry picked from commit c227d08)
geofjamg pushed a commit that referenced this pull request Sep 18, 2024
…ction and disconnection (#3069)

Signed-off-by: Nicolas Rol <nicolas.rol@rte-france.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants