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

Use login instead of name in the GitHub scopes/username request #537

Merged
merged 1 commit into from
Aug 1, 2023

Conversation

vinokurig
Copy link
Contributor

What does this PR do?

Change user.getName() to user.getLogin() in the GitHub getTokenScopes() API request, in order to fix a bug where NullPointer exception is appeared when a GitHub user request returns a user with null in the name field.

Screenshot/screencast of this PR

What issues does this PR fix or reference?

fixes eclipse-che/che#22413

How to test this PR?

  1. In your GitHub profile clear the Name input and hit Save
  2. In your user namespace remove next secrets:
  • personal-access-token-****
  • git-credentials-secret-****
  • devworkspace-merged-git-credentials
  1. Apply GitHub OAuth
  2. Start a workspace from GitHub repo

PR Checklist

As the author of this Pull Request I made sure that:

Reviewers

Reviewers, please comment how you tested the PR when approving it.

@ibuziuk
Copy link
Member

ibuziuk commented Aug 1, 2023

Please, backport to 7.72.x for 3.8 once merged

@vinokurig
Copy link
Contributor Author

/retest

Copy link
Member

@ScrewTSW ScrewTSW left a comment

Choose a reason for hiding this comment

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

Verified with quay.io/eclipse/che-server:pr-537

Added personal access token (classic)
Verified workspace creation from private repository using both ssh and https.

@openshift-ci
Copy link

openshift-ci bot commented Aug 1, 2023

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: ibuziuk, ScrewTSW, tolusha, 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

@vinokurig vinokurig merged commit 0ea20e6 into main Aug 1, 2023
4 checks passed
@vinokurig vinokurig deleted the che-22413 branch August 1, 2023 18:36
vinokurig added a commit that referenced this pull request Aug 1, 2023
…537)

Change user.getName() to user.getLogin() in the GitHub getTokenScopes() API request, in order to fix a bug where NullPointer exception is appeared when a GitHub user request returns a user with null in the name field.
@vinokurig
Copy link
Contributor Author

@ibuziuk

Please, backport to 7.72.x for 3.8 once merged

done

@devstudio-release
Copy link

Build 3.9 :: server_3.x/191: Console, Changes, Git Data

@devstudio-release
Copy link

@devstudio-release
Copy link

@devstudio-release
Copy link

@devstudio-release
Copy link

@devstudio-release
Copy link

Build 3.9 :: server_3.x/191: SUCCESS

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

@devstudio-release
Copy link

Build 3.9 :: update-digests_3.x/3857: Console, Changes, Git Data

@devstudio-release
Copy link

@devstudio-release
Copy link

@devstudio-release
Copy link

@devstudio-release
Copy link

@devstudio-release
Copy link

Build 3.9 :: copyIIBsToQuay/1615: Console, Changes, Git Data

@devstudio-release
Copy link

Build 3.9 :: sync-to-downstream_3.x/3907: SUCCESS

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

@devstudio-release
Copy link

Build 3.9 :: operator-bundle_3.x/1679: SUCCESS

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

@devstudio-release
Copy link

Build 3.9 :: update-digests_3.x/3857: SUCCESS

Detected new images: rebuild operator-bundle
* code
* configbump
* dashboard
* devfileregistry
* devspaces-operator
* machineexec
* pluginregistry
* server
* traefik
* udi; /DS_CI/operator-bundle_3.x/1679 triggered

@devstudio-release
Copy link

Build 3.9 :: dsc_3.x/1105: Console, Changes, Git Data

@devstudio-release
Copy link

Build 3.9 :: server_3.x/192: Console, Changes, Git Data

@devstudio-release
Copy link

@devstudio-release
Copy link

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

Successfully merging this pull request may close these issues.

"Backend is not available" error when Sign in to the dogfooding instance
5 participants