kubevela/velaux

Cannot add user to project

Pacman99 opened this issue · 7 comments

Describe the bug

If I copy the platform generated username for a SSO user, and try and use the "add member" button in a project to add the user I get the following error:
Key: 'AddProjectUserRequest.UserName' Error:Field validation for 'UserName' failed on the 'checkname' tag

I noticed that the html of the page has a maxLength key for the input field at 32, but the generated usernames are longer than 32 digits. So I removed that field and tried again but I get the same error.

To Reproduce

Steps to reproduce the behavior:

  1. Get userid of a generated user from SSO
  2. Go to a project's members page and click "add member"
  3. paste the username (or inspect, remove maxLength field and paste username)
  4. select a role
  5. click create

Expected behavior
The user should be added as a member of the project

Screenshots

KubeVela Version
velaux version: v1.8.0
vela-core version: v1.7.5

Additional context

Yes, the name max length is 32. This is the validation in the API server.

So then how do I have users with names that are over 32? These users ids were automatically made by velaux when logging in with SSO, so I had no choice in their length.

@Pacman99 What connector do you configure? VelaUX generates the user name by the sub of id-token

I'm using the google connector

Thanks for the fix! When will an image with the fix be pushed?

Thanks for the fix! When will an image with the fix be pushed?

1.8.1 has already been released.

amazing thank you!