Skip to content

Comments

PGM-IO internal import resolution: Copy is_nan functionality from PGM, Step 4#299

Merged
nitbharambe merged 6 commits intomainfrom
feature/copy-isnan-functionality
May 15, 2025
Merged

PGM-IO internal import resolution: Copy is_nan functionality from PGM, Step 4#299
nitbharambe merged 6 commits intomainfrom
feature/copy-isnan-functionality

Conversation

@nitbharambe
Copy link
Member

@nitbharambe nitbharambe commented May 9, 2025

Fixes issue: #297

The alternative to Step 4, of copying the is_nan functionality is done. Since this is implemented, we can skip step 2

Signed-off-by: Nitish Bharambe <[email protected]>
Signed-off-by: Nitish Bharambe <[email protected]>
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR embeds the is_nan logic into the JSON converter (instead of importing from power_grid_model), updates dataset serialization to use the new method, and adds unit tests for the new functionality.

  • Removed external is_nan import and added an internal _is_nan static method
  • Updated _serialize_dataset to call self._is_nan
  • Added test_is_nan to verify behavior across float and integer arrays

Reviewed Changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 3 comments.

File Description
tests/unit/converters/test_pgm_json_converter.py Added test_is_nan to cover float and integer cases
src/power_grid_model_io/converters/pgm_json_converter.py Removed external import, added internal _is_nan and adjusted serialization

nitbharambe and others added 4 commits May 13, 2025 17:29
Co-authored-by: Copilot <[email protected]>
Co-authored-by: Jerry Guo <[email protected]>
Signed-off-by: Nitish Bharambe <[email protected]>
Co-authored-by: Jerry Guo <[email protected]>
Signed-off-by: Nitish Bharambe <[email protected]>
Signed-off-by: Nitish Bharambe <[email protected]>
@sonarqubecloud
Copy link

Quality Gate Failed Quality Gate failed

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

See analysis details on SonarQube Cloud

@nitbharambe nitbharambe enabled auto-merge May 15, 2025 06:39
@nitbharambe nitbharambe added this pull request to the merge queue May 15, 2025
Merged via the queue into main with commit b2b5097 May 15, 2025
22 of 23 checks passed
@nitbharambe nitbharambe deleted the feature/copy-isnan-functionality branch May 15, 2025 11:58
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