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
Bug 1907282: fix topology page white screen, use ternary operator instead of logical operator #7534
Conversation
@sahil143: This pull request references Bugzilla bug 1907282, which is valid. The bug has been moved to the POST state. The bug has been updated to refer to the pull request using the external bug tracker. 3 validation(s) were run on this bug
In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
@sahil143: This pull request references Bugzilla bug 1907282, which is valid. 3 validation(s) were run on this bug
In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
/lgtm |
/assign |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/approve
The changes in the PR works fine to fix the issue and does make sense but I would like to point out that the analysis/root cause in the description mentions that the issue is caused because boolean value is being passed to _.truncate
and it's changing false
=> 'false'
. But that wouldn't break the UI since the prop accepts a string as valid type, so the main issue was being caused because false
was being passed to titleComponent
prop. Its fixed after these changes because now titleComponent
receives undefined
instead of false
. cc: @sahil143
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: karthikjeeyar, rohitkrai03, sahil143 The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
Agreed, titleComponent wasn't being invoked since title itself was a boolean |
@sahil143: All pull requests linked via external trackers have merged: Bugzilla bug 1907282 has been moved to the MODIFIED state. In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
Fixes: https://issues.redhat.com/browse/ODC-5258
Analysis / Root cause:
We are using logical operator in the PodSet component which causes it to pass a boolean value to PodStatus component title/subtitle and since we started to truncate the title/subtitle using
_.truncate
in PodStatus component with PR #7447, boolean values are converted to string by lodash truncatefalse => 'false'
.Solution Description: use ternary operator instead of logical operator and pass
undefined
if showPodCount is falseScreen shots / Gifs for design review:
NO UI changes
Unit test coverage report:
Test setup:
Browser conformance: