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

Error check improvement #857

Merged
merged 1 commit into from
May 14, 2024
Merged

Error check improvement #857

merged 1 commit into from
May 14, 2024

Conversation

kohsuke
Copy link
Member

@kohsuke kohsuke commented May 13, 2024

An experienced customer experiemented with the CLI locally to try out a new command. Upon seeing the --session option, they assumed they just need to pass a test session ID, so they ended up invoking something like launchable foo bar --session 12345

That is a good assumption on their part, but it's actually incorrect, as the ID format we take is more complicated. However, there's no error check, so the CLI resulted in 404, which misled them.

By adding parse_session, we can make sure the ID given from the command line is in the correct format, and fail gracefully if not.

@kohsuke kohsuke requested a review from Konboi May 13, 2024 20:55
An experienced customer experiemented with the CLI locally to try out a
new command. Upon seeing the --session option, they assumed they just
need to pass a test session ID, so they ended up invoking something like
`launchable foo bar --session 12345`

That is a good assumption on their part, but it's actually incorrect, as
the ID format we take is more complicated. However, there's no error
check, so the CLI resulted in 404, which misled them.

By adding parse_session, we can make sure the ID given from the command
line is in the correct format, and fail gracefully if not.
Copy link

sonarcloud bot commented May 13, 2024

Quality Gate Passed Quality Gate passed

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
No data about Coverage
0.0% Duplication on New Code

See analysis details on SonarCloud

@kohsuke kohsuke merged commit 83e5cc7 into main May 14, 2024
15 checks passed
@kohsuke kohsuke deleted the session-error-check branch May 14, 2024 01:22
@github-actions github-actions bot mentioned this pull request May 14, 2024
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.

None yet

2 participants