Skip to content

SRVKP-6343: Console crashes when ssh is selected in add secret for starting a pipeline run #155

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

Conversation

lokanandaprabhu
Copy link
Member

Fixes:
https://issues.redhat.com/browse/SRVKP-6343

Analysis / Root cause:
withDragDropContext is not exposed to dynamic plugins. In start pipeline form, user can create secret, there again, another HTML5Backend was getting created and this lead to "Cannot have two HTML5 backends at the same time." error.

Ideally DroppableFileInput and TextColumnField should be exposed to dynamic plugins which internally uses DND but since these components are not exposed, this change is required to set the context to window.

Solution Description:
HTML5Backend is passed directly as backend prop to DndProvider instead of manager prop and the context is set to window

Screen shots / Gifs for design review:

----BEFORE---

Screen.Recording.2024-09-12.at.11.08.12.AM.mov

---AFTER----

Screen.Recording.2024-09-12.at.11.10.00.AM.mov

Unit test coverage report:
NA

Test setup:

NOTE: To test this PR, console PR - openshift/console#14282 to be merged 1st.

1. Install pipelines operator and enable dynamic plugin
2. Create a pipeline through add flow and open start pipeline page in developer perspective
3. Under show credentials select add secret
4. In the secret form select `Access to ` as Git server and `Authentication type` as SSH key

Browser conformance:

  • Chrome
  • Firefox
  • Safari
  • Edge

@openshift-ci-robot
Copy link
Collaborator

openshift-ci-robot commented Sep 12, 2024

@lokanandaprabhu: This pull request references SRVKP-6343 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 either version "4.18." or "openshift-4.18.", but it targets "Pipelines 1.16.0" instead.

In response to this:

Fixes:
https://issues.redhat.com/browse/SRVKP-6343

Analysis / Root cause:
withDragDropContext is not exposed to dynamic plugins. In start pipeline form, user can create secret, there again, another HTML5Backend was getting created and this lead to "Cannot have two HTML5 backends at the same time." error.

Ideally DroppableFileInput and TextColumnField should be exposed to dynamic plugins which internally uses DND but since these components are not exposed, this change is required to set the context to window.

Solution Description:
HTML5Backend is passed directly as backend prop to DndProvider instead of manager prop and the context is set to window

Screen shots / Gifs for design review:

----BEFORE---

Screen.Recording.2024-09-12.at.11.08.12.AM.mov

---AFTER----

Screen.Recording.2024-09-12.at.11.10.00.AM.mov

Unit test coverage report:
NA

Test setup:

NOTE: To test this PR, console PR - openshift/console#14282 to be merged 1st.

  1. Install pipelines operator and enable dynamic plugin
  2. Create a pipeline through add flow and open start pipeline page in developer perspective
  3. Under show credentials select add secret
  4. In the secret form select Access to as Git server and Authentication type as SSH key

Browser conformance:

  • Chrome
  • Firefox
  • Safari
  • Edge

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.

Copy link
Contributor

openshift-ci bot commented Sep 12, 2024

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: lokanandaprabhu

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

@lokanandaprabhu
Copy link
Member Author

/cc @vikram-raj

@openshift-ci openshift-ci bot requested a review from vikram-raj September 12, 2024 05:54
Copy link
Member

@vikram-raj vikram-raj left a comment

Choose a reason for hiding this comment

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

/lgtm

@vikram-raj
Copy link
Member

/cherry-pick release-v1.15.x

@openshift-cherrypick-robot

@vikram-raj: once the present PR merges, I will cherry-pick it on top of release-v1.15.x in a new PR and assign it to you.

In response to this:

/cherry-pick release-v1.15.x

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-sigs/prow repository.

@openshift-merge-bot openshift-merge-bot bot merged commit f41961b into openshift-pipelines:main Sep 13, 2024
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants