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

Add fix to Matpower importer to import some pglib files #3256

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

geofjamg
Copy link
Member

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?

Feature

What is the current behavior?

Some matpower files like pglib_opf_case1354_pegase.m from https://github.com/power-grid-lib/pglib-opf cannot be imported because the generator column count correspond to v1 format and not v2.

What is the new behavior (if this is a feature change)?
We accept to read the file anyway even with missing columns.

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:

Copy link

Quality Gate Failed Quality Gate failed

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

See analysis details on SonarQube Cloud

gen.setRampThirtyMinutes(generators.getDouble(row, 18));
gen.setRampQ(generators.getDouble(row, 19));
gen.setApf(generators.getDouble(row, 20));
if (generators.getDimensions()[1] > MATPOWER_V1_GENERATORS_COLUMNS) {
Copy link
Member

Choose a reason for hiding this comment

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

generatorColumns > MATPOWER_V1_GENERATORS_COLUMNS ?

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