Skip to content

Custom logic for 3-way-merging null values#4542

Merged
mozesl-nokia merged 5 commits into
kptdev:mainfrom
nokia:fix-3merge-null
Jun 5, 2026
Merged

Custom logic for 3-way-merging null values#4542
mozesl-nokia merged 5 commits into
kptdev:mainfrom
nokia:fix-3merge-null

Conversation

@tgzsolt

@tgzsolt tgzsolt commented May 27, 2026

Copy link
Copy Markdown
Contributor

Description

fix the 3merge for an edge case related to null value

Motivation

3way merge does not use the Updated value for a key if Dest and Origin values both are null.

Fix

Do not return nil (it will delete the key from result) when original value is also null (or the key missing)

Copilot AI review requested due to automatic review settings May 27, 2026 12:09
@dosubot dosubot Bot added size:XS This PR changes 0-9 lines, ignoring generated files. bug Something isn't working labels May 27, 2026
@netlify

netlify Bot commented May 27, 2026

Copy link
Copy Markdown

Deploy Preview for kptdocs ready!

Name Link
🔨 Latest commit 23f82eb
🔍 Latest deploy log https://app.netlify.com/projects/kptdocs/deploys/6a227fe2c2fe5e000816e3ad
😎 Deploy Preview https://deploy-preview-4542--kptdocs.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
🤖 Make changes Run an agent on this branch

To edit notification comments on pull requests, go to your Netlify project configuration.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Copilot encountered an error and was unable to review this pull request. You can try again by re-requesting a review.

@dosubot dosubot Bot added size:L This PR changes 100-499 lines, ignoring generated files. and removed size:XS This PR changes 0-9 lines, ignoring generated files. labels May 28, 2026
Copilot AI review requested due to automatic review settings May 28, 2026 14:51
@tgzsolt tgzsolt force-pushed the fix-3merge-null branch from 59be6ca to 2ae79a2 Compare May 28, 2026 14:53

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

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

Comment thread pkg/lib/update/merge3/visitor.go Outdated
Comment thread pkg/lib/update/merge3/visitor.go Outdated
Comment thread pkg/lib/update/merge3/visitor.go Outdated
Comment thread pkg/lib/update/merge3/visitor.go
Comment thread pkg/lib/update/merge3/visitor.go Outdated
Comment thread pkg/lib/update/merge3/visitor.go Outdated
@tgzsolt tgzsolt force-pushed the fix-3merge-null branch from 5d401d2 to 5abaeaa Compare May 29, 2026 06:57
Copilot AI review requested due to automatic review settings June 1, 2026 08:13

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

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

Comment thread pkg/lib/update/merge3/visitor.go Outdated
Comment thread pkg/lib/update/merge3/visitor.go Outdated
Comment thread pkg/lib/update/merge3/visitor.go Outdated
Comment thread pkg/lib/update/merge3/visitor.go Outdated
Comment thread pkg/lib/update/merge3/visitor.go
@tgzsolt tgzsolt requested a review from Copilot June 1, 2026 13:09

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

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

Comment thread pkg/lib/update/merge3/visitor.go Outdated
Comment thread pkg/lib/update/merge3/visitor.go Outdated
Comment thread pkg/lib/update/merge3/visitor.go
Comment thread pkg/lib/update/merge3/visitor.go Outdated
@tgzsolt tgzsolt force-pushed the fix-3merge-null branch from 687d54a to 9b6fea5 Compare June 1, 2026 13:12
Copilot AI review requested due to automatic review settings June 1, 2026 13:46

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

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

Comment thread pkg/lib/update/merge3/visitor.go Outdated
Comment thread pkg/lib/update/merge3/visitor.go Outdated
Comment thread pkg/lib/update/merge3/tuple.go
tgzsolt and others added 3 commits June 4, 2026 17:25
Signed-off-by: tar <gabor.tar.ext@nokia.com>
Signed-off-by: tar <gabor.tar.ext@nokia.com>
Signed-off-by: Mózes László Máté <laszlo.mozes@nokia.com>
Signed-off-by: Mózes László Máté <laszlo.mozes@nokia.com>
Copilot AI review requested due to automatic review settings June 4, 2026 16:03

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 12 out of 12 changed files in this pull request and generated 4 comments.

Comment thread pkg/lib/update/merge3/visitor.go Outdated
Comment thread pkg/lib/update/merge3/visitor.go
Comment thread pkg/lib/update/common.go
Comment thread pkg/lib/update/resource-merge_test.go
@tgzsolt tgzsolt requested a review from Copilot June 5, 2026 05:25

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 17 out of 17 changed files in this pull request and generated 4 comments.

Comment thread pkg/lib/update/merge3/visitor.go
Comment thread pkg/lib/update/common.go
Comment thread pkg/lib/update/resource-merge_test.go
Comment thread pkg/lib/update/merge3/tuple.go
Signed-off-by: tar <gabor.tar.ext@nokia.com>
@tgzsolt tgzsolt force-pushed the fix-3merge-null branch from e568c23 to 23f82eb Compare June 5, 2026 07:50
@dosubot dosubot Bot added the lgtm label Jun 5, 2026
@tgzsolt tgzsolt changed the title fix 3merge null values Custom logic for 3-way-merging null values Jun 5, 2026
@mozesl-nokia mozesl-nokia merged commit fbd01ab into kptdev:main Jun 5, 2026
12 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working lgtm size:L This PR changes 100-499 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants