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

Documentation of CreateWorkflowDispatchEventByID Doesn't Match GitHub REST API Docs #2262

Closed
kylekurz opened this issue Jan 21, 2022 · 2 comments

Comments

@kylekurz
Copy link
Contributor

In actions_workflows.go, the CreateWorkflowDispatchEventRequest type lists the following documentation of the Ref argument:

// Ref represents the reference of the workflow run.
// The reference can be a branch, tag, or a commit SHA.
// Ref is required when creating a workflow dispatch event.
Ref string `json:"ref"`

However, GitHub's REST API restricts that ref to just a branch or tag name. We initially thought we could build against a specific commit due to this documentation, but further investigation after a failure shows that's not accurate:

ref | string | body | Required. The git reference for the workflow. The reference can be a branch or tag name.
@gmlewis
Copy link
Collaborator

gmlewis commented Jan 21, 2022

Thank you, @kylekurz ! So it sounds like the comment needs to be updated to match the official docs.

This would be a great PR for any new contributor to this repo or a new Go developer.
All contributions are greatly appreciated!

Feel free to volunteer for any issue and the issue can be assigned to you so that others don't attempt to duplicate the work.

Please check out our CONTRIBUTING.md guide to get started. (In particular, please remember to go generate ./... and don't use force-push to your PRs.)

Thank you!

@kylekurz
Copy link
Contributor Author

Thanks @gmlewis, happy to throw a PR at you for just editing that comment to match GitHub's docs. I'll tackle that this afternoon.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants