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

state_reason missing from rest api issue docs #19593

Closed
1 task done
tjenkinson opened this issue Aug 8, 2022 · 16 comments
Closed
1 task done

state_reason missing from rest api issue docs #19593

tjenkinson opened this issue Aug 8, 2022 · 16 comments
Labels
content This issue or pull request belongs to the Docs Content team issues Content related to issues rest Content related to rest - overview. waiting for review Issue/PR is waiting for a writer's review

Comments

@tjenkinson
Copy link
Contributor

tjenkinson commented Aug 8, 2022

Code of Conduct

What article on docs.github.com is affected?

https://octokit.github.io/rest.js/v18#issues-update https://docs.github.com/en/rest/issues/issues#update-an-issue and probably some of the other issue entries too.

What part(s) of the article would you like to see updated?

state_reason mentioned in https://github.blog/changelog/2022-05-19-the-new-github-issues-may-19th-update/ should be documented.

refs probot/stale#379
refs actions/stale#744

Additional information

It looks like it's actually there but not sure why it's not ended up in the generated page?

"state_reason": {
  "description": "The reason for the current state",
  "type": [
    "string",
    "null"
  ],
  "examples": [
    "not_planned"
  ]
}

is in lib/rest/static/decorated/api.github.com.json.

@tjenkinson tjenkinson added the content This issue or pull request belongs to the Docs Content team label Aug 8, 2022
@welcome
Copy link

welcome bot commented Aug 8, 2022

Thanks for opening this issue. A GitHub docs team member should be by to give feedback soon. In the meantime, please check out the contributing guidelines.

@github-actions github-actions bot added the triage Do not begin working on this issue until triaged by the team label Aug 8, 2022
@cmwilson21
Copy link
Contributor

@tjenkinson Thanks so much for opening an issue! I'll triage this for the team to take a look 👀

@cmwilson21 cmwilson21 added waiting for review Issue/PR is waiting for a writer's review issues Content related to issues rest Content related to rest - overview. and removed triage Do not begin working on this issue until triaged by the team labels Aug 9, 2022
@janiceilene
Copy link
Contributor

👋 @tjenkinson If I'm understanding correctly, you're looking to update the Octokit docs, which we don't own. You can open an issue in https://github.com/octokit to request an Octokit update.

It looks like we document this feature in https://docs.github.com/en/issues/tracking-your-work-with-issues/closing-an-issue on the GitHub Docs. I'm going to close this now, but please let me know if I'm misunderstanding your request 💛

Thanks so much for your interest and passion in improving the GitHub Docs ⚡

@tjenkinson
Copy link
Contributor Author

tjenkinson commented Aug 23, 2022

Ah @janiceilene I put the wrong link. I meant https://docs.github.com/en/rest/issues/issues#update-an-issue

Looks like an issue should be opened on octokit too though (although I think that might scrape these docs)

@janiceilene janiceilene reopened this Aug 23, 2022
@github-actions github-actions bot added the triage Do not begin working on this issue until triaged by the team label Aug 23, 2022
@janiceilene
Copy link
Contributor

That makes sense! Thanks for the clarification @tjenkinson I'll put this back on the review board for our rest folks to check out 💖

@cmwilson21 cmwilson21 added rest-description and removed triage Do not begin working on this issue until triaged by the team labels Aug 23, 2022
@docubot
Copy link
Contributor

docubot commented Aug 23, 2022

Thank you for opening this issue! Updates to the REST/GraphQL API description must be made internally. I have copied your issue to an internal issue, so I will close this issue.

@docubot docubot closed this as completed Aug 23, 2022
@skedwards88
Copy link
Contributor

Thanks for this issue! If you navigate to the response schema instead of the example response, you will see the state_reason field as expected. This field isn't required and isn't part of the example response, so you don't see it in the example response.

image

@tjenkinson
Copy link
Contributor Author

Hi @skedwards88 for the update command though for the input it says

State of the issue. Either open or closed.
Can be one of: open, closed

So it’s not documented for the request?

@tjenkinson
Copy link
Contributor Author

@skedwards88 just checking if you saw my reply and if the internal ticket been updated?

@skedwards88
Copy link
Contributor

Thanks for clarifying. I thought you were talking about the response, but I understand now that you are pointing out that this is missing from the request parameters. I'll open an issue for the owning team.

@skedwards88
Copy link
Contributor

state_reason is now documented in the request body as well. Thanks again for this issue!

image

@tjenkinson
Copy link
Contributor Author

Thanks! Is the only supported value right now not_planned?

@skedwards88
Copy link
Contributor

Thanks for your thoroughness. I followed up with the team to ask the to define this as an enum and to list the allowed values.

@chouetz
Copy link

chouetz commented Dec 30, 2022

Hi @skedwards88
sorry to jump back on this issue, I have a question regarding the state_reason.
While trying to work on a related issue, I noticed state_reason cannot be changed alone, and needs an update of state. Do you think this could be mentioned in the state_reason description in the update-an-issue REST API documentation? Something like


state_reason string or null
The reason for the current state. NOTE: Can only be updated alongside with a state update
Can be one of: completed, not_planned, reopened,


Many thanks in advance

@cmwilson21
Copy link
Contributor

Hello @chouetz! Would you mind opening a new issue for your question? That way I can add it to the board for the team to take a look. 💖

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
content This issue or pull request belongs to the Docs Content team issues Content related to issues rest Content related to rest - overview. waiting for review Issue/PR is waiting for a writer's review
Projects
None yet
Development

No branches or pull requests

8 participants
@tjenkinson @janiceilene @chouetz @skedwards88 @docubot @cmwilson21 and others