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

Undocumented octocrab::models::workflows::Status variant "pending" observed coming from GitHub #574

Closed
ztj opened this issue Feb 9, 2024 · 1 comment · Fixed by #604
Closed

Comments

@ztj
Copy link
Contributor

ztj commented Feb 9, 2024

I've observed through usage that despite the documentation, GitHub sends at least the additional variant of "pending" for a Job's status, or possibly the status of a step. This would be far from the first time I've encountered undocumented or incorrectly documented GitHub API behavior. It manifests in my logs like...

Serde Error: unknown variant `pending`, expected one of `queued`, `in_progress`, `completed`, `failed`

... along with the rest of the snafu context when sending a .workflows(...).list_jobs(...) request.

I'm not really sure how you'd prefer to handle this or I'd probably PR a quick fix. For my part, I'm not even using the status value except to log it, so, the failure here is totally spurious for my use case. I appreciate that this is almost certainly a GitHub screw-up, and I've only seen it once so far, so perhaps it's nothing urgent, but, nonetheless an interesting conundrum to consider when writing a client for a service you have no control over.

@XAMPPRocky
Copy link
Owner

Thank you for your issue! Yes, another variant should be added, I'd be happy to review PR adding it.

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 a pull request may close this issue.

2 participants