Skip to content

Does not support validating Enterprise SSO users #207

@lukasz-mitka

Description

@lukasz-mitka

Description
Validation fails on checking valid enterprise sso users
Example: @user-name-can-be-very-long_and-has-underscore

Validation fails after adding SSO user to CODEOWNERS file.

Expected result
User should be validated successfully.

Actual result
Fails with

Owner @user_id does not look like a GitHub username or team name

Steps to reproduce
Add * @user_id to CODEOWNERS file

Troubleshooting
Here's the regex that doesn't match it.

usernameOrTeamRegexp = regexp.MustCompile(`^@(?i:[a-z\d](?:[a-z\d-]){0,37}[a-z\d](/[a-z\d](?:[a-z\d_-]*)[a-z\d])?)$`)

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions