mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2026-07-18 07:28:47 +00:00
fix: do not migrate confidential issues and internal notes from Gitlab (#12735)
A dedicated test repository was added at https://gitlab.com/forgejo/test_repo-confidential with one "confidential issue" and two "internal notes". Closes: #12688 Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/12735 Reviewed-by: oliverpool <oliverpool@noreply.codeberg.org> Reviewed-by: Gusted <gusted@noreply.codeberg.org>
This commit is contained in:
parent
6c85dffb78
commit
44b93ff7cc
14 changed files with 381 additions and 3 deletions
|
|
@ -430,6 +430,14 @@ func (g *GitlabDownloader) GetIssues(page, perPage int) ([]*base.Issue, bool, er
|
|||
return nil, false, fmt.Errorf("error while listing issues: %w", err)
|
||||
}
|
||||
for _, issue := range issues {
|
||||
// record the issue IID, to be used in GetPullRequests()
|
||||
g.iidResolver.recordIssueIID(issue.IID)
|
||||
|
||||
// Do not include confidential issues as long as Forgejo does not support them, see https://codeberg.org/forgejo/design/issues/2
|
||||
if issue.Confidential {
|
||||
continue
|
||||
}
|
||||
|
||||
labels := make([]*base.Label, 0, len(issue.Labels))
|
||||
for _, l := range issue.Labels {
|
||||
labels = append(labels, &base.Label{
|
||||
|
|
@ -459,9 +467,6 @@ func (g *GitlabDownloader) GetIssues(page, perPage int) ([]*base.Issue, bool, er
|
|||
awardPage++
|
||||
}
|
||||
|
||||
// record the issue IID, to be used in GetPullRequests()
|
||||
g.iidResolver.recordIssueIID(issue.IID)
|
||||
|
||||
allIssues = append(allIssues, &base.Issue{
|
||||
Title: issue.Title,
|
||||
Number: int64(issue.IID),
|
||||
|
|
@ -517,6 +522,9 @@ func (g *GitlabDownloader) GetComments(commentable base.Commentable) ([]*base.Co
|
|||
}
|
||||
for _, comment := range comments {
|
||||
for _, note := range comment.Notes {
|
||||
if note.Internal {
|
||||
continue
|
||||
}
|
||||
allComments = append(allComments, g.convertNoteToComment(commentable.GetLocalIndex(), note))
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -839,3 +839,73 @@ func TestCommentBodyParser(t *testing.T) {
|
|||
assert.Equal(t, "!21 and !11 are simillar but !211 and !110 are not!", parsedBody6)
|
||||
assert.Equal(t, "Simillar to #9, may be solved in !14", parsedBody7)
|
||||
}
|
||||
|
||||
func TestGitlabConfidential(t *testing.T) {
|
||||
// If a GitLab access token is provided, this test will make HTTP requests to the live gitlab.com instance.
|
||||
// When doing so, the responses from gitlab.com will be saved as test data files.
|
||||
// If no access token is available, those cached responses will be used instead.
|
||||
gitlabPersonalAccessToken := os.Getenv("GITLAB_READ_TOKEN")
|
||||
fixturePath := "./testdata/gitlab/confidential"
|
||||
server := unittest.NewMockWebServer(t, "https://gitlab.com", fixturePath, gitlabPersonalAccessToken != "")
|
||||
defer server.Close()
|
||||
|
||||
downloader, err := NewGitlabDownloader(t.Context(), server.URL, "forgejo/test_repo-confidential", "", "", gitlabPersonalAccessToken)
|
||||
if err != nil {
|
||||
t.Fatalf("NewGitlabDownloader is nil: %v", err)
|
||||
}
|
||||
repo, err := downloader.GetRepoInfo()
|
||||
require.NoError(t, err)
|
||||
// Repo Owner is blank in Gitlab Group repos
|
||||
assertRepositoryEqual(t, &base.Repository{
|
||||
Name: "test_repo-confidential",
|
||||
Owner: "",
|
||||
Description: "",
|
||||
CloneURL: server.URL + "/forgejo/test_repo-confidential.git",
|
||||
OriginalURL: server.URL + "/forgejo/test_repo-confidential",
|
||||
DefaultBranch: "main",
|
||||
}, repo)
|
||||
|
||||
issues, isEnd, err := downloader.GetIssues(1, 10)
|
||||
require.NoError(t, err)
|
||||
assert.True(t, isEnd)
|
||||
|
||||
// the only issue in this repository has number 1, confidential issue with number 2 is skipped
|
||||
assert.Len(t, issues, 1)
|
||||
assert.EqualValues(t, 1, issues[0].Number)
|
||||
assert.Equal(t, "Normal issue", issues[0].Title)
|
||||
|
||||
prs, _, err := downloader.GetPullRequests(1, 10)
|
||||
require.NoError(t, err)
|
||||
// the only merge request in this repository has number 1,
|
||||
// but we offset it by the maximum issue number so it becomes
|
||||
// pull request 2 in Forgejo
|
||||
assert.Len(t, prs, 1)
|
||||
assert.EqualValues(t, 3, prs[0].Number)
|
||||
|
||||
// Issue with number 1 has two comments, but one of them is an internal note and is skipped
|
||||
comments, _, err := downloader.GetComments(&base.Issue{
|
||||
Number: 1,
|
||||
ForeignIndex: 1,
|
||||
Context: gitlabIssueContext{IsMergeRequest: false},
|
||||
})
|
||||
require.NoError(t, err)
|
||||
assertCommentsEqual(t, []*base.Comment{
|
||||
{
|
||||
IssueIndex: 1,
|
||||
PosterID: 3974632,
|
||||
PosterName: "mahlzahn",
|
||||
Created: time.Date(2026, 5, 26, 9, 32, 49, 748000000, time.UTC),
|
||||
Content: "Normal comment",
|
||||
Reactions: nil,
|
||||
},
|
||||
}, comments)
|
||||
|
||||
// Pull request with number 1 has only one comment, but it is an internal note and is skipped
|
||||
comments, _, err = downloader.GetComments(&base.Issue{
|
||||
Number: 3,
|
||||
ForeignIndex: 1,
|
||||
Context: gitlabIssueContext{IsMergeRequest: true},
|
||||
})
|
||||
require.NoError(t, err)
|
||||
assert.Empty(t, comments)
|
||||
}
|
||||
|
|
|
|||
20
services/migrations/testdata/gitlab/confidential/GET_%2Fapi%2Fv4%2Fprojects%2F82554980
vendored
Normal file
20
services/migrations/testdata/gitlab/confidential/GET_%2Fapi%2Fv4%2Fprojects%2F82554980
vendored
Normal file
File diff suppressed because one or more lines are too long
|
|
@ -0,0 +1,28 @@
|
|||
Cache-Control: max-age=0, private, must-revalidate
|
||||
Cf-Cache-Status: MISS
|
||||
Content-Length: 2
|
||||
Content-Security-Policy: default-src 'none'
|
||||
Content-Type: application/json
|
||||
Etag: W/"4f53cda18c2baa0c0354bb5f9a3ecbe5"
|
||||
Gitlab-Lb: haproxy-main-19-lb-gprd
|
||||
Gitlab-Sv: api-gke-us-east1-b
|
||||
Link: <https://gitlab.com/api/v4/projects/82554980/issues/1/award_emoji?id=82554980&issue_iid=1&page=1&per_page=10>; rel="first", <https://gitlab.com/api/v4/projects/82554980/issues/1/award_emoji?id=82554980&issue_iid=1&page=1&per_page=10>; rel="last"
|
||||
Ratelimit-Limit: 2000
|
||||
Ratelimit-Name: throttle_authenticated_api
|
||||
Ratelimit-Observed: 5
|
||||
Ratelimit-Remaining: 1995
|
||||
Ratelimit-Reset: 1779789300
|
||||
Referrer-Policy: strict-origin-when-cross-origin
|
||||
Strict-Transport-Security: max-age=31536000
|
||||
Vary: Origin, Accept-Encoding
|
||||
X-Content-Type-Options: nosniff
|
||||
X-Frame-Options: SAMEORIGIN
|
||||
X-Next-Page:
|
||||
X-Page: 1
|
||||
X-Per-Page: 10
|
||||
X-Prev-Page:
|
||||
X-Runtime: 0.073433
|
||||
X-Total: 0
|
||||
X-Total-Pages: 1
|
||||
|
||||
[]
|
||||
|
|
@ -0,0 +1,27 @@
|
|||
Cache-Control: max-age=0, private, must-revalidate
|
||||
Cf-Cache-Status: MISS
|
||||
Content-Security-Policy: default-src 'none'
|
||||
Content-Type: application/json
|
||||
Etag: W/"2fbd24efd95ba4bff096d7176a06f03c"
|
||||
Gitlab-Lb: haproxy-main-13-lb-gprd
|
||||
Gitlab-Sv: api-gke-us-east1-b
|
||||
Link: <https://gitlab.com/api/v4/projects/82554980/issues/1/discussions?id=82554980¬eable_id=1&page=1&per_page=100>; rel="first", <https://gitlab.com/api/v4/projects/82554980/issues/1/discussions?id=82554980¬eable_id=1&page=1&per_page=100>; rel="last"
|
||||
Ratelimit-Limit: 2000
|
||||
Ratelimit-Name: throttle_authenticated_api
|
||||
Ratelimit-Observed: 9
|
||||
Ratelimit-Remaining: 1991
|
||||
Ratelimit-Reset: 1779789300
|
||||
Referrer-Policy: strict-origin-when-cross-origin
|
||||
Strict-Transport-Security: max-age=31536000
|
||||
Vary: Origin, Accept-Encoding
|
||||
X-Content-Type-Options: nosniff
|
||||
X-Frame-Options: SAMEORIGIN
|
||||
X-Next-Page:
|
||||
X-Page: 1
|
||||
X-Per-Page: 100
|
||||
X-Prev-Page:
|
||||
X-Runtime: 0.142777
|
||||
X-Total: 2
|
||||
X-Total-Pages: 1
|
||||
|
||||
[{"id":"e3fd72a0a026c57218994979ba686d7ebdc32ce4","individual_note":true,"resolvable":false,"notes":[{"id":3384409453,"type":null,"body":"Internal note","author":{"id":3974632,"username":"mahlzahn","public_email":"","name":"mahlzahn","state":"active","locked":false,"avatar_url":"https://gitlab.com/uploads/-/system/user/avatar/3974632/avatar.png","web_url":"https://gitlab.com/mahlzahn"},"created_at":"2026-05-26T08:58:52.374Z","updated_at":"2026-05-26T08:58:52.374Z","system":false,"noteable_id":191028598,"noteable_type":"Issue","project_id":82554980,"resolvable":false,"confidential":true,"internal":true,"imported":false,"imported_from":"none","noteable_iid":1,"commands_changes":{}}]},{"id":"06234a3146c02649facca69551660ea0c058176e","individual_note":true,"resolvable":false,"notes":[{"id":3384552626,"type":null,"body":"Normal comment","author":{"id":3974632,"username":"mahlzahn","public_email":"","name":"mahlzahn","state":"active","locked":false,"avatar_url":"https://gitlab.com/uploads/-/system/user/avatar/3974632/avatar.png","web_url":"https://gitlab.com/mahlzahn"},"created_at":"2026-05-26T09:32:49.748Z","updated_at":"2026-05-26T09:32:49.748Z","system":false,"noteable_id":191028598,"noteable_type":"Issue","project_id":82554980,"resolvable":false,"confidential":false,"internal":false,"imported":false,"imported_from":"none","noteable_iid":1,"commands_changes":{}}]}]
|
||||
|
|
@ -0,0 +1,28 @@
|
|||
Cache-Control: max-age=0, private, must-revalidate
|
||||
Cf-Cache-Status: MISS
|
||||
Content-Length: 2
|
||||
Content-Security-Policy: default-src 'none'
|
||||
Content-Type: application/json
|
||||
Etag: W/"4f53cda18c2baa0c0354bb5f9a3ecbe5"
|
||||
Gitlab-Lb: haproxy-main-57-lb-gprd
|
||||
Gitlab-Sv: api-gke-us-east1-d
|
||||
Link: <https://gitlab.com/api/v4/projects/82554980/issues/1/resource_state_events?eventable_id=1&id=82554980&page=1&per_page=100>; rel="first", <https://gitlab.com/api/v4/projects/82554980/issues/1/resource_state_events?eventable_id=1&id=82554980&page=1&per_page=100>; rel="last"
|
||||
Ratelimit-Limit: 2000
|
||||
Ratelimit-Name: throttle_authenticated_api
|
||||
Ratelimit-Observed: 10
|
||||
Ratelimit-Remaining: 1990
|
||||
Ratelimit-Reset: 1779789300
|
||||
Referrer-Policy: strict-origin-when-cross-origin
|
||||
Strict-Transport-Security: max-age=31536000
|
||||
Vary: Origin, Accept-Encoding
|
||||
X-Content-Type-Options: nosniff
|
||||
X-Frame-Options: SAMEORIGIN
|
||||
X-Next-Page:
|
||||
X-Page: 1
|
||||
X-Per-Page: 100
|
||||
X-Prev-Page:
|
||||
X-Runtime: 0.098598
|
||||
X-Total: 0
|
||||
X-Total-Pages: 1
|
||||
|
||||
[]
|
||||
|
|
@ -0,0 +1,27 @@
|
|||
Cache-Control: max-age=0, private, must-revalidate
|
||||
Cf-Cache-Status: MISS
|
||||
Content-Security-Policy: default-src 'none'
|
||||
Content-Type: application/json
|
||||
Etag: W/"79478b7d2ca6de15cebecfdde62e7dec"
|
||||
Gitlab-Lb: haproxy-main-55-lb-gprd
|
||||
Gitlab-Sv: api-gke-us-east1-b
|
||||
Link: <https://gitlab.com/api/v4/projects/82554980/issues?id=82554980&order_by=created_at&page=1&per_page=10&sort=desc&state=all&with_labels_details=false>; rel="first", <https://gitlab.com/api/v4/projects/82554980/issues?id=82554980&order_by=created_at&page=1&per_page=10&sort=desc&state=all&with_labels_details=false>; rel="last"
|
||||
Ratelimit-Limit: 2000
|
||||
Ratelimit-Name: throttle_authenticated_api
|
||||
Ratelimit-Observed: 4
|
||||
Ratelimit-Remaining: 1996
|
||||
Ratelimit-Reset: 1779789300
|
||||
Referrer-Policy: strict-origin-when-cross-origin
|
||||
Strict-Transport-Security: max-age=31536000
|
||||
Vary: Origin, Accept-Encoding
|
||||
X-Content-Type-Options: nosniff
|
||||
X-Frame-Options: SAMEORIGIN
|
||||
X-Next-Page:
|
||||
X-Page: 1
|
||||
X-Per-Page: 10
|
||||
X-Prev-Page:
|
||||
X-Runtime: 0.177626
|
||||
X-Total: 2
|
||||
X-Total-Pages: 1
|
||||
|
||||
[{"id":191028619,"iid":2,"project_id":82554980,"title":"Confidential issue","description":"","state":"opened","created_at":"2026-05-26T08:55:44.918Z","updated_at":"2026-05-26T08:55:44.918Z","closed_at":null,"closed_by":null,"labels":[],"milestone":null,"assignees":[],"author":{"id":3974632,"username":"mahlzahn","public_email":"","name":"mahlzahn","state":"active","locked":false,"avatar_url":"https://gitlab.com/uploads/-/system/user/avatar/3974632/avatar.png","web_url":"https://gitlab.com/mahlzahn"},"type":"ISSUE","assignee":null,"user_notes_count":0,"merge_requests_count":0,"upvotes":0,"downvotes":0,"start_date":null,"due_date":null,"confidential":true,"discussion_locked":null,"issue_type":"issue","web_url":"https://gitlab.com/forgejo/test_repo-confidential/-/work_items/2","time_stats":{"time_estimate":0,"total_time_spent":0,"human_time_estimate":null,"human_total_time_spent":null},"task_completion_status":{"count":0,"completed_count":0},"blocking_issues_count":0,"has_tasks":true,"task_status":"","_links":{"self":"https://gitlab.com/api/v4/projects/82554980/issues/2","notes":"https://gitlab.com/api/v4/projects/82554980/issues/2/notes","award_emoji":"https://gitlab.com/api/v4/projects/82554980/issues/2/award_emoji","project":"https://gitlab.com/api/v4/projects/82554980","closed_as_duplicate_of":null},"references":{"short":"#2","relative":"#2","full":"forgejo/test_repo-confidential#2"},"severity":"UNKNOWN","moved_to_id":null,"imported":false,"imported_from":"none","service_desk_reply_to":null},{"id":191028598,"iid":1,"project_id":82554980,"title":"Normal issue","description":"","state":"opened","created_at":"2026-05-26T08:55:25.760Z","updated_at":"2026-05-26T09:32:49.776Z","closed_at":null,"closed_by":null,"labels":[],"milestone":null,"assignees":[],"author":{"id":3974632,"username":"mahlzahn","public_email":"","name":"mahlzahn","state":"active","locked":false,"avatar_url":"https://gitlab.com/uploads/-/system/user/avatar/3974632/avatar.png","web_url":"https://gitlab.com/mahlzahn"},"type":"ISSUE","assignee":null,"user_notes_count":2,"merge_requests_count":0,"upvotes":0,"downvotes":0,"start_date":null,"due_date":null,"confidential":false,"discussion_locked":null,"issue_type":"issue","web_url":"https://gitlab.com/forgejo/test_repo-confidential/-/work_items/1","time_stats":{"time_estimate":0,"total_time_spent":0,"human_time_estimate":null,"human_total_time_spent":null},"task_completion_status":{"count":0,"completed_count":0},"blocking_issues_count":0,"has_tasks":true,"task_status":"","_links":{"self":"https://gitlab.com/api/v4/projects/82554980/issues/1","notes":"https://gitlab.com/api/v4/projects/82554980/issues/1/notes","award_emoji":"https://gitlab.com/api/v4/projects/82554980/issues/1/award_emoji","project":"https://gitlab.com/api/v4/projects/82554980","closed_as_duplicate_of":null},"references":{"short":"#1","relative":"#1","full":"forgejo/test_repo-confidential#1"},"severity":"UNKNOWN","moved_to_id":null,"imported":false,"imported_from":"none","service_desk_reply_to":null}]
|
||||
|
|
@ -0,0 +1,20 @@
|
|||
Cache-Control: max-age=0, private, must-revalidate
|
||||
Cf-Cache-Status: MISS
|
||||
Content-Security-Policy: default-src 'none'
|
||||
Content-Type: application/json
|
||||
Etag: W/"b9c76d03ff5614caf10a4c57360357cd"
|
||||
Gitlab-Lb: haproxy-main-06-lb-gprd
|
||||
Gitlab-Sv: api-gke-us-east1-d
|
||||
Ratelimit-Limit: 2000
|
||||
Ratelimit-Name: throttle_authenticated_api
|
||||
Ratelimit-Observed: 7
|
||||
Ratelimit-Remaining: 1993
|
||||
Ratelimit-Reset: 1779789300
|
||||
Referrer-Policy: strict-origin-when-cross-origin
|
||||
Strict-Transport-Security: max-age=31536000
|
||||
Vary: Origin, Accept-Encoding
|
||||
X-Content-Type-Options: nosniff
|
||||
X-Frame-Options: SAMEORIGIN
|
||||
X-Runtime: 0.169552
|
||||
|
||||
{"id":488879616,"iid":1,"project_id":82554980,"title":"chore: fix typo","description":"","state":"opened","created_at":"2026-05-26T09:02:35.641Z","updated_at":"2026-05-26T09:40:10.508Z","merged_by":null,"merge_user":null,"merged_at":null,"closed_by":null,"closed_at":null,"target_branch":"main","source_branch":"fix_typo","user_notes_count":1,"upvotes":0,"downvotes":0,"author":{"id":3974632,"username":"mahlzahn","public_email":"","name":"mahlzahn","state":"active","locked":false,"avatar_url":"https://gitlab.com/uploads/-/system/user/avatar/3974632/avatar.png","web_url":"https://gitlab.com/mahlzahn"},"assignees":[],"assignee":null,"reviewers":[],"source_project_id":82554980,"target_project_id":82554980,"labels":[],"draft":false,"imported":false,"imported_from":"none","work_in_progress":false,"milestone":null,"merge_when_pipeline_succeeds":false,"merge_status":"cannot_be_merged","detailed_merge_status":"conflict","merge_after":null,"sha":"ca7060858fda4c3bca198462a2a907a417ab7759","merge_commit_sha":null,"squash_commit_sha":null,"discussion_locked":null,"should_remove_source_branch":null,"force_remove_source_branch":true,"prepared_at":"2026-05-26T09:02:37.178Z","reference":"!1","references":{"short":"!1","relative":"!1","full":"forgejo/test_repo-confidential!1"},"web_url":"https://gitlab.com/forgejo/test_repo-confidential/-/merge_requests/1","time_stats":{"time_estimate":0,"total_time_spent":0,"human_time_estimate":null,"human_total_time_spent":null},"squash":false,"squash_on_merge":false,"task_completion_status":{"count":0,"completed_count":0},"has_conflicts":true,"blocking_discussions_resolved":true,"approvals_before_merge":null,"subscribed":true,"changes_count":"1","head_pipeline":null,"diff_refs":{"base_sha":"f19949326d3d51391e8f05a5f1cf96fa9dd99763","head_sha":"ca7060858fda4c3bca198462a2a907a417ab7759","start_sha":"f19949326d3d51391e8f05a5f1cf96fa9dd99763"},"merge_error":null,"first_contribution":true,"user":{"can_merge":false}}
|
||||
|
|
@ -0,0 +1,28 @@
|
|||
Cache-Control: max-age=0, private, must-revalidate
|
||||
Cf-Cache-Status: MISS
|
||||
Content-Length: 2
|
||||
Content-Security-Policy: default-src 'none'
|
||||
Content-Type: application/json
|
||||
Etag: W/"4f53cda18c2baa0c0354bb5f9a3ecbe5"
|
||||
Gitlab-Lb: haproxy-main-25-lb-gprd
|
||||
Gitlab-Sv: api-gke-us-east1-b
|
||||
Link: <https://gitlab.com/api/v4/projects/82554980/merge_requests/1/award_emoji?id=82554980&merge_request_iid=1&page=1&per_page=10>; rel="first", <https://gitlab.com/api/v4/projects/82554980/merge_requests/1/award_emoji?id=82554980&merge_request_iid=1&page=1&per_page=10>; rel="last"
|
||||
Ratelimit-Limit: 2000
|
||||
Ratelimit-Name: throttle_authenticated_api
|
||||
Ratelimit-Observed: 8
|
||||
Ratelimit-Remaining: 1992
|
||||
Ratelimit-Reset: 1779789300
|
||||
Referrer-Policy: strict-origin-when-cross-origin
|
||||
Strict-Transport-Security: max-age=31536000
|
||||
Vary: Origin, Accept-Encoding
|
||||
X-Content-Type-Options: nosniff
|
||||
X-Frame-Options: SAMEORIGIN
|
||||
X-Next-Page:
|
||||
X-Page: 1
|
||||
X-Per-Page: 10
|
||||
X-Prev-Page:
|
||||
X-Runtime: 0.097656
|
||||
X-Total: 0
|
||||
X-Total-Pages: 1
|
||||
|
||||
[]
|
||||
|
|
@ -0,0 +1,27 @@
|
|||
Cache-Control: max-age=0, private, must-revalidate
|
||||
Cf-Cache-Status: MISS
|
||||
Content-Security-Policy: default-src 'none'
|
||||
Content-Type: application/json
|
||||
Etag: W/"591e42a5f29fd322c1f77db90999e0f6"
|
||||
Gitlab-Lb: haproxy-main-01-lb-gprd
|
||||
Gitlab-Sv: api-gke-us-east1-b
|
||||
Link: <https://gitlab.com/api/v4/projects/82554980/merge_requests/1/discussions?id=82554980¬eable_id=1&page=1&per_page=100>; rel="first", <https://gitlab.com/api/v4/projects/82554980/merge_requests/1/discussions?id=82554980¬eable_id=1&page=1&per_page=100>; rel="last"
|
||||
Ratelimit-Limit: 2000
|
||||
Ratelimit-Name: throttle_authenticated_api
|
||||
Ratelimit-Observed: 11
|
||||
Ratelimit-Remaining: 1989
|
||||
Ratelimit-Reset: 1779789300
|
||||
Referrer-Policy: strict-origin-when-cross-origin
|
||||
Strict-Transport-Security: max-age=31536000
|
||||
Vary: Origin, Accept-Encoding
|
||||
X-Content-Type-Options: nosniff
|
||||
X-Frame-Options: SAMEORIGIN
|
||||
X-Next-Page:
|
||||
X-Page: 1
|
||||
X-Per-Page: 100
|
||||
X-Prev-Page:
|
||||
X-Runtime: 0.132759
|
||||
X-Total: 1
|
||||
X-Total-Pages: 1
|
||||
|
||||
[{"id":"992a517dbd25b748c6aa8ce27bdc1e5a3ec239f6","individual_note":true,"resolvable":false,"notes":[{"id":3384581942,"type":null,"body":"Another internal note","author":{"id":3974632,"username":"mahlzahn","public_email":"","name":"mahlzahn","state":"active","locked":false,"avatar_url":"https://gitlab.com/uploads/-/system/user/avatar/3974632/avatar.png","web_url":"https://gitlab.com/mahlzahn"},"created_at":"2026-05-26T09:40:10.477Z","updated_at":"2026-05-26T09:40:10.477Z","system":false,"noteable_id":488879616,"noteable_type":"MergeRequest","project_id":82554980,"resolvable":false,"confidential":true,"internal":true,"imported":false,"imported_from":"none","noteable_iid":1,"commands_changes":{}}]}]
|
||||
|
|
@ -0,0 +1,28 @@
|
|||
Cache-Control: max-age=0, private, must-revalidate
|
||||
Cf-Cache-Status: MISS
|
||||
Content-Length: 2
|
||||
Content-Security-Policy: default-src 'none'
|
||||
Content-Type: application/json
|
||||
Etag: W/"4f53cda18c2baa0c0354bb5f9a3ecbe5"
|
||||
Gitlab-Lb: haproxy-main-51-lb-gprd
|
||||
Gitlab-Sv: api-gke-us-east1-d
|
||||
Link: <https://gitlab.com/api/v4/projects/82554980/merge_requests/1/resource_state_events?eventable_id=1&id=82554980&page=1&per_page=100>; rel="first", <https://gitlab.com/api/v4/projects/82554980/merge_requests/1/resource_state_events?eventable_id=1&id=82554980&page=1&per_page=100>; rel="last"
|
||||
Ratelimit-Limit: 2000
|
||||
Ratelimit-Name: throttle_authenticated_api
|
||||
Ratelimit-Observed: 12
|
||||
Ratelimit-Remaining: 1988
|
||||
Ratelimit-Reset: 1779789300
|
||||
Referrer-Policy: strict-origin-when-cross-origin
|
||||
Strict-Transport-Security: max-age=31536000
|
||||
Vary: Origin, Accept-Encoding
|
||||
X-Content-Type-Options: nosniff
|
||||
X-Frame-Options: SAMEORIGIN
|
||||
X-Next-Page:
|
||||
X-Page: 1
|
||||
X-Per-Page: 100
|
||||
X-Prev-Page:
|
||||
X-Runtime: 0.063179
|
||||
X-Total: 0
|
||||
X-Total-Pages: 1
|
||||
|
||||
[]
|
||||
|
|
@ -0,0 +1,27 @@
|
|||
Cache-Control: max-age=0, private, must-revalidate
|
||||
Cf-Cache-Status: MISS
|
||||
Content-Security-Policy: default-src 'none'
|
||||
Content-Type: application/json
|
||||
Etag: W/"455960f9d3850d1ac04b6f21857873da"
|
||||
Gitlab-Lb: haproxy-main-05-lb-gprd
|
||||
Gitlab-Sv: api-gke-us-east1-c
|
||||
Link: <https://gitlab.com/api/v4/projects/82554980/merge_requests?id=82554980&order_by=created_at&page=1&per_page=10&sort=desc&state=all&view=simple&with_labels_details=false&with_merge_status_recheck=false>; rel="first", <https://gitlab.com/api/v4/projects/82554980/merge_requests?id=82554980&order_by=created_at&page=1&per_page=10&sort=desc&state=all&view=simple&with_labels_details=false&with_merge_status_recheck=false>; rel="last"
|
||||
Ratelimit-Limit: 2000
|
||||
Ratelimit-Name: throttle_authenticated_api
|
||||
Ratelimit-Observed: 6
|
||||
Ratelimit-Remaining: 1994
|
||||
Ratelimit-Reset: 1779789300
|
||||
Referrer-Policy: strict-origin-when-cross-origin
|
||||
Strict-Transport-Security: max-age=31536000
|
||||
Vary: Origin, Accept-Encoding
|
||||
X-Content-Type-Options: nosniff
|
||||
X-Frame-Options: SAMEORIGIN
|
||||
X-Next-Page:
|
||||
X-Page: 1
|
||||
X-Per-Page: 10
|
||||
X-Prev-Page:
|
||||
X-Runtime: 0.086347
|
||||
X-Total: 1
|
||||
X-Total-Pages: 1
|
||||
|
||||
[{"id":488879616,"iid":1,"project_id":82554980,"title":"chore: fix typo","description":"","state":"opened","created_at":"2026-05-26T09:02:35.641Z","updated_at":"2026-05-26T09:40:10.508Z","web_url":"https://gitlab.com/forgejo/test_repo-confidential/-/merge_requests/1"}]
|
||||
File diff suppressed because one or more lines are too long
20
services/migrations/testdata/gitlab/confidential/GET_%2Fapi%2Fv4%2Fversion
vendored
Normal file
20
services/migrations/testdata/gitlab/confidential/GET_%2Fapi%2Fv4%2Fversion
vendored
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
Cache-Control: max-age=0, private, must-revalidate
|
||||
Cf-Cache-Status: MISS
|
||||
Content-Security-Policy: default-src 'none'
|
||||
Content-Type: application/json
|
||||
Etag: W/"f4c5c4fb869a5286a8cc44a863504620"
|
||||
Gitlab-Lb: haproxy-main-41-lb-gprd
|
||||
Gitlab-Sv: api-gke-us-east1-c
|
||||
Ratelimit-Limit: 2000
|
||||
Ratelimit-Name: throttle_authenticated_api
|
||||
Ratelimit-Observed: 1
|
||||
Ratelimit-Remaining: 1999
|
||||
Ratelimit-Reset: 1779789300
|
||||
Referrer-Policy: strict-origin-when-cross-origin
|
||||
Strict-Transport-Security: max-age=31536000
|
||||
Vary: Origin, Accept-Encoding
|
||||
X-Content-Type-Options: nosniff
|
||||
X-Frame-Options: SAMEORIGIN
|
||||
X-Runtime: 0.050947
|
||||
|
||||
{"version":"19.1.0-pre","revision":"02f8641dbf3","kas":{"enabled":true,"externalUrl":"wss://kas.gitlab.com","externalK8sProxyUrl":"https://kas.gitlab.com/k8s-proxy","version":"19.1.0-rc1+772eacfab6e697eed51d7ebf031fdb25b1851c16"},"enterprise":true}
|
||||
Loading…
Add table
Add a link
Reference in a new issue