Skip to content

[Backport release-1.6] fix(virtual-machine): guard Kube-OVN IP lookup - #5061

Merged
myasnikovdaniil merged 1 commit into
release-1.6from
backport-4013-to-release-1.6
Oct 22, 2026
Merged

myasnikovdaniil merged 1 commit into
release-1.6from
backport-4013-to-release-1.6

Conversation

@github-actions

Copy link
Copy Markdown

Description

Backport of #4013 to release-1.6.

Helm's `lookup` propagates the discovery error when the requested API
group is not served, so the vm-instance chart could not render at all on
clusters without the Kube-OVN CRDs. Gate the IP lookup behind
`.Capabilities.APIVersions.Has "kubeovn.io/v1/IP"`.

The regression suite mocks the IP object through kubernetesProvider and
pins both sides: with the API advertised the annotations carry the mocked
MAC and IP, without it they are absent even though the object exists.
helm-unittest's fake lookup never errors on an unserved kind, so only the
second case distinguishes the guard; it fails on main and passes here.

Assisted-By: GPT-5 <[email protected]>
Signed-off-by: Loïc Fontaine <[email protected]>
(cherry picked from commit b142d27)
@coderabbitai

coderabbitai Bot commented Oct 22, 2026

Copy link
Copy Markdown
Contributor

Important

Review skipped

Bot user detected.

To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@myasnikovdaniil
myasnikovdaniil merged commit a521806 into release-1.6 Oct 22, 2026
12 checks passed
@myasnikovdaniil
myasnikovdaniil deleted the backport-4013-to-release-1.6 branch October 22, 2026 19:25
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