Skip to content

Commit 577ba42

Browse files
author
GitLab Bot
committed
Add latest changes from gitlab-org/gitlab@master
1 parent 215313e commit 577ba42

File tree

80 files changed

+1109
-675
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

80 files changed

+1109
-675
lines changed

.gitlab/ci/qa.gitlab-ci.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -231,7 +231,7 @@ e2e:test-on-gdk:
231231
SKIP_MESSAGE: Skipping test-on-gdk due to mr containing only quarantine changes!
232232
GDK_IMAGE: "${CI_REGISTRY_IMAGE}/gitlab-qa-gdk:${CI_COMMIT_SHA}"
233233

234-
.e2e:test-product-analytics:
234+
e2e:test-product-analytics:
235235
extends:
236236
- .qa:rules:e2e:test-on-gdk
237237
stage: qa

GITALY_SERVER_VERSION

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
90d4f1b1a6f42d95d35bfd21267fda5621ac9a90
1+
b5a7b5020dc91f9ae06087f87fcd418fc49f5808

app/assets/javascripts/sidebar/components/subscriptions/sidebar_subscriptions_widget.vue

+10-2
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ import {
66
GlLoadingIcon,
77
GlToggle,
88
GlTooltipDirective,
9+
GlAnimatedNotificationIcon,
910
} from '@gitlab/ui';
1011
import { createAlert } from '~/alert';
1112
import { TYPE_ISSUE, TYPE_EPIC, WORKSPACE_GROUP, WORKSPACE_PROJECT } from '~/issues/constants';
@@ -35,6 +36,7 @@ export default {
3536
GlIcon,
3637
GlLoadingIcon,
3738
GlToggle,
39+
GlAnimatedNotificationIcon,
3840
SidebarEditableItem,
3941
},
4042
mixins: [glFeatureFlagMixin()],
@@ -228,7 +230,10 @@ export default {
228230
:class="{ 'gl-ml-2': isIssuable, 'btn-icon': isNotificationsTodosButtons }"
229231
@click="toggleSubscribed"
230232
>
231-
<gl-icon :name="notificationIcon" :size="16" :class="{ '!gl-fill-blue-500': subscribed }" />
233+
<gl-animated-notification-icon
234+
:class="{ '!gl-text-blue-500': subscribed }"
235+
:is-on="subscribed"
236+
/>
232237
</gl-button>
233238
<gl-button
234239
v-if="!isMergeRequest"
@@ -240,7 +245,10 @@ export default {
240245
class="sidebar-collapsed-icon sidebar-collapsed-container !gl-rounded-none !gl-shadow-none"
241246
@click="toggleSubscribed"
242247
>
243-
<gl-icon :name="notificationIcon" :size="16" :class="{ '!gl-fill-blue-500': subscribed }" />
248+
<gl-animated-notification-icon
249+
:class="{ '!gl-text-blue-500': subscribed }"
250+
:is-on="subscribed"
251+
/>
244252
</gl-button>
245253
</div>
246254
<sidebar-editable-item

app/assets/javascripts/sidebar/components/todo_toggle/sidebar_todo_widget.vue

+4-7
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<script>
2-
import { GlButton, GlIcon, GlTooltipDirective } from '@gitlab/ui';
2+
import { GlButton, GlTooltipDirective, GlAnimatedTodoIcon } from '@gitlab/ui';
33
import { produce } from 'immer';
44
import { createAlert } from '~/alert';
55
import { TYPE_MERGE_REQUEST } from '~/issues/constants';
@@ -16,8 +16,8 @@ const trackingMixin = Tracking.mixin();
1616
export default {
1717
components: {
1818
GlButton,
19-
GlIcon,
2019
TodoButton,
20+
GlAnimatedTodoIcon,
2121
},
2222
directives: {
2323
GlTooltip: GlTooltipDirective,
@@ -112,9 +112,6 @@ export default {
112112
}
113113
return todoMutationTypes.create;
114114
},
115-
collapsedButtonIcon() {
116-
return this.hasTodo ? 'todo-done' : 'todo-add';
117-
},
118115
tootltipTitle() {
119116
return todoLabel(this.hasTodo);
120117
},
@@ -203,7 +200,7 @@ export default {
203200
class="hide-collapsed"
204201
@click.stop.prevent="toggleTodo"
205202
>
206-
<gl-icon :class="{ 'todo-undone !gl-fill-blue-500': hasTodo }" :name="collapsedButtonIcon" />
203+
<gl-animated-todo-icon :class="{ '!gl-text-blue-500': hasTodo }" :is-on="hasTodo" />
207204
</todo-button>
208205
<todo-button
209206
v-else
@@ -224,7 +221,7 @@ export default {
224221
class="sidebar-collapsed-icon sidebar-collapsed-container !gl-rounded-none !gl-shadow-none"
225222
@click.stop.prevent="toggleTodo"
226223
>
227-
<gl-icon :class="{ 'todo-undone': hasTodo }" :name="collapsedButtonIcon" />
224+
<gl-animated-todo-icon :is-on="hasTodo" />
228225
</gl-button>
229226
</div>
230227
</template>

app/assets/javascripts/vue_merge_request_widget/components/mr_widget_how_to_merge_modal.vue

+17-23
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@ import { GlModal, GlLink, GlSprintf } from '@gitlab/ui';
33
import { helpPagePath } from '~/helpers/help_page_helper';
44
import { escapeShellString } from '~/lib/utils/text_utility';
55
import { __ } from '~/locale';
6-
import ClipboardButton from '~/vue_shared/components/clipboard_button.vue';
76
87
export default {
98
i18n: {
@@ -25,15 +24,13 @@ export default {
2524
help: __('Push the source branch up to GitLab.'),
2625
},
2726
},
28-
copyCommands: __('Copy commands'),
2927
tip: __(
3028
'%{strongStart}Tip:%{strongEnd} You can also %{linkStart}check out with merge request ID%{linkEnd}.',
3129
),
3230
title: __('Check out, review, and resolve locally'),
3331
},
3432
components: {
3533
GlModal,
36-
ClipboardButton,
3734
GlLink,
3835
GlSprintf,
3936
},
@@ -113,6 +110,7 @@ export default {
113110
}
114111
});
115112
},
113+
userColorScheme: window.gon.user_color_scheme,
116114
};
117115
</script>
118116

@@ -132,16 +130,16 @@ export default {
132130
</strong>
133131
{{ $options.i18n.steps.step1.help }}
134132
</p>
135-
<div class="gl-flex gl-gap-3">
136-
<pre class="gl-w-full" data-testid="how-to-merge-instructions">{{ mergeInfo1 }}</pre>
137-
<clipboard-button
138-
:text="mergeInfo1"
139-
:title="$options.i18n.copyCommands"
140-
category="tertiary"
141-
class="gl-self-start"
142-
/>
143-
</div>
144-
<p v-if="reviewingDocsPath">
133+
<pre
134+
:class="$options.userColorScheme"
135+
class="code highlight js-syntax-highlight gl-rounded-base"
136+
data-testid="how-to-merge-instructions"
137+
>{{ mergeInfo1 }}</pre
138+
>
139+
<p
140+
v-if="reviewingDocsPath"
141+
class="-gl-mt-4 gl-rounded-b-base gl-border-1 gl-border-solid gl-border-default gl-px-4 gl-py-3"
142+
>
145143
<gl-sprintf data-testid="docs-tip" :message="$options.i18n.tip">
146144
<template #strong="{ content }">
147145
<strong>{{ content }}</strong>
@@ -153,7 +151,6 @@ export default {
153151
</template>
154152
</gl-sprintf>
155153
</p>
156-
157154
<p>
158155
<strong>
159156
{{ $options.i18n.steps.step2.label }}
@@ -178,14 +175,11 @@ export default {
178175
</strong>
179176
{{ $options.i18n.steps.step4.help }}
180177
</p>
181-
<div class="gl-flex gl-gap-3">
182-
<pre class="gl-w-full" data-testid="how-to-merge-instructions">{{ mergeInfo2 }}</pre>
183-
<clipboard-button
184-
:text="mergeInfo2"
185-
:title="$options.i18n.copyCommands"
186-
category="tertiary"
187-
class="gl-self-start"
188-
/>
189-
</div>
178+
<pre
179+
:class="$options.userColorScheme"
180+
class="code highlight js-syntax-highlight language-shell gl-rounded-base"
181+
data-testid="how-to-merge-instructions"
182+
>{{ mergeInfo2 }}</pre
183+
>
190184
</gl-modal>
191185
</template>

app/helpers/sidebars_helper.rb

+7-1
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,13 @@ def super_sidebar_logged_in_context(user, group:, project:, panel:, panel_type:)
101101
sign_out_link: destroy_user_session_path,
102102
issues_dashboard_path: issues_dashboard_path(assignee_username: user.username),
103103
merge_request_dashboard_path: user.merge_request_dashboard_enabled? ? merge_requests_dashboard_path : nil,
104-
todos_dashboard_path: dashboard_todos_path,
104+
105+
todos_dashboard_path: if Feature.enabled?(:todos_vue_application, user)
106+
vue_dashboard_todos_path
107+
else
108+
dashboard_todos_path
109+
end,
110+
105111
create_new_menu_groups: create_new_menu_groups(group: group, project: project),
106112
merge_request_menu: create_merge_request_menu(user),
107113
projects_path: dashboard_projects_path,

config/feature_flags/development/allow_protected_branches_for_group.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,4 @@ rollout_issue_url: https://gitlab.com/gitlab-org/gitlab/-/issues/383178
55
milestone: '15.11'
66
type: development
77
group: group::source code
8-
default_enabled: false
8+
default_enabled: true
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
---
22
migration_job_name: BackfillApprovalMergeRequestRuleSourcesProjectId
3-
description: Backfills sharding key `approval_merge_request_rule_sources.project_id` from `approval_project_rules`.
3+
description: Backfills sharding key `approval_merge_request_rule_sources.project_id`
4+
from `approval_project_rules`.
45
feature_category: code_review_workflow
56
introduced_by_url: https://gitlab.com/gitlab-org/gitlab/-/merge_requests/151629
67
milestone: '17.0'
78
queued_migration_version: 20240501044238
8-
finalized_by: # version of the migration that finalized this BBM
9+
finalized_by: '20241001231957'
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
---
2+
migration_job_name: BackfillPagesDomainAcmeOrdersProjectId
3+
description: Backfills sharding key `pages_domain_acme_orders.project_id` from `pages_domains`.
4+
feature_category: pages
5+
introduced_by_url: https://gitlab.com/gitlab-org/gitlab/-/merge_requests/167614
6+
milestone: '17.5'
7+
queued_migration_version: 20240930123732
8+
finalize_after: '2024-10-22'
9+
finalized_by: # version of the migration that finalized this BBM

db/docs/batched_background_migrations/deduplicate_lfs_objects_projects.yml

+8-4
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,13 @@ description: >-
55
After the migration is finalized, we need to add a unique index on all three columns to ensure
66
data consistency since the unique validation already exists at the model level.
77
8-
Originally introduced by https://gitlab.com/gitlab-org/gitlab/-/merge_requests/154323
8+
1) Originally introduced by https://gitlab.com/gitlab-org/gitlab/-/merge_requests/154323
99
Re-enqueued because we found some duplicates were still being introduced
10+
11+
2) Originally re-enqueued in https://gitlab.com/gitlab-org/gitlab/-/merge_requests/167468
12+
Re-enqueued a second time since we found some duplicates when repository_type is NULL
1013
feature_category: source_code_management
11-
introduced_by_url: https://gitlab.com/gitlab-org/gitlab/-/merge_requests/164127
12-
milestone: '17.4'
13-
queued_migration_version: 20240827204855
14+
introduced_by_url: https://gitlab.com/gitlab-org/gitlab/-/merge_requests/167468
15+
milestone: '17.5'
16+
queued_migration_version: 20240927202948
17+
finalize_after: '2024-10-17' # required upgrade stop due date

db/docs/pages_domain_acme_orders.yml

+3-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,8 @@ classes:
44
- PagesDomainAcmeOrder
55
feature_categories:
66
- pages
7-
description: Stores ACME order information used in obtaining Let's Encrypt certificates for GitLab Pages domains.
7+
description: Stores ACME order information used in obtaining Let's Encrypt certificates
8+
for GitLab Pages domains.
89
introduced_by_url: https://gitlab.com/gitlab-org/gitlab/-/merge_requests/14014
910
milestone: '12.0'
1011
gitlab_schema: gitlab_main_cell
@@ -19,3 +20,4 @@ desired_sharding_key:
1920
table: pages_domains
2021
sharding_key: project_id
2122
belongs_to: pages_domain
23+
desired_sharding_key_migration_job_name: BackfillPagesDomainAcmeOrdersProjectId
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
# frozen_string_literal: true
2+
3+
class AddProjectIdToPagesDomainAcmeOrders < Gitlab::Database::Migration[2.2]
4+
milestone '17.5'
5+
6+
def change
7+
add_column :pages_domain_acme_orders, :project_id, :bigint
8+
end
9+
end

db/post_migrate/20240827204855_reenqueue_deduplicate_lfs_objects_projects.rb

+4-11
Original file line numberDiff line numberDiff line change
@@ -13,20 +13,13 @@ class ReenqueueDeduplicateLfsObjectsProjects < Gitlab::Database::Migration[2.2]
1313

1414
restrict_gitlab_migration gitlab_schema: :gitlab_main
1515

16+
# To be re-enqueued by:
17+
# db/post_migrate/20240927202948_reenqueue_deduplicate_lfs_objects_projects_with_null_repository_types.rb
1618
def up
17-
delete_batched_background_migration(MIGRATION, :lfs_objects_projects, :id, [])
18-
19-
queue_batched_background_migration(
20-
MIGRATION,
21-
:lfs_objects_projects,
22-
:id,
23-
job_interval: DELAY_INTERVAL,
24-
batch_size: BATCH_SIZE,
25-
sub_batch_size: SUB_BATCH_SIZE
26-
)
19+
# no-op
2720
end
2821

2922
def down
30-
delete_batched_background_migration(MIGRATION, :lfs_objects_projects, :id, [])
23+
# no-op
3124
end
3225
end
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
# frozen_string_literal: true
2+
3+
class RemoveDefaultForSbomComponentsOrganizationId < Gitlab::Database::Migration[2.2]
4+
milestone '17.5'
5+
6+
def change
7+
change_column_default(:sbom_components, :organization_id, from: 1, to: nil)
8+
end
9+
end
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
# frozen_string_literal: true
2+
3+
class RemoveDefaultForSbomComponentVersionsOrganizationId < Gitlab::Database::Migration[2.2]
4+
milestone '17.5'
5+
6+
def change
7+
change_column_default(:sbom_component_versions, :organization_id, from: 1, to: nil)
8+
end
9+
end
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
# frozen_string_literal: true
2+
3+
class RemoveDefaultForSbomSourcesOrganizationId < Gitlab::Database::Migration[2.2]
4+
milestone '17.5'
5+
6+
def change
7+
change_column_default(:sbom_sources, :organization_id, from: 1, to: nil)
8+
end
9+
end
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
# frozen_string_literal: true
2+
3+
class RemoveDefaultForSbomSourcePackagesOrganizationId < Gitlab::Database::Migration[2.2]
4+
milestone '17.5'
5+
6+
def change
7+
change_column_default(:sbom_source_packages, :organization_id, from: 1, to: nil)
8+
end
9+
end
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
# frozen_string_literal: true
2+
3+
class RemoveDefaultForVulnerabilityExportsOrganizationId < Gitlab::Database::Migration[2.2]
4+
milestone '17.5'
5+
6+
def change
7+
change_column_default(:vulnerability_exports, :organization_id, from: 1, to: nil)
8+
end
9+
end
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
# frozen_string_literal: true
2+
3+
class RemoveDefaultForVulnerabilityExportPartsOrganizationId < Gitlab::Database::Migration[2.2]
4+
milestone '17.5'
5+
6+
def change
7+
change_column_default(:vulnerability_export_parts, :organization_id, from: 1, to: nil)
8+
end
9+
end
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
# frozen_string_literal: true
2+
3+
class RemoveDefaultForDependencyListExportPartsOrganizationId < Gitlab::Database::Migration[2.2]
4+
milestone '17.5'
5+
6+
def change
7+
change_column_default(:dependency_list_export_parts, :organization_id, from: 1, to: nil)
8+
end
9+
end
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
# frozen_string_literal: true
2+
3+
class ReenqueueDeduplicateLfsObjectsProjectsWithNullRepositoryTypes < Gitlab::Database::Migration[2.2]
4+
milestone '17.5'
5+
6+
MIGRATION = 'DeduplicateLfsObjectsProjects'
7+
TABLE_NAME = :lfs_objects_projects
8+
DELAY_INTERVAL = 100
9+
BATCH_SIZE = 10_000
10+
SUB_BATCH_SIZE = 2_500
11+
12+
disable_ddl_transaction!
13+
14+
restrict_gitlab_migration gitlab_schema: :gitlab_main
15+
16+
def up
17+
delete_batched_background_migration(MIGRATION, :lfs_objects_projects, :id, [])
18+
19+
queue_batched_background_migration(
20+
MIGRATION,
21+
:lfs_objects_projects,
22+
:id,
23+
job_interval: DELAY_INTERVAL,
24+
batch_size: BATCH_SIZE,
25+
sub_batch_size: SUB_BATCH_SIZE
26+
)
27+
end
28+
29+
def down
30+
delete_batched_background_migration(MIGRATION, :lfs_objects_projects, :id, [])
31+
end
32+
end

0 commit comments

Comments
 (0)