[Schema Inaccuracy] Get Repository Unavailable for Legal Reasons
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 2/5
- Thời gian dự kiến
- 1-3 giờ
- Mức phù hợp với người mới
- 35/100
- Loại issue
- Tài liệu
- Độ rõ ràng
- Đặc tả rõ ràng
- Mức độ hoạt động
- Đình trệ
- Công nghệ
- github, openapi
- Lĩnh vực
- api, documentation
Hướng nghiên cứu
Bắt đầu với operation GET /repos/{owner}/{repo} và các định nghĩa response được liệt kê trong đó, sau đó so sánh chúng với reproduction gh api --verbose /repositories/239386228. Hoàn thành khi schema mô tả status 451 và các trường trong response body được hiển thị trong issue.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Schema Inaccuracy
When retrieving a repository that is unavailable for legal reasons (e.g. a DMCA takedown request), the GitHub API responds with an HTTP status "451 Unavailable For Legal Reasons" and a response body such as:
{
"message": "Repository access blocked",
"block": {
"reason": "dmca",
"created_at": "2021-04-22T17:53:56Z",
"html_url": "https://github.com/github/dmca/blob/master/2021/04/2021-04-20-ultimate-character-controller.md"
}
}
This response code and error body are not described in the schema.
Relevant schema excerpt:
"/repos/{owner}/{repo}":
get:
summary: Get a repository
description: |-
The `parent` and `source` objects are present when the repository is a fork. `parent` is the repository this repository was forked from, `source` is the ultimate source for the network.
**Note:** In order to see the `security_and_analysis` block for a repository you must have admin permissions for the repository or be an owner or security manager for the organization that owns the repository. For more information, see "[Managing security managers in your organization](https://docs.github.com/organizations/managing-peoples-access-to-your-organization-with-roles/managing-security-managers-in-your-organization)."
tags:
- repos
operationId: repos/get
externalDocs:
description: API method documentation
url: https://docs.github.com/rest/repos/repos#get-a-repository
parameters:
- "$ref": "#/components/parameters/owner"
- "$ref": "#/components/parameters/repo"
responses:
'200':
description: Response
content:
application/json:
schema:
"$ref": "#/components/schemas/full-repository"
examples:
default-response:
"$ref": "#/components/examples/full-repository-default-response"
'403':
"$ref": "#/components/responses/forbidden"
'404':
"$ref": "#/components/responses/not_found"
'301':
"$ref": "#/components/responses/moved_permanently"
Expected
Expected a 451 response description for "Get a repository".
Reproduction Steps
gh api --verbose /repositories/239386228
- Ngôn ngữ chính
- Không có dữ liệu ngôn ngữ
- Star
- 1.6k
- Fork
- 342
- Merge trung bình
- 2 giờ 23 phút
- Pull request đã merge (30 ngày)
- 57
Hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của github/rest-api-description
-
feature
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 85/100
github/rest-api-description#7220 ·
-
feature
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 82/100
github/rest-api-description#7201 ·
-
feature
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
github/rest-api-description#7163 ·
-
Runner deprecations: registration_deprecates_at is declared on the response but never returned Đang mởfeature
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
github/rest-api-description#7162 ·
-
feature
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
github/rest-api-description#7135 ·
Tất cả issue của github/rest-api-description
Issue tương tự
-
Area: Excel support
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
orbeon/orbeon-forms#7893 ·
-
essnmx good first issue
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 95/100
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
yeti-platform/yeti#1380 ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
modelcontextprotocol/python-sdk#3566 ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 70/100
griptape-ai/griptape#2353 ·