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

fix the error of cluster status old condition update will overwrite the newest condition #5227

Merged

Conversation

XiShanYongYe-Chang
Copy link
Member

@XiShanYongYe-Chang XiShanYongYe-Chang commented Jul 19, 2024

What type of PR is this?

/kind bug
/kind failing-test

What this PR does / why we need it:

During the cluster status update, due to the presence of an old Condition in the previous Cluster status, this Condition is incorrectly updated to the Cluster object during the status refresh. The expected Cluster status conditions should no longer include the old condition.

Which issue(s) this PR fixes:
Fixes #

Special notes for your reviewer:

Does this PR introduce a user-facing change?:

`karmada-controller-manager`: Fixed the error of cluster status old condition update will overwrite the newest condition.

@karmada-bot karmada-bot added kind/failing-test Categorizes issue or PR as related to a consistently or frequently failing test. do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. labels Jul 19, 2024
@karmada-bot karmada-bot requested review from Poor12 and Vacant2333 July 19, 2024 04:05
@karmada-bot karmada-bot added the size/S Denotes a PR that changes 10-29 lines, ignoring generated files. label Jul 19, 2024
@codecov-commenter
Copy link

codecov-commenter commented Jul 19, 2024

⚠️ Please install the 'codecov app svg image' to ensure uploads and comments are reliably processed by Codecov.

Codecov Report

Attention: Patch coverage is 80.64516% with 6 lines in your changes missing coverage. Please review.

Project coverage is 29.66%. Comparing base (51b2e10) to head (b59761e).

Files Patch % Lines
...kg/controllers/status/cluster_status_controller.go 80.64% 4 Missing and 2 partials ⚠️

❗ Your organization needs to install the Codecov GitHub app to enable full functionality.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #5227      +/-   ##
==========================================
- Coverage   29.67%   29.66%   -0.01%     
==========================================
  Files         632      632              
  Lines       43901    43915      +14     
==========================================
+ Hits        13027    13029       +2     
- Misses      29931    29939       +8     
- Partials      943      947       +4     
Flag Coverage Δ
unittests 29.66% <80.64%> (-0.01%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@XiShanYongYe-Chang
Copy link
Member Author

/retest

@XiShanYongYe-Chang XiShanYongYe-Chang force-pushed the fix-remedy-ci-failed branch 7 times, most recently from 35f6dca to 5a0d116 Compare July 25, 2024 02:14
@XiShanYongYe-Chang XiShanYongYe-Chang changed the title [WIP] fix the occasional cluster status wait error in the remedy test Fix the occasional cluster status wait error in the remedy test Jul 25, 2024
@karmada-bot karmada-bot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Jul 25, 2024
@XiShanYongYe-Chang
Copy link
Member Author

/cc @zhzhuang-zju @RainbowMango

@XiShanYongYe-Chang
Copy link
Member Author

/retest

@XiShanYongYe-Chang
Copy link
Member Author

/retest

@XiShanYongYe-Chang
Copy link
Member Author

/retest

@XiShanYongYe-Chang XiShanYongYe-Chang force-pushed the fix-remedy-ci-failed branch 4 times, most recently from 37988be to 626ae87 Compare July 30, 2024 01:44
@XiShanYongYe-Chang
Copy link
Member Author

/hold

@karmada-bot karmada-bot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Aug 9, 2024
@karmada-bot karmada-bot added size/M Denotes a PR that changes 30-99 lines, ignoring generated files. and removed size/S Denotes a PR that changes 10-29 lines, ignoring generated files. labels Aug 19, 2024
@XiShanYongYe-Chang XiShanYongYe-Chang changed the title Fix the occasional cluster status wait error in the remedy test fix the error of cluster status condition update will overwrite the old condition Aug 19, 2024
@XiShanYongYe-Chang XiShanYongYe-Chang changed the title fix the error of cluster status condition update will overwrite the old condition fix the error of cluster status old condition update will overwrite the newest condition Aug 19, 2024
@XiShanYongYe-Chang
Copy link
Member Author

/hold cancel
/kind bug

@karmada-bot karmada-bot added kind/bug Categorizes issue or PR as related to a bug. and removed do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. labels Aug 19, 2024
@XiShanYongYe-Chang
Copy link
Member Author

/assign @RainbowMango

Copy link
Member

@RainbowMango RainbowMango left a comment

Choose a reason for hiding this comment

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

/lgtm
/approve

@karmada-bot karmada-bot added the lgtm Indicates that a PR is ready to be merged. label Aug 19, 2024
@karmada-bot
Copy link
Collaborator

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: RainbowMango

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 /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@karmada-bot karmada-bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Aug 19, 2024
@karmada-bot karmada-bot merged commit 7307e2e into karmada-io:master Aug 19, 2024
12 checks passed
@RainbowMango RainbowMango added this to the v1.11 milestone Aug 31, 2024
karmada-bot added a commit that referenced this pull request Sep 2, 2024
…k-of-#5227-upstream-release-1.9

Automated cherry pick of #5227: fix error of when cluster status condition update
karmada-bot added a commit that referenced this pull request Sep 2, 2024
…k-of-#5227-upstream-release-1.10

Automated cherry pick of #5227: fix error of when cluster status condition update
@XiShanYongYe-Chang XiShanYongYe-Chang deleted the fix-remedy-ci-failed branch September 25, 2024 07:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. kind/bug Categorizes issue or PR as related to a bug. kind/failing-test Categorizes issue or PR as related to a consistently or frequently failing test. lgtm Indicates that a PR is ready to be merged. size/M Denotes a PR that changes 30-99 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants