pipelines icon indicating copy to clipboard operation
pipelines copied to clipboard

Fix /default parameters not displayed in Compare Runs

Open rishabh998186 opened this issue 2 weeks ago • 2 comments

This PR fixes an issue where default pipeline parameters are not shown in the Compare Runs view when a run is created from the UI without changing any parameter values. Previously, parameter values were only propagated when the user interacted with the inputs, so untouched defaults were missing from runtime_config and therefore from Compare Runs.

changes

NewRunParametersV2.tsx


Extend the existing parameter initialization effect to:

1. Build runtimeParametersInRealType from specParameters using convertInput for each parameter type.

2. Call handleParameterChange(runtimeParametersInRealType) once on mount/when spec changes so that:

 * Default parameter values are propagated to the parent (setRuntimeParameters).

 * These defaults are included in runtime_config even if the user does not modify any parameter fields.

3. Preserve the existing validation behavior with setIsValidInput.

NewRunParametersV2.test.tsx

1. Add a test: calls handleParameterChange with default values on mount:

Mount NewRunParametersV2 with a set of parameters of different types: STRING, NUMBER_INTEGER, BOOLEAN, LIST, and STRUCT, each with a defaultValue.

2.Assert that handleParameterChange is:

* Called exactly once.

*Called with the correctly converted runtime values.

3. Assert that these default values are rendered in the UI inputs.

Fixes: #12536

rishabh998186 avatar Dec 09 '25 04:12 rishabh998186

Hi @rishabh998186. Thanks for your PR.

I'm waiting for a kubeflow member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

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.

google-oss-prow[bot] avatar Dec 09 '25 04:12 google-oss-prow[bot]

/ok-to-test

droctothorpe avatar Dec 19 '25 00:12 droctothorpe

Hey @droctothorpe, thanks for looking at my PR!

I've made some new changes to address the Compare Runs issue:

NewRunParametersV2.tsx: Now calls handleParameterChange on mount with all default parameter values, ensuring they're included in runtime_config even without user interaction

NewRunParametersV2.test.tsx: Updated existing tests and added 3 new test cases covering default-only runs, partial changes, and falsy default values

All tests are passing and the frontend build succeeds. Could you please review these changes and let me know if you need any modifications?

Thanks!

rishabh998186 avatar Dec 20 '25 07:12 rishabh998186

/ok-to-test

droctothorpe avatar Dec 22 '25 05:12 droctothorpe

✅ Added ok-to-test label. CI will now run automatically on all commits to this PR.

github-actions[bot] avatar Dec 22 '25 05:12 github-actions[bot]

/lgtm

droctothorpe avatar Dec 22 '25 05:12 droctothorpe

@droctothorpe I think all required checks are passed the failing check is just an syntex error . If anything is still missing let me know , I fix it.

thinks for looking at my pr .

rishabh998186 avatar Dec 22 '25 05:12 rishabh998186

Np! Tag me once you fix the syntax error.

droctothorpe avatar Dec 22 '25 06:12 droctothorpe

@droctothorpe done ,i fixed the syntex error.

rishabh998186 avatar Dec 22 '25 06:12 rishabh998186

/approve

Thanks for the contribution, @rishabh998186 ! 🎉

droctothorpe avatar Dec 22 '25 13:12 droctothorpe

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: droctothorpe

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

google-oss-prow[bot] avatar Dec 22 '25 13:12 google-oss-prow[bot]

@droctothorpe I think tke LGTM is required to merge this pr. Bot removed the label due to the new commit of syntex error fix . And Thanks for reviewing my pr.

rishabh998186 avatar Dec 22 '25 14:12 rishabh998186

/lgtm

droctothorpe avatar Dec 22 '25 16:12 droctothorpe