Skip to content

Conversation

@pcbailey
Copy link
Member

@pcbailey pcbailey commented Feb 3, 2026

📝 Description

This PR fixes the behavior of the "Start VirtualMachine after creation" to have the runStrategy be 'Always' if the checkbox is checked and 'Halted' if unchecked.

Jira: https://issues.redhat.com/browse/CNV-77551

🎥 Demo

Before

start-after-creation-checkbox--BEFORE--2026-02-03--07-42.mp4

After

start-after-creation-checkbox--AFTER--2026-02-03--07-31.mp4

Summary by CodeRabbit

  • Bug Fixes
    • Updated the default execution strategy for virtual machines that are inactive to ensure they always run, rather than only rerunning when failures occur.

@openshift-ci-robot
Copy link
Collaborator

openshift-ci-robot commented Feb 3, 2026

@pcbailey: This pull request references CNV-77551 which is a valid jira issue.

Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the bug to target the "4.22.0" version, but no target version was set.

Details

In response to this:

📝 Description

This PR fixes the behavior of the "Start VirtualMachine after creation" to have the runStrategy be 'Always' if the checkbox is checked and 'Halted' if unchecked.

Jira: https://issues.redhat.com/browse/CNV-77551

🎥 Demo

Before

start-after-creation-checkbox--BEFORE--2026-02-03--07-42.mp4

After

start-after-creation-checkbox--AFTER--2026-02-03--07-31.mp4

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 openshift-eng/jira-lifecycle-plugin repository.

@openshift-ci openshift-ci bot added the approved This issue is something we want to fix label Feb 3, 2026
@coderabbitai
Copy link

coderabbitai bot commented Feb 3, 2026

📝 Walkthrough

Walkthrough

The pull request updates the VM draft run strategy assignment logic in the drawer context hook. When a VM is not running and its current run strategy is HALTED or MANUAL, the default strategy is now set to RUNSTRATEGY_ALWAYS instead of RUNSTRATEGY_RERUNONFAILURE, changing the behavioral control flow.

Changes

Cohort / File(s) Summary
VM Run Strategy Configuration
src/views/catalog/templatescatalog/components/TemplatesCatalogDrawer/hooks/useDrawerContext.tsx
Updated import from RUNSTRATEGY_RERUNONFAILURE to RUNSTRATEGY_ALWAYS and modified conditional logic to assign RUNSTRATEGY_ALWAYS when VM has no running state and current runStrategy is HALTED or MANUAL.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Suggested labels

lgtm, approved

Suggested reviewers

  • rszwajko
  • aviavissar
🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly describes the fix for the runStrategy behavior when creating a VirtualMachine, directly matching the code change from RUNSTRATEGY_RERUNONFAILURE to RUNSTRATEGY_ALWAYS.
Description check ✅ Passed The description includes the required sections with a clear explanation of the fix, a Jira reference, and demo videos showing before/after behavior.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment

Important

Action Needed: IP Allowlist Update

If your organization protects your Git platform with IP whitelisting, please add the new CodeRabbit IP address to your allowlist:

  • 136.113.208.247/32 (new)
  • 34.170.211.100/32
  • 35.222.179.152/32

Failure to add the new IP will result in interrupted reviews.


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 and usage tips.

@openshift-ci-robot
Copy link
Collaborator

openshift-ci-robot commented Feb 3, 2026

@pcbailey: This pull request references CNV-77551 which is a valid jira issue.

Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the bug to target the "4.22.0" version, but no target version was set.

Details

In response to this:

📝 Description

This PR fixes the behavior of the "Start VirtualMachine after creation" to have the runStrategy be 'Always' if the checkbox is checked and 'Halted' if unchecked.

Jira: https://issues.redhat.com/browse/CNV-77551

🎥 Demo

Before

start-after-creation-checkbox--BEFORE--2026-02-03--07-42.mp4

After

start-after-creation-checkbox--AFTER--2026-02-03--07-31.mp4

Summary by CodeRabbit

  • Bug Fixes
  • Updated the default execution strategy for virtual machines that are inactive to ensure they always run, rather than only rerunning when failures occur.

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 openshift-eng/jira-lifecycle-plugin repository.

@openshift-ci openshift-ci bot added the lgtm Passed code review, ready for merge label Feb 3, 2026
@openshift-ci
Copy link
Contributor

openshift-ci bot commented Feb 3, 2026

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: pcbailey, upalatucci

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:
  • OWNERS [pcbailey,upalatucci]

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@pcbailey
Copy link
Member Author

pcbailey commented Feb 3, 2026

/hold

@pcbailey
Copy link
Member Author

pcbailey commented Feb 3, 2026

Waiting for a response from Yifat and Ronen as there are larger discussions about runStrategy happening right now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved This issue is something we want to fix do-not-merge/hold jira/valid-reference lgtm Passed code review, ready for merge

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants