Skip to content

Commit 380d41a

Browse files
author
GitLab Bot
committed
Add latest changes from gitlab-org/gitlab@master
1 parent f0471bf commit 380d41a

File tree

80 files changed

+1484
-208
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

+1484
-208
lines changed

.gitlab/ci/rails.gitlab-ci.yml

+5-6
Original file line numberDiff line numberDiff line change
@@ -336,28 +336,27 @@ rspec system pg14 no_gitaly_transactions:
336336
rspec-ee migration pg14 no_gitaly_transactions:
337337
extends:
338338
- rspec-ee migration pg14
339-
- .gitaly-without-transactions
339+
- .ee-only-gitaly-without-transactions
340340

341341
rspec-ee background_migration pg14 no_gitaly_transactions:
342342
extends:
343343
- rspec-ee background_migration pg14
344-
- .gitaly-without-transactions
344+
- .ee-only-gitaly-without-transactions
345345

346346
rspec-ee unit pg14 no_gitaly_transactions:
347347
extends:
348348
- rspec-ee unit pg14
349-
- .gitaly-without-transactions
349+
- .ee-only-gitaly-without-transactions
350350

351351
rspec-ee integration pg14 no_gitaly_transactions:
352352
extends:
353353
- rspec-ee integration pg14
354-
- .gitaly-without-transactions
354+
- .ee-only-gitaly-without-transactions
355355

356356
rspec-ee system pg14 no_gitaly_transactions:
357357
extends:
358358
- rspec-ee system pg14
359-
- .gitaly-without-transactions
360-
359+
- .ee-only-gitaly-without-transactions
361360

362361
# Dedicated job to test DB library code against PG13.
363362
# Note that these are already tested against PG13 in the `rspec unit pg13` / `rspec-ee unit pg13` jobs.

.gitlab/ci/rails/shared.gitlab-ci.yml

+6
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,12 @@ include:
6666
variables:
6767
GITALY_TRANSACTIONS_ENABLED: "false"
6868

69+
.ee-only-gitaly-without-transactions:
70+
extends:
71+
- .rails:rules:ee-only-gitaly-without-transactions
72+
variables:
73+
GITALY_TRANSACTIONS_ENABLED: "false"
74+
6975
.rspec-base-needs:
7076
needs:
7177
- !reference [.repo-from-artifacts, needs]

.gitlab/ci/rules.gitlab-ci.yml

+6
Original file line numberDiff line numberDiff line change
@@ -2002,6 +2002,12 @@
20022002
- <<: *if-schedule-maintenance
20032003
- <<: *if-merge-request-labels-run-without-gitaly-transactions
20042004

2005+
.rails:rules:ee-only-gitaly-without-transactions:
2006+
rules:
2007+
- <<: *if-not-ee
2008+
when: never
2009+
- !reference [".rails:rules:gitaly-without-transactions", rules]
2010+
20052011
.rails:rules:ee-and-foss-migration:
20062012
rules:
20072013
- <<: *if-fork-merge-request

.rubocop_todo/rspec/file_path.yml

+1
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,7 @@ RSpec/FilePath:
6565
- 'spec/services/ci/create_pipeline_service/rate_limit_spec.rb'
6666
- 'spec/services/ci/create_pipeline_service/rules_spec.rb'
6767
- 'spec/services/ci/create_pipeline_service/scripts_spec.rb'
68+
- 'spec/services/ci/create_pipeline_service/run_spec.rb'
6869
- 'spec/services/ci/create_pipeline_service/tags_spec.rb'
6970
- 'spec/services/ci/create_pipeline_service/variables_spec.rb'
7071
- 'spec/services/ci/create_pipeline_service/workflow_auto_cancel_spec.rb'

GITALY_SERVER_VERSION

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
47c3c8bc2d5a93e83eee6b250a06e4c39d9c929c
1+
8274bcec3ce5fd5059d83e724a4671bc3dcd2d68

Gemfile

+1-1
Original file line numberDiff line numberDiff line change
@@ -565,7 +565,7 @@ group :test do
565565
# Moved in `test` because https://gitlab.com/gitlab-org/gitlab/-/issues/217527
566566
gem 'derailed_benchmarks', require: false # rubocop:todo Gemfile/MissingFeatureCategory
567567

