Skip to content

Commit

Permalink
Add latest changes from gitlab-org/gitlab@master
Browse files Browse the repository at this point in the history
  • Loading branch information
GitLab Bot committed Dec 4, 2023
1 parent 6974fff commit 1570618
Show file tree
Hide file tree
Showing 40 changed files with 345 additions and 247 deletions.
2 changes: 1 addition & 1 deletion .gitlab/ci/rules.gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2640,9 +2640,9 @@
when: never
- <<: *if-merge-request-labels-pipeline-expedite
when: never
- <<: *if-merge-request-labels-run-review-app
- if: '$CI_REVIEW_APPS_ENABLED != "true"'
when: never
- <<: *if-merge-request-labels-run-review-app
- <<: *if-merge-request-not-approved
when: never
- <<: *if-dot-com-gitlab-org-merge-request
Expand Down
3 changes: 2 additions & 1 deletion .rubocop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -871,7 +871,8 @@ Migration/ReferToIndexByName:
Migration/CreateTableWithForeignKeys:
# Disable this cop for all the existing migrations
Exclude:
- !ruby/regexp /\Adb\/(?:post_)?migrate\/(?:201[0-9]\d+|20200[0-8][0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9])_.+\.rb\z/
- !ruby/regexp /\Adb\/(post_)?migrate\/201.*\.rb\z/
- !ruby/regexp /\Adb\/(post_)?migrate\/2022[1-11].*\.rb\z/

