fix(PDiskSpaceDistribution): use only space severity for slots#2070
Merged
artemmufazalov merged 1 commit intomainfrom Apr 1, 2025
Merged
fix(PDiskSpaceDistribution): use only space severity for slots#2070artemmufazalov merged 1 commit intomainfrom
artemmufazalov merged 1 commit intomainfrom
Conversation
Contributor
There was a problem hiding this comment.
Pull Request Overview
This PR fixes the severity calculation for VDisk slots in PDiskSpaceDistribution by using only the allocated space percent for severity, ignoring other VDisk statuses.
- Updated the severity logic in src/store/reducers/pdisk/utils.ts to remove combination with other status values.
- Adjusted tests in tests/preparePDiskDataResponse.test.ts to verify the new behavior and added an extra test to ensure VDisk statuses are ignored.
Reviewed Changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| src/store/reducers/pdisk/utils.ts | Updated severity calculation logic and comments to use only space severity for VDisks. |
| src/store/reducers/pdisk/tests/preparePDiskDataResponse.test.ts | Updated and added tests to align with the new severity calculation for VDisk slots. |
68f6288 to
443151b
Compare
Contributor
There was a problem hiding this comment.
Pull Request Overview
This PR fixes the severity computation for vDisk slots in PDiskSpaceDistribution by using only the space allocation percentage.
- Removed the combined severity calculation in favor of using getSpaceSeverity exclusively for vDisk slots.
- Updated tests to verify that vDisk severity is determined solely by allocated space.
Reviewed Changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| src/store/reducers/pdisk/utils.ts | Updated vDisk severity calculation to rely solely on allocated space. |
| src/store/reducers/pdisk/tests/preparePDiskDataResponse.test.ts | Adjusted tests to reflect the new severity logic for vDisk slots. |
Raubzeug
approved these changes
Apr 1, 2025
astandrik
approved these changes
Apr 1, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #2060
New logic:
CI Results
Test Status: ✅ PASSED
📊 Full Report
😟 No changes in tests. 😕
Bundle Size: ✅
Current: 83.25 MB | Main: 83.25 MB
Diff: +0.09 KB (0.00%)
✅ Bundle size unchanged.
ℹ️ CI Information