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

Milestone is missing ID #1970

Closed
patriksvensson opened this issue Jun 18, 2019 · 5 comments · Fixed by #2007
Closed

Milestone is missing ID #1970

patriksvensson opened this issue Jun 18, 2019 · 5 comments · Fixed by #2007
Labels
Status: Up for grabs Issues that are ready to be worked on by anyone Type: Bug Something isn't working as documented

Comments

@patriksvensson
Copy link
Contributor

It looks like Id is missing from Octokit.Milestone.

API example can be seen here: https://developer.github.com/v3/pulls/#get-a-single-pull-request

@shiftkey
Copy link
Member

@patriksvensson what did you need Id for? I believe that's an internal identifier for it, and Number is the public-facing ID that you should use when querying, based on https://developer.github.com/v3/issues/milestones/#get-a-single-milestone

@patriksvensson
Copy link
Contributor Author

I use it as an external identifier in a GitHub client i'm building.

What is the practice when it comes to expose the id field? A lot of other entities in the Octokit API exposes it (label, issue, pullrequest) and it's part of the public API.

I would gladly submit a PR for this.

@shiftkey
Copy link
Member

What is the practice when it comes to expose the id field?

Some entities can be queried for using the id, but the only entity I can think of where this is explicitly support is for repositories and users - because they can renamed or transferred, integrators can query for that as it's considered more "stable". You'll also see these URLs in the pagination response to indicate there are more results, but it's not used much these days.

But for repository-specific entities (issues, labels, milestones, etc) I don't believe the same lookup was ever implemented.

I would gladly submit a PR for this.

I'm not opposed to this, but I just wanted to indicate that the field is not what is used in the API itself.

cc @ryangribble just in case.

@ryangribble
Copy link
Contributor

If it's in the public API response payload I don't mind having it implemented here for completeness

@hnrkndrssn
Copy link
Contributor

@patriksvensson would you still like to submit a PR for this? Otherwise, I'll be happy to tackle it over the weekend.

@nickfloyd nickfloyd added Type: Bug Something isn't working as documented Status: Up for grabs Issues that are ready to be worked on by anyone and removed category: bug labels Oct 26, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Status: Up for grabs Issues that are ready to be worked on by anyone Type: Bug Something isn't working as documented
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants