Skip to content

Avoid empty input arrays#175

Draft
Thijss wants to merge 1 commit intomainfrom
fix/avoid-empty-imput-arrays
Draft

Avoid empty input arrays#175
Thijss wants to merge 1 commit intomainfrom
fix/avoid-empty-imput-arrays

Conversation

@Thijss
Copy link
Member

@Thijss Thijss commented Mar 4, 2026

When converting to a pgm_input_dict, we should not include empty arrays.

Reasons:

Note: As @mgovers suggested, this is technically a breaking change (different set of dict keys in pgm_input dict). Though I doubt it will have much impact.

Signed-off-by: Thijs Baaijen <13253091+Thijss@users.noreply.github.com>
@sonarqubecloud
Copy link

sonarqubecloud bot commented Mar 4, 2026

@Thijss Thijss marked this pull request as draft March 6, 2026 09:39
Copy link
Member

@vincentkoppen vincentkoppen left a comment

Choose a reason for hiding this comment

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

Whether needed or not, seems like a sensible change any way to me.
This way the input_data if looked at, is much easier to understand for the user.

loaded_grid = Grid.deserialize(path)
assert loaded_grid == grid

@pytest.mark.parametrize("grid_fixture", ("basic_grid", "grid"))
Copy link
Member

Choose a reason for hiding this comment

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

Any specific reason we should test on grid anymore?

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.

2 participants