Migration/PreventIndexCreation:
Exclude:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@ import DetailsRow from '~/vue_shared/components/registry/details_row.vue';
export default {
i18n: {
requiredPython: s__('PackageRegistry|Required Python: %{pythonVersion}'),
summary: s__('PackageRegistry|Summary: %{summary}'),
authorEmail: s__('PackageRegistry|Author email: %{authorEmail}'),
keywords: s__('PackageRegistry|Keywords: %{keywords}'),
},
components: {
DetailsRow,
Expand All @@ -24,12 +27,33 @@ export default {

<template>
<div>
<details-row icon="information-o" padding="gl-p-4" data-testid="pypi-required-python">
<details-row dashed icon="information-o" padding="gl-p-4" data-testid="pypi-required-python">
<gl-sprintf :message="$options.i18n.requiredPython">
<template #pythonVersion>
<strong>{{ packageMetadata.requiredPython }}</strong>
</template>
</gl-sprintf>
</details-row>
<details-row dashed icon="doc-text" padding="gl-p-4" data-testid="pypi-summary">
<gl-sprintf :message="$options.i18n.summary">
<template #summary>
<strong>{{ packageMetadata.summary }}</strong>
</template>
</gl-sprintf>
</details-row>
<details-row dashed icon="doc-text" padding="gl-p-4" data-testid="pypi-keywords">
<gl-sprintf :message="$options.i18n.keywords">
<template #keywords>
<strong>{{ packageMetadata.keywords }}</strong>
</template>
</gl-sprintf>
</details-row>
<details-row dashed icon="mail" padding="gl-p-4" data-testid="pypi-author-email">
<gl-sprintf :message="$options.i18n.authorEmail">
<template #authorEmail>
<strong>{{ packageMetadata.authorEmail }}</strong>
</template>
</gl-sprintf>
</details-row>
</div>
</template>
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,10 @@ query getPackageMetadata($id: PackagesPackageID!) {
}
... on PypiMetadata {
id
authorEmail
keywords
requiredPython
summary
}
... on ConanMetadata {
id
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,12 +32,14 @@ export default {

<template>
<div
class="gl-display-flex gl-align-items-center gl-font-monospace gl-font-sm gl-word-break-all"
class="gl-display-flex gl-align-items-top gl-font-monospace gl-font-sm gl-word-break-all"
:class="[padding, borderClass]"
>
<gl-icon v-if="icon" :name="icon" class="gl-mr-4" />
<span>
<div v-if="icon" class="gl-w-5 gl-mr-4">
<gl-icon :name="icon" />
</div>
<div>
<slot></slot>
</span>
</div>
</div>
</template>
2 changes: 1 addition & 1 deletion app/models/ci/catalog/listing.rb
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ def by_search(relation, search)

def by_scope(relation, scope)
if scope == :namespaces && Feature.enabled?(:ci_guard_for_catalog_resource_scope, current_user)
relation.merge(Project.public_and_internal_only.visible_to_user(current_user))
relation.merge(Project.visible_to_user(current_user))
else
relation.merge(Project.public_or_visible_to_user(current_user))
end
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
---
name: contributions_calendar_refactoring
introduced_by_url: https://gitlab.com/gitlab-org/gitlab/-/merge_requests/134991
rollout_issue_url: https://gitlab.com/gitlab-org/gitlab/-/issues/429648
milestone: '16.6'
name: self_managed_code_suggestions
introduced_by_url: https://gitlab.com/gitlab-org/gitlab/-/merge_requests/138490
rollout_issue_url: https://gitlab.com/gitlab-org/gitlab/-/issues/432983
milestone: '16.7'
type: development
group: group::tenant scale
group: group::purchase
default_enabled: false
1 change: 1 addition & 0 deletions config/routes.rb
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
InitializerConnections.raise_if_new_database_connection do
Rails.application.routes.draw do
concern :access_requestable do
get :request_access, on: :collection
post :request_access, on: :collection
post :approve_access_request, on: :member
end
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# frozen_string_literal: true

class RemoveApplicationSettingsColumns < Gitlab::Database::Migration[2.2]
milestone '16.7'

disable_ddl_transaction!

def up
remove_column :application_settings, :elasticsearch_shards, if_exists: true
remove_column :application_settings, :elasticsearch_replicas, if_exists: true
remove_column :application_settings, :static_objects_external_storage_auth_token, if_exists: true
remove_column :application_settings, :web_ide_clientside_preview_enabled, if_exists: true
end

def down
add_column :application_settings, :elasticsearch_shards, :integer, default: 5, null: false, if_not_exists: true
add_column :application_settings, :elasticsearch_replicas, :integer, default: 1, null: false, if_not_exists: true
add_column :application_settings, :static_objects_external_storage_auth_token, :string, limit: 255,
if_not_exists: true
add_column :application_settings, :web_ide_clientside_preview_enabled, :boolean, default: false, null: false,
if_not_exists: true
end
end
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
# frozen_string_literal: true

class IndexProjectsOnOrganizationIdAndId < Gitlab::Database::Migration[2.2]
milestone '16.7'
disable_ddl_transaction!

INDEX_NAME = "index_projects_on_organization_id_and_id"

def up
# rubocop:disable Migration/PreventIndexCreation -- Replacing existing index
# on organization_id with an index on (organization_id, id)
add_concurrent_index :projects, [:organization_id, :id], name: INDEX_NAME
# rubocop:enable Migration/PreventIndexCreation
end

def down
remove_concurrent_index :projects, [:organization_id, :id], name: INDEX_NAME
end
end
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# frozen_string_literal: true

class RemoveIndexOnOrganizationIdProjectsTable < Gitlab::Database::Migration[2.2]
milestone '16.7'
disable_ddl_transaction!

INDEX_NAME = 'index_projects_on_organization_id'

def up
remove_concurrent_index_by_name :projects, INDEX_NAME
end

def down
add_concurrent_index :projects, :organization_id, name: INDEX_NAME
end
end
1 change: 1 addition & 0 deletions db/schema_migrations/20231127171903
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
af73341ffb326a6e9d4f6b6aa836f5888182278626f51cc193f5ca906c4ccf4e
1 change: 1 addition & 0 deletions db/schema_migrations/20231202175941
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
8d752179a1544a0dad7c1df99ed332002b8ebd0191d3ae7434366267e227987f
1 change: 1 addition & 0 deletions db/schema_migrations/20231202180101
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
432843177f4e67613b94bd24de3ab6903d4295a591545247ca7c264c18720ad6
6 changes: 1 addition & 5 deletions db/structure.sql
Original file line number Diff line number Diff line change
Expand Up @@ -11873,7 +11873,6 @@ CREATE TABLE application_settings (
snowplow_enabled boolean DEFAULT false NOT NULL,
snowplow_collector_hostname character varying,
snowplow_cookie_domain character varying,
web_ide_clientside_preview_enabled boolean DEFAULT false NOT NULL,
user_show_add_ssh_key_message boolean DEFAULT true NOT NULL,
custom_project_templates_group_id integer,
usage_stats_set_by_user_id integer,
Expand All @@ -11890,8 +11889,6 @@ CREATE TABLE application_settings (
lets_encrypt_notification_email character varying,
lets_encrypt_terms_of_service_accepted boolean DEFAULT false NOT NULL,
geo_node_allowed_ips character varying DEFAULT '0.0.0.0/0, ::/0'::character varying,
elasticsearch_shards integer DEFAULT 5 NOT NULL,
elasticsearch_replicas integer DEFAULT 1 NOT NULL,
encrypted_lets_encrypt_private_key text,
encrypted_lets_encrypt_private_key_iv text,
required_instance_ci_template character varying,
Expand All @@ -11912,7 +11909,6 @@ CREATE TABLE application_settings (
encrypted_asset_proxy_secret_key text,
encrypted_asset_proxy_secret_key_iv character varying,
static_objects_external_storage_url character varying(255),
static_objects_external_storage_auth_token character varying(255),
max_personal_access_token_lifetime integer,
throttle_protected_paths_enabled boolean DEFAULT false NOT NULL,
throttle_protected_paths_requests_per_period integer DEFAULT 10 NOT NULL,
Expand Down Expand Up @@ -34198,7 +34194,7 @@ CREATE INDEX index_projects_on_namespace_id_and_id ON projects USING btree (name

CREATE INDEX index_projects_on_namespace_id_and_repository_size_limit ON projects USING btree (namespace_id, repository_size_limit);

CREATE INDEX index_projects_on_organization_id ON projects USING btree (organization_id);
CREATE INDEX index_projects_on_organization_id_and_id ON projects USING btree (organization_id, id);

CREATE INDEX index_projects_on_path_trigram ON projects USING gin (path gin_trgm_ops);

Expand Down
Loading

0 comments on commit 1570618

Please sign in to comment.