Skip to content
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

Add whitespace to the is Http check regex pattern #1150

Merged
merged 2 commits into from
Jul 24, 2024
Merged

Add whitespace to the is Http check regex pattern #1150

merged 2 commits into from
Jul 24, 2024

Conversation

vinokurig
Copy link
Contributor

What does this PR do?

Add whitespace to the isHttpLocation check regex pattern.

What issues does this PR fix or reference?

https://issues.redhat.com/browse/CRW-6790

Is it tested? How?

Try to start a workspace from a repository url with whitespace, e.g. https://vinokurig@dev.azure.com/vinokurig/public/_git/re po

Release Notes

Docs PR

@che-bot
Copy link
Contributor

che-bot commented Jul 22, 2024

Click here to review and test in web IDE: Contribute

Copy link

Docker image build succeeded: quay.io/eclipse/che-dashboard:pr-1150

kubectl patch command
kubectl patch -n eclipse-che "checluster/eclipse-che" --type=json -p="[{"op": "replace", "path": "/spec/components/dashboard/deployment", "value": {containers: [{image: "quay.io/eclipse/che-dashboard:pr-1150", name: che-dashboard}]}}]"

Copy link

codecov bot commented Jul 22, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 89.60%. Comparing base (a288cf3) to head (0bd3535).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1150      +/-   ##
==========================================
+ Coverage   89.46%   89.60%   +0.14%     
==========================================
  Files         415      415              
  Lines       42461    42461              
  Branches     2831     2832       +1     
==========================================
+ Hits        37987    38049      +62     
+ Misses       4443     4385      -58     
+ Partials       31       27       -4     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@@ -54,7 +54,7 @@ export class FactoryLocationAdapter implements FactoryLocation {
}

public static isHttpLocation(href: string): boolean {
return /^(https?:\/\/.)[-a-zA-Z0-9@:%._+~#=]{2,}\b([-a-zA-Z0-9@:%_+.~#?&/={},]*)$/.test(href);
return /^(https?:\/\/.)[-a-zA-Z0-9@:%._+~#=]{2,}\b([-a-zA-Z0-9@:%_+.~#?&/={}, ]*)$/.test(href);
Copy link
Member

Choose a reason for hiding this comment

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

@vinokurig could you please add a unit test for that ?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

done

@artaleks9
Copy link
Contributor

Verified on Eclipse Che with quay.io/eclipse/che-dashboard:pr-1150 - the functionality works properly.

Copy link

openshift-ci bot commented Jul 23, 2024

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: akurinnoy, artaleks9, vinokurig

The full list of commands accepted by this bot can be found 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

@openshift-ci openshift-ci bot removed the lgtm label Jul 24, 2024
Copy link

openshift-ci bot commented Jul 24, 2024

New changes are detected. LGTM label has been removed.

Copy link

Docker image build succeeded: quay.io/eclipse/che-dashboard:pr-1150

kubectl patch command
kubectl patch -n eclipse-che "checluster/eclipse-che" --type=json -p="[{"op": "replace", "path": "/spec/components/dashboard/deployment", "value": {containers: [{image: "quay.io/eclipse/che-dashboard:pr-1150", name: che-dashboard}]}}]"

@vinokurig vinokurig merged commit 9f4e348 into main Jul 24, 2024
18 checks passed
@vinokurig vinokurig deleted the CRW-6790 branch July 24, 2024 08:44
@devstudio-release
Copy link

Build 3.16 :: dashboard_3.x/511: Console, Changes, Git Data

@devstudio-release
Copy link

@devstudio-release
Copy link

@devstudio-release
Copy link

@devstudio-release
Copy link

@devstudio-release
Copy link

@devstudio-release
Copy link

Build 3.16 :: dashboard_3.x/511: SUCCESS

Upstream sync done; /DS_CI/sync-to-downstream_3.x/7300 triggered

@devstudio-release
Copy link

@devstudio-release
Copy link

@devstudio-release
Copy link

@devstudio-release
Copy link

@devstudio-release
Copy link

Build 3.16 :: copyIIBsToQuay/2712: Console, Changes, Git Data

@devstudio-release
Copy link

Build 3.16 :: sync-to-downstream_3.x/7302: SUCCESS

Build container: devspaces-operator-bundle synced; /DS_CI/get-sources-rhpkg-container-build_3.x/7281 triggered; /job/DS_CI/job/dsc_3.x triggered;

@devstudio-release
Copy link

Build 3.16 :: operator-bundle_3.x/3353: SUCCESS

Upstream sync done; /DS_CI/sync-to-downstream_3.x/7302 triggered

@devstudio-release
Copy link

Build 3.16 :: dsc_3.x/1950: Console, Changes, Git Data

@devstudio-release
Copy link

Build 3.16 :: update-digests_3.x/7126: SUCCESS

Detected new images: rebuild operator-bundle
* dashboard
* devfileregistry; /DS_CI/operator-bundle_3.x/3353 triggered

@devstudio-release
Copy link

Build 3.16 :: dsc_3.x/1950: SUCCESS

3.16.0-CI

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.

6 participants