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

feat: Force refresh personal access token #1137

Merged
merged 5 commits into from
Jun 27, 2024
Merged

feat: Force refresh personal access token #1137

merged 5 commits into from
Jun 27, 2024

Conversation

tolusha
Copy link
Contributor

@tolusha tolusha commented Jun 26, 2024

What does this PR do?

feat: Force refresh personal access token

What issues does this PR fix or reference?

eclipse-che/che#23005

Is it tested? How?

N/A

Release Notes

N/A

Docs PR

N/A

Signed-off-by: Anatolii Bazko <abazko@redhat.com>
Copy link

openshift-ci bot commented Jun 26, 2024

Skipping CI for Draft Pull Request.
If you want CI signal for your change, please convert it to an actual PR.
You can still manually trigger a test run with /test all

@che-bot
Copy link
Contributor

che-bot commented Jun 26, 2024

Click here to review and test in web IDE: Contribute

Copy link

codecov bot commented Jun 26, 2024

Codecov Report

Attention: Patch coverage is 77.77778% with 2 lines in your changes missing coverage. Please review.

Project coverage is 89.58%. Comparing base (28abf62) to head (09d4eb1).
Report is 5 commits behind head on main.

Files Patch % Lines
...ges/dashboard-frontend/src/services/oauth/index.ts 75.00% 0 Missing and 2 partials ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1137      +/-   ##
==========================================
- Coverage   89.61%   89.58%   -0.04%     
==========================================
  Files         411      411              
  Lines       41920    41976      +56     
  Branches     2809     2825      +16     
==========================================
+ Hits        37566    37603      +37     
- Misses       4329     4344      +15     
- Partials       25       29       +4     

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

@tolusha tolusha marked this pull request as ready for review June 27, 2024 07:01
tolusha and others added 4 commits June 27, 2024 09:25
Signed-off-by: Anatolii Bazko <abazko@redhat.com>
Signed-off-by: Anatolii Bazko <abazko@redhat.com>
Signed-off-by: Anatolii Bazko <abazko@redhat.com>
Signed-off-by: Oleksii Orel <oorel@redhat.com>
Copy link

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

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-1137", name: che-dashboard}]}}]"

if (!project || !project.git) {
return;
}
static async refreshTokenIfProjectExists(workspace: devfileApi.DevWorkspace): Promise<void> {
Copy link
Member

Choose a reason for hiding this comment

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

@tolusha I'm a bit lost, why project presence in devfile is indicator for token refresh ?

Copy link
Member

Choose a reason for hiding this comment

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

at the very least, would be great to have some comment with method description

Copy link
Contributor Author

Choose a reason for hiding this comment

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

We need a repository url to figure out the correct OAuth provider.


try {
await refreshFactoryOauthToken(project.git.remotes.origin);
if (project) {
await refreshFactoryOauthToken(project.git!.remotes.origin);
Copy link
Member

Choose a reason for hiding this comment

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

is it expected change?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yes

@tolusha
Copy link
Contributor Author

tolusha commented Jun 27, 2024

/test v14-dashboard-happy-path

Copy link

openshift-ci bot commented Jun 27, 2024

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: ibuziuk, olexii4, tolusha

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

@tolusha tolusha merged commit 3991d41 into main Jun 27, 2024
16 of 18 checks passed
@tolusha tolusha deleted the 23005 branch June 27, 2024 14:53
@devstudio-release
Copy link

Build 3.15 :: dashboard_3.15/2: Console, Changes, Git Data

@devstudio-release
Copy link

Build 3.16 :: dashboard_3.x/503: 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

@devstudio-release
Copy link

Build 3.16 :: dashboard_3.x/503: SUCCESS

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

@devstudio-release
Copy link

@devstudio-release
Copy link

@devstudio-release
Copy link

@devstudio-release
Copy link

Build 3.16 :: get-sources-rhpkg-container-build_3.x/6931: FAILURE

devspaces-operator-bundle : 3.x :: Failed in 62237807 : BREW:BUILD/STATUS:UNKNOWN
FAILURE:; copied to quay

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
5 participants