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

services/kill: make username check case-insensitive #43

Merged
merged 1 commit into from
Mar 11, 2024

Conversation

VallariAg
Copy link
Member

Kill route checks if github_username == run_owner (from paddles).
Github returns username like "JohnDoe" while run-names scheduled via teuthology machines have no capitalisation like "johndoe". This results in error like: ERROR:teuthology_api.services.kill:JohnDoe doesn't have permission to kill a job scheduled by: johndoe

Runs scheduled by teuthology-api would not have above error because they would have run-name capitalised too like "JohnDoe-2024-01-08_10:32:53-teuthology:no-ceph-main-distro-default-testnode".

Contribution Guidelines

To sign and test your commits, please refer to Contibution guidelines.

Checklist

Kill route checks if github_username == run_owner (from paddles).
Github returns username "JohnDoe" while run-names scheduled via teuthology
machines have no captilzation like "johndoe". This results in error like:
`ERROR:teuthology_api.services.kill:JohnDoe doesn't have permission to kill a job scheduled by: johndoe`

Signed-off-by: Vallari Agrawal <[email protected]>
Copy link
Member

@kamoltat kamoltat left a comment

Choose a reason for hiding this comment

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

LGTM!

@VallariAg VallariAg merged commit f0a9d59 into main Mar 11, 2024
4 checks passed
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.

2 participants