-
Notifications
You must be signed in to change notification settings - Fork 10
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
feat: remove ruleset objects, various description updates #367
Conversation
Interestingly, the tests are failing due to an invalid JSON description. Here's the offending material in JSON snippet
"/orgs/{org}/blocks/{username}": {
"get": {
"summary": "Check if a user is blocked by an organization",
"description": "Returns a 204 if the given user is blocked by the given organization. Returns a 404 if the organization is not blocking the user, or if the user account has been identified as spam by GitHub.",
"tags": [
"orgs"
],
"operationId": "orgs/check-blocked-user",
"externalDocs": {
"description": "API method documentation",
"url": "https://docs.github.com/rest/reference/orgs#check-if-a-user-is-blocked-by-an-organization"
},
"parameters": [
{
"name": "org",
"description": "The organization name. The name is not case sensitive.",
"in": "path",
"required": true,
"schema": {
"type": "string"
}
},
"304": {
"description": "Not modified"
},
"401": {
"description": "Requires authentication",
"content": {
"application/json": {
"schema": {
"title": "Basic Error",
"description": "Basic Error",
"type": "object",
"properties": {
"message": {
"type": "string"
},
"documentation_url": {
"type": "string"
},
"url": {
"type": "string"
},
"status": {
"type": "string"
}
}
}
}
}
}
},
"x-github": {
"githubCloudOnly": false,
"enabledForGitHubApps": true,
"category": "orgs",
"subcategory": "blocking"
},
"x-octokit": {}
},
"put": {
"summary": "Block a user from an organization",
"description": "Blocks the given user on behalf of the specified organization and returns a 204. If the organization cannot block the given user a 422 is returned.",
"tags": [
"orgs"
],
"operationId": "orgs/block-user",
"externalDocs": {
"description": "API method documentation",
"url": "https://docs.github.com/rest/reference/orgs#block-a-user-from-an-organization"
},
"parameters": [
{
"name": "org",
"description": "The organization name. The name is not case sensitive.",
"in": "path",
"required": true,
"schema": {
"type": "string"
}
},
"404": {
"description": "Resource not found",
"content": {
"application/json": {
"schema": {
"title": "Basic Error",
"description": "Basic Error",
"type": "object",
"properties": {
"message": {
"type": "string"
},
"documentation_url": {
"type": "string"
},
"url": {
"type": "string"
},
"status": {
"type": "string"
}
}
}
}
}
},
"500": {
"description": "Internal Error",
"content": {
"application/json": {
"schema": {
"title": "Basic Error",
"description": "Basic Error",
"type": "object",
"properties": {
"message": {
"type": "string"
},
"documentation_url": {
"type": "string"
},
"url": {
"type": "string"
},
"status": {
"type": "string"
}
}
}
}
}
}
}, Here's the other offense, from JSON snippet
"/orgs/{org}/packages": {
"get": {
"summary": "List packages for an organization",
"description": "Lists packages in an organization readable by the user.\n\nTo use this endpoint, you must authenticate using an access token with the `read:packages` scope. If the `package_type` belongs to a registry that only supports repository-scoped permissions, your token must also include the `repo` scope. For the list of GitHub Packages registries that only support repository-scoped permissions, see \"[About permissions for GitHub Packages](https://docs.github.com/enterprise-cloud@latest//packages/learn-github-packages/about-permissions-for-github-packages#permissions-for-repository-scoped-packages).\"",
"tags": [
"packages"
],
"operationId": "packages/list-packages-for-organization",
"externalDocs": {
"description": "API method documentation",
"url": "https://docs.github.com/enterprise-cloud@latest//rest/reference/packages#list-packages-for-an-organization"
},
"parameters": [
{
"name": "package_type",
"description": "The type of supported package. Packages in GitHub's Gradle registry have the type `maven`. Docker images pushed to GitHub's Container registry (`ghcr.io`) have the type `container`. You can use the type `docker` to find images that were pushed to GitHub's Docker registry (`docker.pkg.github.com`), even if these have now been migrated to the Container registry.",
"in": "query",
"required": true,
"schema": {
"type": "string",
"enum": [
"npm",
"maven",
"rubygems",
"docker",
"nuget",
"container"
]
}
},
{
"name": "org",
"description": "The organization name. The name is not case sensitive.",
"in": "path",
"required": true,
"schema": {
"type": "string"
}
},
{
"name": "visibility",
"description": "The selected visibility of the packages. This parameter is optional and only filters an existing result set.\n\nThe `internal` visibility is only supported for GitHub Packages registries that allow for granular permissions. For other ecosystems `internal` is synonymous with `private`.\nFor the list of GitHub Packages registries that support granular permissions, see \"[About permissions for GitHub Packages](https://docs.github.com/enterprise-cloud@latest//packages/learn-github-packages/about-permissions-for-github-packages#granular-permissions-for-userorganization-scoped-packages).\"",
"in": "query",
"required": false,
"schema": {
"type": "string",
"enum": [
"public",
"private",
"internal"
]
}
},
{
"name": "page",
"description": "Page number of the results to fetch.",
"in": "query",
"schema": {
"type": "integer",
"default": 1
}
},
{
"name": "per_page",
"description": "The number of results per page (max 100).",
"in": "query",
"schema": {
"type": "integer",
"default": 30
}
}
},
"responses": { These are both org endpoints, though they are different ones so it seems unlikely the error is due to a root schema issue. More investigation here is required. |
@gr2m I'd like to ask you for advice about how I might troubleshoot this further if that's okay! |
The problem seems to be that the path |
It's not the case at https://raw.githubusercontent.com/github/rest-api-description/main/descriptions/api.github.com/api.github.com.json, so I'm not sure what's happening |
Also this is invalid JSON:
An array item can be |
Running |
Perhaps #364 should be merged before this PR is merged. |
There appear to be more issues with ghes-3.8-diff-to-ghes-3.9.json.
|
I found new changes in GitHub's official OpenAPI specifications and thought I'd let you know about it 👋🤖
I can't tell if the changes include fixes, features, breaking changes or just cache updates, you'll have to figure that out on yourself and adapt the commit messages accordingly to trigger the right release, see our commit message conventions.