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

Simple User Type doesn't have to be null #38

Closed
3 of 7 tasks
mlbonniec opened this issue Apr 17, 2021 · 6 comments
Closed
3 of 7 tasks

Simple User Type doesn't have to be null #38

mlbonniec opened this issue Apr 17, 2021 · 6 comments
Labels
Type: Bug Something isn't working as documented typescript

Comments

@mlbonniec
Copy link

Checklist

Environment

Versions

├── @octokit/rest@18.5.2
├── @octokit/types@6.13.0

What happened?

On the schema, located at components['schemas']['full-repository'] (from '@octokit/openapi-types'), the value of owner can be null. However, a repo has to be owned, so null shouldn't be here.

Capture d’écran 2021-04-18 à 01 54 08

Minimal test case to reproduce the problem

What did you expect to happen?

owner should be only an object, not an object or null

What the problem might be
Just remove null from the declaration file.

@wolfy1339
Copy link
Member

This unfortunately isn't a bug that we can fix ourselves since those types are auto-generated.

I confirmed that this stems from Github's OpenAPI descriptions

I would file a bug report with them and link it back to here: https://github.com/github/rest-api-description/issues/new/choose
Then a staffer/contributor can confirm wether this is intended behaviour or an actual bug

@mlbonniec
Copy link
Author

Ah, alright, thanks for your extremely quick answer!
I'll manage for the moment in my code, I hope it will be fixed quickly (if it's a bug)

@wolfy1339
Copy link
Member

I filed an issue upstream with Github: github/rest-api-description#270

@gr2m gr2m transferred this issue from octokit/octokit.js Apr 18, 2021
@gr2m gr2m added Type: Bug Something isn't working as documented typescript labels Apr 18, 2021
@gr2m gr2m added the Status: Blocked Some technical or requirement is blocking the issue label Apr 18, 2021
@AndrewSouthpaw
Copy link

Looks like the upstream issues may have been resolved, would it be possible to resume work on this?

@wolfy1339
Copy link
Member

Can you try the latest version of @octokit/rest?

The v10.1.2 release of @octokit/types contains the fix.

@wolfy1339 wolfy1339 removed the Status: Blocked Some technical or requirement is blocking the issue label Sep 29, 2021
@wolfy1339
Copy link
Member

Closing as this has been fixed now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Bug Something isn't working as documented typescript
Projects
None yet
Development

No branches or pull requests

4 participants