568-
gem 'gitlab_quality-test_tooling', '~> 1.30.0', require: false, feature_category: :tooling
568+
gem 'gitlab_quality-test_tooling', '~> 1.31.0', require: false, feature_category: :tooling
569569
end
570570

571571
gem 'octokit', '~> 9.0', feature_category: :importers

Gemfile.checksum

+1-1
Original file line numberDiff line numberDiff line change
@@ -234,7 +234,7 @@
234234
{"name":"gitlab-styles","version":"12.0.1","platform":"ruby","checksum":"d8a302b0ab0e1f18e2d11501760f1b85c5e70b5e5ca628828a0786c7984ed133"},
235235
{"name":"gitlab_chronic_duration","version":"0.12.0","platform":"ruby","checksum":"0d766944d415b5c831f176871ee8625783fc0c5bfbef2d79a3a616f207ffc16d"},
236236
{"name":"gitlab_omniauth-ldap","version":"2.2.0","platform":"ruby","checksum":"bb4d20acb3b123ed654a8f6a47d3fac673ece7ed0b6992edb92dca14bad2838c"},
237-
{"name":"gitlab_quality-test_tooling","version":"1.30.0","platform":"ruby","checksum":"06722db6aed571e2ec22e04a4179215cf0b49c9658ef14f71b8bd2245bc0c56c"},
237+
{"name":"gitlab_quality-test_tooling","version":"1.31.0","platform":"ruby","checksum":"c13d38f2ba01469179db7211008722b1f4a55270cca561d832b1eee438124f52"},
238238
{"name":"globalid","version":"1.1.0","platform":"ruby","checksum":"b337e1746f0c8cb0a6c918234b03a1ddeb4966206ce288fbb57779f59b2d154f"},
239239
{"name":"gon","version":"6.4.0","platform":"ruby","checksum":"e3a618d659392890f1aa7db420f17c75fd7d35aeb5f8fe003697d02c4b88d2f0"},
240240
{"name":"google-apis-androidpublisher_v3","version":"0.34.0","platform":"ruby","checksum":"d7e1d7dd92f79c498fe2082222a1740d788e022e660c135564b3fd299cab5425"},

Gemfile.lock

+2-2
Original file line numberDiff line numberDiff line change
@@ -754,7 +754,7 @@ GEM
754754
omniauth (>= 1.3, < 3)
755755
pyu-ruby-sasl (>= 0.0.3.3, < 0.1)
756756
rubyntlm (~> 0.5)
757-
gitlab_quality-test_tooling (1.30.0)
757+
gitlab_quality-test_tooling (1.31.0)
758758
activesupport (>= 7.0, < 7.2)
759759
amatch (~> 0.4.1)
760760
gitlab (~> 4.19)
@@ -2044,7 +2044,7 @@ DEPENDENCIES
20442044
gitlab-utils!
20452045
gitlab_chronic_duration (~> 0.12)
20462046
gitlab_omniauth-ldap (~> 2.2.0)
2047-
gitlab_quality-test_tooling (~> 1.30.0)
2047+
gitlab_quality-test_tooling (~> 1.31.0)
20482048
gon (~> 6.4.0)
20492049
google-apis-androidpublisher_v3 (~> 0.34.0)
20502050
google-apis-cloudbilling_v1 (~> 0.21.0)

app/assets/javascripts/editor/schema/ci.json

+47
Original file line numberDiff line numberDiff line change
@@ -880,6 +880,49 @@
880880
}
881881
]
882882
},
883+
"steps": {
884+
"type": "array",
885+
"items": {
886+
"oneOf": [
887+
{
888+
"required": [
889+
"step"
890+
]
891+
},
892+
{
893+
"required": [
894+
"script"
895+
]
896+
}
897+
],
898+
"properties": {
899+
"name": {
900+
"type": "string",
901+
"description": "Unique identifier for this step."
902+
},
903+
"step": {
904+
"type": "string",
905+
"description": "Reference to the step to invoke."
906+
},
907+
"env": {
908+
"$ref": "#/definitions/globalVariables"
909+
},
910+
"inputs": {
911+
"$ref": "#/definitions/inputs"
912+
},
913+
"script": {
914+
"type": "string",
915+
"description": "Shell script to evaluate."
916+
}
917+
},
918+
"additionalProperties": false,
919+
"type": "object",
920+
"required": [
921+
"name"
922+
],
923+
"description": "A single step invocation."
924+
}
925+
},
883926
"optional_script": {
884927
"oneOf": [
885928
{
@@ -1742,6 +1785,10 @@
17421785
"$ref": "#/definitions/script",
17431786
"markdownDescription": "Shell scripts executed by the Runner. The only required property of jobs. Be careful with special characters (e.g. `:`, `{`, `}`, `&`) and use single or double quotes to avoid issues. [Learn More](https://docs.gitlab.com/ee/ci/yaml/#script)"
17441787
},
1788+
"run": {
1789+
"$ref": "#/definitions/steps",
1790+
"markdownDescription": "Specifies a list of steps to execute in the job. The `run` keyword is an alternative to `script` and allows for more advanced job configuration. Each step is an object that defines a single task or command. Use either `run` or `script` in a job, but not both, otherwise the pipeline will error out."
1791+
},
17451792
"stage": {
17461793
"description": "Define what stage the job will run in.",
17471794
"anyOf": [

app/assets/javascripts/issues/list/components/issue_card_time_info.vue

+1-5
Original file line numberDiff line numberDiff line change
@@ -97,11 +97,7 @@ export default {
9797
9898
<template>
9999
<span>
100-
<span
101-
v-if="milestone"
102-
class="issuable-milestone gl-mr-3 gl-text-truncate gl-max-w-26 gl-display-inline-block gl-align-bottom"
103-
data-testid="issuable-milestone"
104-
>
100+
<span v-if="milestone" class="issuable-milestone gl-mr-3" data-testid="issuable-milestone">
105101
<gl-link
106102
v-gl-tooltip
107103
:href="milestoneLink"

app/assets/javascripts/pages/projects/shared/permissions/components/settings_panel.vue

+1-1
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ export default {
7777
),
7878
duoLabel: s__('ProjectSettings|GitLab Duo'),
7979
duoHelpText: s__('ProjectSettings|Use AI-powered features in this project.'),
80-
securityAndComplianceLabel: s__('ProjectSettings|Security and Compliance'),
80+
securityAndComplianceLabel: s__('ProjectSettings|Security and compliance'),
8181
snippetsLabel: s__('ProjectSettings|Snippets'),
8282
wikiLabel: s__('ProjectSettings|Wiki'),
8383
pucWarningLabel: s__('ProjectSettings|Warn about Potentially Unwanted Characters'),

app/assets/javascripts/security_configuration/utils.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ import { REPORT_TYPE_DAST } from '~/vue_shared/security_reports/constants';
1111
* It then filters out any scanner features that lack a security config for rednering in the UI
1212
* @param [{}] features
1313
* @param {Object} securityFeatures Object containing client side UI options
14-
* @returns {Object} Object with enriched features from constants divided into Security and Compliance Features
14+
* @returns {Object} Object with enriched features from constants divided into Security and compliance Features
1515
*/
1616

1717
export const augmentFeatures = (securityFeatures, features = []) => {

app/controllers/concerns/integrations/actions.rb

+2-2
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@ module Integrations::Actions
1313
before_action :integration, only: [:edit, :update, :overrides, :test]
1414
# rubocop:enable Rails/LexicallyScopedActionFilter
1515

16-
before_action :render_404, only: :edit, if: -> do
17-
integration.to_param == 'prometheus' && Feature.enabled?(:remove_monitor_metrics)
16+
before_action :render_404, only: [:edit, :update, :overrides, :test], if: -> do
17+
integration.is_a?(::Integrations::Prometheus) && Feature.enabled?(:remove_monitor_metrics)
1818
end
1919

2020
urgency :low, [:test]

app/controllers/projects/settings/integrations_controller.rb

+5-3
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,10 @@ class IntegrationsController < Projects::ApplicationController
1313
before_action :web_hook_logs, only: [:edit, :update]
1414
before_action -> { check_test_rate_limit! }, only: :test
1515

16+
before_action :render_404, only: [:edit, :update, :test], if: -> do
17+
integration.is_a?(::Integrations::Prometheus) && Feature.enabled?(:remove_monitor_metrics)
18+
end
19+
1620
respond_to :html
1721

1822
layout "project_settings"
@@ -24,9 +28,7 @@ def index
2428
@integrations = @project.find_or_initialize_integrations
2529
end
2630

27-
def edit
28-
render_404 if integration.to_param == 'prometheus' && Feature.enabled?(:remove_monitor_metrics)
29-
end
31+
def edit; end
3032

3133
def update
3234
attributes = integration_params[:integration]

app/finders/banzai/uploads_finder.rb

+2
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22

33
module Banzai
44
class UploadsFinder
5+
include FinderMethods
6+
57
def initialize(parent:)
68
@parent = parent
79
end

app/finders/organizations/groups_finder.rb

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ module Organizations
44
class GroupsFinder < GroupsFinder
55
def execute
66
groups = find_union(filtered_groups, Group)
7-
groups = groups.without_deleted if Feature.enabled?(:filter_deleted_groups, current_user)
7+
groups = groups.without_deleted
88

99
unless default_organization?
1010
cte = Gitlab::SQL::CTE.new(:filtered_groups_cte, groups, materialized: false)

app/models/ci/build.rb

+1-1
Original file line numberDiff line numberDiff line change
@@ -233,7 +233,7 @@ def clone_accessors
233233
yaml_variables when environment coverage_regex
234234
description tag_list protected needs_attributes
235235
job_variables_attributes resource_group scheduling_type
236-
ci_stage partition_id id_tokens interruptible].freeze
236+
ci_stage partition_id id_tokens interruptible execution_config_id].freeze
237237
end
238238

239239
def supported_keyset_orderings

app/models/upload.rb

+7-6
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ class Upload < ApplicationRecord
2020
scope :for_model_type_and_id, ->(type, id) { where(model_type: type, model_id: id) }
2121
scope :for_uploader, ->(uploader_class) { where(uploader: uploader_class.to_s) }
2222
scope :order_by_created_at_desc, -> { reorder(created_at: :desc) }
23+
scope :preload_uploaded_by_user, -> { preload(:uploaded_by_user) }
2324

2425
before_save :calculate_checksum!, if: :foreground_checksummable?
2526
# as the FileUploader is not mounted, the default CarrierWave ActiveRecord
@@ -98,7 +99,7 @@ def build_uploader(mounted_as = nil)
9899
# @return [GitlabUploader] one of the subclasses, defined at the model's uploader attribute
99100
def retrieve_uploader(mounted_as = nil)
100101
build_uploader(mounted_as).tap do |uploader|
101-
uploader.retrieve_from_store!(identifier)
102+
uploader.retrieve_from_store!(filename)
102103
end
103104
end
104105

@@ -124,7 +125,7 @@ def exist?
124125

125126
def uploader_context
126127
{
127-
identifier: identifier,
128+
identifier: filename,
128129
secret: secret,
129130
uploaded_by_user_id: uploaded_by_user_id
130131
}.compact
@@ -144,6 +145,10 @@ def needs_checksum?
144145
checksum.nil? && local? && exist?
145146
end
146147

148+
def filename
149+
File.basename(path)
150+
end
151+
147152
private
148153

149154
def delete_file!
@@ -166,10 +171,6 @@ def uploader_class
166171
Object.const_get(uploader, false)
167172
end
168173

169-
def identifier
170-
File.basename(path)
171-
end
172-
173174
def mount_point
174175
super&.to_sym
175176
end

app/policies/group_policy.rb

+1
Original file line numberDiff line numberDiff line change
@@ -256,6 +256,7 @@ class GroupPolicy < Namespaces::GroupProjectNamespaceSharedPolicy
256256
enable :create_jira_connect_subscription
257257
enable :maintainer_access
258258
enable :read_upload
259+
enable :admin_upload
259260
enable :destroy_upload
260261
enable :admin_push_rules
261262
end

app/policies/project_policy.rb

+1
Original file line numberDiff line numberDiff line change
@@ -613,6 +613,7 @@ class ProjectPolicy < BasePolicy
613613
enable :admin_project_aws
614614
enable :admin_secure_files
615615
enable :read_upload
616+
enable :admin_upload
616617
enable :destroy_upload
617618
enable :admin_incident_management_timeline_event_tag
618619
enable :stop_environment

app/validators/json_schema_validator.rb

+1-1
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ def initialize(options)
2525
end
2626

2727
def validate_each(record, attribute, value)
28-
value = value.to_h.deep_stringify_keys if options[:hash_conversion] == true
28+
value = Gitlab::Json.parse(Gitlab::Json.dump(value)) if options[:hash_conversion] == true
2929
value = Gitlab::Json.parse(value.to_s) if options[:parse_json] == true && !value.nil?
3030

3131
if options[:detail_errors]

app/views/projects/merge_requests/_merge_request.html.haml

+2-2
Original file line numberDiff line numberDiff line change
@@ -26,13 +26,13 @@
2626
&middot;
2727
#{s_('IssueList|created %{timeAgoString} by %{user}').html_safe % { timeAgoString: time_ago_with_tooltip(merge_request.created_at, placement: 'bottom'), user: link_to_member(@project, merge_request.author, avatar: false, extra_class: 'gl-text-gray-500!') }}
2828
- if merge_request.milestone
29-
%span.issuable-milestone.gl-inline-block.gl-text-truncate.gl-max-w-26.gl-align-bottom
29+
%span.issuable-milestone.gl-inline-block
3030
&nbsp;
3131
= link_to project_merge_requests_path(merge_request.project, milestone_title: merge_request.milestone.title), class: 'gl-text-gray-500!', data: { html: 'true', toggle: 'tooltip', title: milestone_tooltip_due_date(merge_request.milestone) } do
3232
= sprite_icon('milestone', size: 12, css_class: 'gl-vertical-align-text-bottom')
3333
= merge_request.milestone.title
3434
- if merge_request.target_project.default_branch != merge_request.target_branch
35-
%span.project-ref-path.has-tooltip.gl-inline-block.gl-text-truncate.gl-max-w-26.gl-align-bottom{ title: _('Target branch: %{target_branch}') % {target_branch: merge_request.target_branch} }
35+
%span.project-ref-path.has-tooltip.gl-inline-block{ title: _('Target branch: %{target_branch}') % {target_branch: merge_request.target_branch} }
3636
&nbsp;
3737
= link_to project_ref_path(merge_request.project, merge_request.target_branch), class: 'ref-name gl-text-gray-500!' do
3838
= sprite_icon('branch', size: 12, css_class: 'fork-sprite')
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
---
2-
name: filter_deleted_groups
3-
feature_issue_url: https://gitlab.com/gitlab-org/gitlab/-/issues/455871
4-
introduced_by_url: https://gitlab.com/gitlab-org/gitlab/-/merge_requests/158309
5-
rollout_issue_url: https://gitlab.com/gitlab-org/gitlab/-/issues/470628
2+
name: pipeline_run_keyword
3+
feature_issue_url: https://gitlab.com/gitlab-org/gitlab/-/issues/440487
4+
introduced_by_url: https://gitlab.com/gitlab-org/gitlab/-/merge_requests/146333
5+
rollout_issue_url: https://gitlab.com/gitlab-org/gitlab/-/issues/471925
66
milestone: '17.2'
7-
group: group::tenant scale
7+
group: group::pipeline authoring
88
type: gitlab_com_derisk
99
default_enabled: false

doc/administration/custom_project_templates.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ Prerequisites:
5757
1. Review the project's
5858
[feature settings](../user/project/settings/index.md#configure-project-features-and-permissions).
5959
All enabled project features should be set to **Everyone With Access**, except
60-
**GitLab Pages** and **Security and Compliance**.
60+
**GitLab Pages** and **Security and compliance**.
6161

6262
Repository and database information that are copied over to each new project are
6363
identical to the data exported with the [GitLab Project Import/Export](../user/project/settings/import_export.md).

doc/administration/settings/security_and_compliance.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ group: Composition Analysis
44
info: To determine the technical writer assigned to the Stage/Group associated with this page, see https://handbook.gitlab.com/handbook/product/ux/technical-writing/#assignments
55
---
66

7-
# Security and Compliance Admin area settings
7+
# Security and compliance Admin area settings
88

99
DETAILS:
1010
**Tier:** Ultimate
@@ -17,7 +17,7 @@ The settings for package metadata synchronization are located in the [Admin area
1717
To choose the packages you want to synchronize with the GitLab Package Metadata Database for [License Compliance](../../user/compliance/license_scanning_of_cyclonedx_files/index.md) and [Continuous Vulnerability Scanning](../../user/application_security/continuous_vulnerability_scanning/index.md):
1818

1919
1. On the left sidebar, at the bottom, select **Admin area**.
20-
1. Select **Settings > Security and Compliance**.
20+
1. Select **Settings > Security and compliance**.
2121
1. In **Package registry metadata to sync**, select or clear checkboxes for the
2222
package registries that you want to sync.
2323
1. Select **Save changes**.

0 commit comments

Comments
 (0)