Commit 0f0a8be3 authored by GitLab Bot's avatar GitLab Bot

Add latest changes from gitlab-org/gitlab@master

parent 3fe9588b
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
extends: extends:
- .default-tags - .default-tags
- .default-retry - .default-retry
- .only-docs-changes - .only:changes-docs
only: only:
refs: refs:
- merge_requests - merge_requests
...@@ -50,7 +50,7 @@ docs lint: ...@@ -50,7 +50,7 @@ docs lint:
- .default-tags - .default-tags
- .default-retry - .default-retry
- .default-only - .default-only
- .only-docs-changes - .only:changes-docs
image: "registry.gitlab.com/gitlab-org/gitlab-build-images:gitlab-docs-lint" image: "registry.gitlab.com/gitlab-org/gitlab-build-images:gitlab-docs-lint"
stage: test stage: test
dependencies: [] dependencies: []
...@@ -76,7 +76,7 @@ graphql-docs-verify: ...@@ -76,7 +76,7 @@ graphql-docs-verify:
- .default-cache - .default-cache
- .default-only - .default-only
- .default-before_script - .default-before_script
- .only-graphql-changes - .only:changes-graphql
variables: variables:
SETUP_DB: "false" SETUP_DB: "false"
stage: test stage: test
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
- .default-only - .default-only
- .default-before_script - .default-before_script
- .assets-compile-cache - .assets-compile-cache
- .only-code-qa-changes - .only:changes-code-backstage-qa
image: registry.gitlab.com/gitlab-org/gitlab-build-images:ruby-2.6.3-git-2.22-chrome-73.0-node-12.x-yarn-1.16-graphicsmagick-1.3.33-docker-18.06.1 image: registry.gitlab.com/gitlab-org/gitlab-build-images:ruby-2.6.3-git-2.22-chrome-73.0-node-12.x-yarn-1.16-graphicsmagick-1.3.33-docker-18.06.1
stage: test stage: test
dependencies: ["setup-test-env"] dependencies: ["setup-test-env"]
...@@ -73,7 +73,7 @@ gitlab:assets:compile pull-cache: ...@@ -73,7 +73,7 @@ gitlab:assets:compile pull-cache:
- .default-only - .default-only
- .default-before_script - .default-before_script
- .assets-compile-cache - .assets-compile-cache
- .only-code-qa-changes - .only:changes-code-backstage-qa
- .use-pg9 - .use-pg9
stage: prepare stage: prepare
script: script:
...@@ -128,7 +128,7 @@ compile-assets pull-cache foss: ...@@ -128,7 +128,7 @@ compile-assets pull-cache foss:
- .default-cache - .default-cache
- .default-only - .default-only
- .default-before_script - .default-before_script
- .only-code-changes - .only:changes-code-backstage
- .use-pg9 - .use-pg9
stage: test stage: test
needs: ["setup-test-env", "compile-assets pull-cache"] needs: ["setup-test-env", "compile-assets pull-cache"]
...@@ -205,7 +205,7 @@ jest-foss: ...@@ -205,7 +205,7 @@ jest-foss:
- .default-retry - .default-retry
- .default-cache - .default-cache
- .default-only - .default-only
- .only-code-changes - .only:changes-code-backstage
stage: test stage: test
dependencies: [] dependencies: []
cache: cache:
...@@ -238,7 +238,7 @@ webpack-dev-server: ...@@ -238,7 +238,7 @@ webpack-dev-server:
- .default-retry - .default-retry
- .default-cache - .default-cache
- .default-only - .default-only
- .only-code-changes - .only:changes-code-backstage
stage: test stage: test
needs: ["setup-test-env", "compile-assets pull-cache"] needs: ["setup-test-env", "compile-assets pull-cache"]
dependencies: ["setup-test-env", "compile-assets pull-cache"] dependencies: ["setup-test-env", "compile-assets pull-cache"]
......
...@@ -40,14 +40,11 @@ ...@@ -40,14 +40,11 @@
- merge_requests - merge_requests
- tags - tags
.only-code-changes: .code-patterns: &code-patterns
only:
changes:
- ".gitlab/ci/**/*" - ".gitlab/ci/**/*"
- ".{eslintignore,gitattributes,nvmrc,prettierrc,stylelintrc,yamllint}" - ".{eslintignore,gitattributes,nvmrc,prettierrc,stylelintrc,yamllint}"
- ".{codeclimate,eslintrc,gitlab-ci,haml-lint,haml-lint_todo,rubocop,rubocop_todo,scss-lint}.yml" - ".{codeclimate,eslintrc,gitlab-ci,haml-lint,haml-lint_todo,rubocop,rubocop_todo,scss-lint}.yml"
- ".csscomb.json" - ".csscomb.json"
- "Dangerfile"
- "Dockerfile.assets" - "Dockerfile.assets"
- "*_VERSION" - "*_VERSION"
- "Gemfile{,.lock}" - "Gemfile{,.lock}"
...@@ -55,36 +52,75 @@ ...@@ -55,36 +52,75 @@
- "{babel.config,jest.config}.js" - "{babel.config,jest.config}.js"
- "config.ru" - "config.ru"
- "{package.json,yarn.lock}" - "{package.json,yarn.lock}"
- "{app,bin,config,danger,db,ee,fixtures,haml_lint,lib,locale,public,rubocop,scripts,spec,symbol,vendor}/**/*" - "{,ee/}{app,bin,config,db,haml_lint,lib,locale,public,scripts,symbol,vendor}/**/*"
.backstage-patterns: &backstage-patterns
- "Dangerfile"
- "danger/**/*"
- "{,ee/}fixtures/**/*"
- "{,ee/}rubocop/**/*"
- "{,ee/}spec/**/*"
- "doc/README.md" # Some RSpec test rely on this file - "doc/README.md" # Some RSpec test rely on this file
.only-qa-changes: .qa-patterns: &qa-patterns
only:
changes:
- ".dockerignore" - ".dockerignore"
- "qa/**/*" - "qa/**/*"
.only-docs-changes: .docs-patterns: &docs-patterns
only:
changes:
- ".gitlab/route-map.yml" - ".gitlab/route-map.yml"
- "doc/**/*" - "doc/**/*"
- ".markdownlint.json" - ".markdownlint.json"
.only-graphql-changes: .graphql-patterns: &graphql-patterns
only:
changes:
- "{,ee/}app/graphql/**/*" - "{,ee/}app/graphql/**/*"
- "{,ee/}lib/gitlab/graphql/**/*" - "{,ee/}lib/gitlab/graphql/**/*"
.only-code-qa-changes: .only:changes-code:
only:
changes: *code-patterns
.only:changes-qa:
only:
changes: *qa-patterns
.only:changes-docs:
only:
changes: *docs-patterns
.only:changes-graphql:
only:
changes: *graphql-patterns
.only:changes-code-backstage:
only: only:
changes: changes:
- ".gitlab/ci/**/*" - ".gitlab/ci/**/*"
- ".{eslintignore,gitattributes,nvmrc,prettierrc,stylelintrc,yamllint}" - ".{eslintignore,gitattributes,nvmrc,prettierrc,stylelintrc,yamllint}"
- ".{codeclimate,eslintrc,gitlab-ci,haml-lint,haml-lint_todo,rubocop,rubocop_todo,scss-lint}.yml" - ".{codeclimate,eslintrc,gitlab-ci,haml-lint,haml-lint_todo,rubocop,rubocop_todo,scss-lint}.yml"
- ".csscomb.json" - ".csscomb.json"
- "Dockerfile.assets"
- "*_VERSION"
- "Gemfile{,.lock}"
- "Rakefile"
- "{babel.config,jest.config}.js"
- "config.ru"
- "{package.json,yarn.lock}"
- "{,ee/}{app,bin,config,db,haml_lint,lib,locale,public,scripts,symbol,vendor}/**/*"
# Backstage changes
- "Dangerfile" - "Dangerfile"
- "danger/**/*"
- "{,ee/}fixtures/**/*"
- "{,ee/}rubocop/**/*"
- "{,ee/}spec/**/*"
- "doc/README.md" # Some RSpec test rely on this file
.only:changes-code-qa:
only:
changes:
- ".gitlab/ci/**/*"
- ".{eslintignore,gitattributes,nvmrc,prettierrc,stylelintrc,yamllint}"
- ".{codeclimate,eslintrc,gitlab-ci,haml-lint,haml-lint_todo,rubocop,rubocop_todo,scss-lint}.yml"
- ".csscomb.json"
- "Dockerfile.assets" - "Dockerfile.assets"
- "*_VERSION" - "*_VERSION"
- "Gemfile{,.lock}" - "Gemfile{,.lock}"
...@@ -92,8 +128,34 @@ ...@@ -92,8 +128,34 @@
- "{babel.config,jest.config}.js" - "{babel.config,jest.config}.js"
- "config.ru" - "config.ru"
- "{package.json,yarn.lock}" - "{package.json,yarn.lock}"
- "{app,bin,config,danger,db,ee,fixtures,haml_lint,lib,locale,public,rubocop,scripts,spec,symbol,vendor}/**/*" - "{,ee/}{app,bin,config,db,haml_lint,lib,locale,public,scripts,symbol,vendor}/**/*"
# QA changes
- ".dockerignore"
- "qa/**/*"
.only:changes-code-backstage-qa:
only:
changes:
- ".gitlab/ci/**/*"
- ".{eslintignore,gitattributes,nvmrc,prettierrc,stylelintrc,yamllint}"
- ".{codeclimate,eslintrc,gitlab-ci,haml-lint,haml-lint_todo,rubocop,rubocop_todo,scss-lint}.yml"
- ".csscomb.json"
- "Dockerfile.assets"
- "*_VERSION"
- "Gemfile{,.lock}"
- "Rakefile"
- "{babel.config,jest.config}.js"
- "config.ru"
- "{package.json,yarn.lock}"
- "{,ee/}{app,bin,config,db,haml_lint,lib,locale,public,scripts,symbol,vendor}/**/*"
# Backstage changes
- "Dangerfile"
- "danger/**/*"
- "{,ee/}fixtures/**/*"
- "{,ee/}rubocop/**/*"
- "{,ee/}spec/**/*"
- "doc/README.md" # Some RSpec test rely on this file - "doc/README.md" # Some RSpec test rely on this file
# QA changes
- ".dockerignore" - ".dockerignore"
- "qa/**/*" - "qa/**/*"
......
...@@ -5,7 +5,7 @@ ...@@ -5,7 +5,7 @@
- .default-cache - .default-cache
- .default-only - .default-only
- .default-before_script - .default-before_script
- .only-code-changes - .only:changes-code
memory-static: memory-static:
extends: .only-code-memory-job-base extends: .only-code-memory-job-base
......
...@@ -4,7 +4,7 @@ pages: ...@@ -4,7 +4,7 @@ pages:
- .default-retry - .default-retry
- .default-cache - .default-cache
- .default-only - .default-only
- .only-code-qa-changes - .only:changes-code-backstage-qa
only: only:
refs: refs:
- master - master
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
- .default-tags - .default-tags
- .default-retry - .default-retry
- .default-only - .default-only
- .only-code-qa-changes - .only:changes-code-qa
stage: test stage: test
dependencies: [] dependencies: []
cache: cache:
...@@ -47,7 +47,7 @@ qa:selectors-foss: ...@@ -47,7 +47,7 @@ qa:selectors-foss:
package-and-qa-manual: package-and-qa-manual:
extends: extends:
- .package-and-qa-base - .package-and-qa-base
- .only-code-changes - .only:changes-code
except: except:
refs: refs:
- master - master
...@@ -58,7 +58,7 @@ package-and-qa-manual: ...@@ -58,7 +58,7 @@ package-and-qa-manual:
package-and-qa: package-and-qa:
extends: extends:
- .package-and-qa-base - .package-and-qa-base
- .only-qa-changes - .only:changes-qa
except: except:
refs: refs:
- master - master
...@@ -69,6 +69,6 @@ package-and-qa: ...@@ -69,6 +69,6 @@ package-and-qa:
schedule:package-and-qa: schedule:package-and-qa:
extends: extends:
- .package-and-qa-base - .package-and-qa-base
- .only-code-qa-changes - .only:changes-code-qa
- .only-canonical-schedules - .only-canonical-schedules
needs: ["build-qa-image", "gitlab:assets:compile pull-cache"] needs: ["build-qa-image", "gitlab:assets:compile pull-cache"]
...@@ -22,7 +22,7 @@ ...@@ -22,7 +22,7 @@
- .default-cache - .default-cache
- .default-only - .default-only
- .default-before_script - .default-before_script
- .only-code-changes - .only:changes-code-backstage
.only-code-qa-rails-job-base: .only-code-qa-rails-job-base:
extends: extends:
...@@ -31,7 +31,7 @@ ...@@ -31,7 +31,7 @@
- .default-cache - .default-cache
- .default-only - .default-only
- .default-before_script - .default-before_script
- .only-code-qa-changes - .only:changes-code-backstage-qa
setup-test-env: setup-test-env:
extends: extends:
...@@ -251,7 +251,7 @@ static-analysis: ...@@ -251,7 +251,7 @@ static-analysis:
downtime_check: downtime_check:
extends: extends:
- .rake-exec - .rake-exec
- .only-code-changes - .only:changes-code-backstage
except: except:
refs: refs:
- master - master
......
...@@ -11,7 +11,7 @@ code_quality: ...@@ -11,7 +11,7 @@ code_quality:
extends: extends:
- .default-retry - .default-retry
- .default-only - .default-only
- .only-code-changes - .only:changes-code-backstage
stage: test stage: test
image: docker:stable image: docker:stable
allow_failure: true allow_failure: true
...@@ -50,7 +50,7 @@ sast: ...@@ -50,7 +50,7 @@ sast:
extends: extends:
- .default-retry - .default-retry
- .default-only - .default-only
- .only-code-changes - .only:changes-code-backstage-qa
stage: test stage: test
image: docker:stable image: docker:stable
variables: variables:
...@@ -132,7 +132,7 @@ dependency_scanning: ...@@ -132,7 +132,7 @@ dependency_scanning:
extends: extends:
- .default-retry - .default-retry
- .default-only - .default-only
- .only-code-changes - .only:changes-code-backstage-qa
stage: test stage: test
image: docker:stable image: docker:stable
variables: variables:
...@@ -195,7 +195,7 @@ dast: ...@@ -195,7 +195,7 @@ dast:
extends: extends:
- .default-retry - .default-retry
- .default-only - .default-only
- .only-code-qa-changes - .only:changes-code-qa
- .only-review - .only-review
stage: qa stage: qa
needs: ["review-deploy"] needs: ["review-deploy"]
......
...@@ -23,7 +23,7 @@ ...@@ -23,7 +23,7 @@
build-qa-image: build-qa-image:
extends: extends:
- .review-docker - .review-docker
- .only-code-qa-changes - .only:changes-code-qa
only: only:
variables: variables:
- $CI_SERVER_HOST == "gitlab.com" && $CI_PROJECT_NAMESPACE == "gitlab-org" - $CI_SERVER_HOST == "gitlab.com" && $CI_PROJECT_NAMESPACE == "gitlab-org"
...@@ -40,7 +40,7 @@ build-qa-image: ...@@ -40,7 +40,7 @@ build-qa-image:
- .default-tags - .default-tags
- .default-retry - .default-retry
- .default-only - .default-only
- .only-code-qa-changes - .only:changes-code-qa
stage: prepare stage: prepare
image: registry.gitlab.com/gitlab-org/gitlab-build-images:gitlab-charts-build-base image: registry.gitlab.com/gitlab-org/gitlab-build-images:gitlab-charts-build-base
allow_failure: true allow_failure: true
...@@ -66,7 +66,7 @@ manual:review-cleanup: ...@@ -66,7 +66,7 @@ manual:review-cleanup:
.review-build-cng-base: .review-build-cng-base:
extends: extends:
- .default-only - .default-only
- .only-code-qa-changes - .only:changes-code-qa
- .except-deploys - .except-deploys
image: ruby:2.6-alpine image: ruby:2.6-alpine
stage: review-prepare stage: review-prepare
...@@ -95,7 +95,7 @@ schedule:review-build-cng: ...@@ -95,7 +95,7 @@ schedule:review-build-cng:
- .default-tags - .default-tags
- .default-retry - .default-retry
- .default-only - .default-only
- .only-code-qa-changes - .only:changes-code-qa
- .except-deploys - .except-deploys
stage: review stage: review
image: registry.gitlab.com/gitlab-org/gitlab-build-images:gitlab-charts-build-base image: registry.gitlab.com/gitlab-org/gitlab-build-images:gitlab-charts-build-base
...@@ -189,7 +189,7 @@ review-cleanup-failed-deployment: ...@@ -189,7 +189,7 @@ review-cleanup-failed-deployment:
extends: extends:
- .review-docker - .review-docker
- .only-review - .only-review
- .only-code-qa-changes - .only:changes-code-qa
stage: qa stage: qa
allow_failure: true allow_failure: true
variables: variables:
...@@ -236,7 +236,7 @@ review-qa-all: ...@@ -236,7 +236,7 @@ review-qa-all:
.review-performance-base: .review-performance-base:
extends: extends:
- .review-docker - .review-docker
- .only-code-qa-changes - .only:changes-code-qa
stage: qa stage: qa
allow_failure: true allow_failure: true
before_script: before_script:
...@@ -288,7 +288,7 @@ parallel-spec-reports: ...@@ -288,7 +288,7 @@ parallel-spec-reports:
extends: extends:
- .default-tags - .default-tags
- .default-only - .default-only
- .only-code-qa-changes - .only:changes-code-qa
- .only-review - .only-review
- .except-deploys - .except-deploys
image: ruby:2.6-alpine image: ruby:2.6-alpine
......
...@@ -6,7 +6,7 @@ cache gems: ...@@ -6,7 +6,7 @@ cache gems:
- .default-retry - .default-retry
- .default-cache - .default-cache
- .default-before_script - .default-before_script
- .only-code-qa-changes - .only:changes-code-backstage-qa
stage: test stage: test
dependencies: ["setup-test-env"] dependencies: ["setup-test-env"]
needs: ["setup-test-env"] needs: ["setup-test-env"]
...@@ -29,7 +29,7 @@ cache gems: ...@@ -29,7 +29,7 @@ cache gems:
- .default-tags - .default-tags
- .default-retry - .default-retry
- .default-only - .default-only
- .only-code-changes - .only:changes-code-backstage
dependencies: [] dependencies: []
gitlab_git_test: gitlab_git_test:
......
.tests-metadata-state: .tests-metadata-state:
extends: extends:
- .default-only - .default-only
- .only-code-changes - .only:changes-code-backstage
variables: variables:
TESTS_METADATA_S3_BUCKET: "gitlab-ce-cache" TESTS_METADATA_S3_BUCKET: "gitlab-ce-cache"
before_script: before_script:
...@@ -48,7 +48,7 @@ flaky-examples-check: ...@@ -48,7 +48,7 @@ flaky-examples-check:
- .default-tags - .default-tags
- .default-retry - .default-retry
- .default-only - .default-only
- .only-code-changes - .only:changes-code-backstage
image: ruby:2.6-alpine image: ruby:2.6-alpine
stage: post-test stage: post-test
variables: variables:
......
...@@ -26,7 +26,8 @@ export default (resolvers = {}, config = {}) => { ...@@ -26,7 +26,8 @@ export default (resolvers = {}, config = {}) => {
createUploadLink(httpOptions), createUploadLink(httpOptions),
new BatchHttpLink(httpOptions), new BatchHttpLink(httpOptions),
), ),
cache: new InMemoryCache(config.cacheConfig), cache: new InMemoryCache({ ...config.cacheConfig, freezeResults: true }),
resolvers, resolvers,
assumeImmutableResults: true,
}); });
}; };
...@@ -23,6 +23,7 @@ ...@@ -23,6 +23,7 @@
.signup-heading h2 { .signup-heading h2 {
font-weight: $gl-font-weight-bold; font-weight: $gl-font-weight-bold;
padding: 0 10px;
@include media-breakpoint-down(md) { @include media-breakpoint-down(md) {
font-size: $gl-font-size-large; font-size: $gl-font-size-large;
......
...@@ -35,6 +35,10 @@ module Ci ...@@ -35,6 +35,10 @@ module Ci
refspecs: -> (build) { build.merge_request_ref? } refspecs: -> (build) { build.merge_request_ref? }
}.freeze }.freeze
DEFAULT_RETRIES = {
scheduler_failure: 2
}.freeze
has_one :deployment, as: :deployable, class_name: 'Deployment' has_one :deployment, as: :deployable, class_name: 'Deployment'
has_many :trace_sections, class_name: 'Ci::BuildTraceSection' has_many :trace_sections, class_name: 'Ci::BuildTraceSection'
has_many :trace_chunks, class_name: 'Ci::BuildTraceChunk', foreign_key: :build_id has_many :trace_chunks, class_name: 'Ci::BuildTraceChunk', foreign_key: :build_id
...@@ -372,18 +376,25 @@ module Ci ...@@ -372,18 +376,25 @@ module Ci
pipeline.builds.retried.where(name: self.name).count pipeline.builds.retried.where(name: self.name).count
end end
def retries_max def retry_failure?
normalized_retry.fetch(:max, 0) max_allowed_retries = nil
max_allowed_retries ||= options_retry_max if retry_on_reason_or_always?
max_allowed_retries ||= DEFAULT_RETRIES.fetch(failure_reason.to_sym, 0)
max_allowed_retries > 0 && retries_count < max_allowed_retries
end end
def retry_when def options_retry_max
normalized_retry.fetch(:when, ['always']) options_retry[:max]
end end
def retry_failure? def options_retry_when
return false if retries_max.zero? || retries_count >= retries_max options_retry.fetch(:when, ['always'])
end
retry_when.include?('always') || retry_when.include?(failure_reason.to_s) def retry_on_reason_or_always?
options_retry_when.include?(failure_reason.to_s) ||
options_retry_when.include?('always')
end end
def latest? def latest?
...@@ -831,6 +842,13 @@ module Ci ...@@ -831,6 +842,13 @@ module Ci
:creating :creating
end end
# Consider this object to have a structural integrity problems
def doom!
update_columns(
status: :failed,
failure_reason: :data_integrity_failure)
end
private private
def successful_deployment_status def successful_deployment_status
...@@ -875,8 +893,8 @@ module Ci ...@@ -875,8 +893,8 @@ module Ci
# format, but builds created before GitLab 11.5 and saved in database still # format, but builds created before GitLab 11.5 and saved in database still
# have the old integer only format. This method returns the retry option # have the old integer only format. This method returns the retry option
# normalized as a hash in 11.5+ format. # normalized as a hash in 11.5+ format.
def normalized_retry def options_retry
strong_memoize(:normalized_retry) do strong_memoize(:options_retry) do
value = options&.dig(:retry) value = options&.dig(:retry)
value = value.is_a?(Integer) ? { max: value } : value.to_h value = value.is_a?(Integer) ? { max: value } : value.to_h
value.with_indifferent_access value.with_indifferent_access
......
...@@ -15,7 +15,9 @@ module CommitStatusEnums ...@@ -15,7 +15,9 @@ module CommitStatusEnums
stale_schedule: 7, stale_schedule: 7,
job_execution_timeout: 8, job_execution_timeout: 8,
archived_failure: 9, archived_failure: 9,
unmet_prerequisites: 10 unmet_prerequisites: 10,
scheduler_failure: 11,
data_integrity_failure: 12
} }
end end
end end
......
...@@ -11,7 +11,9 @@ class CommitStatusPresenter < Gitlab::View::Presenter::Delegated ...@@ -11,7 +11,9 @@ class CommitStatusPresenter < Gitlab::View::Presenter::Delegated
stale_schedule: 'Delayed job could not be executed by some reason, please try again', stale_schedule: 'Delayed job could not be executed by some reason, please try again',
job_execution_timeout: 'The script exceeded the maximum execution time set for the job', job_execution_timeout: 'The script exceeded the maximum execution time set for the job',
archived_failure: 'The job is archived and cannot be run', archived_failure: 'The job is archived and cannot be run',
unmet_prerequisites: 'The job failed to complete prerequisite tasks' unmet_prerequisites: 'The job failed to complete prerequisite tasks',
scheduler_failure: 'The scheduler failed to assign job to the runner, please try again or contact system administrator',
data_integrity_failure: 'There has been a structural integrity problem detected, please contact system administrator'
}.freeze }.freeze
private_constant :CALLOUT_FAILURE_MESSAGES private_constant :CALLOUT_FAILURE_MESSAGES
...@@ -33,6 +35,6 @@ class CommitStatusPresenter < Gitlab::View::Presenter::Delegated ...@@ -33,6 +35,6 @@ class CommitStatusPresenter < Gitlab::View::Presenter::Delegated
end end
def unrecoverable? def unrecoverable?
script_failure? || missing_dependency_failure? || archived_failure? script_failure? || missing_dependency_failure? || archived_failure? || scheduler_failure? || data_integrity_failure?
end end
end end
...@@ -42,15 +42,34 @@ module Ci ...@@ -42,15 +42,34 @@ module Ci
end end
builds.each do |build| builds.each do |build|
next unless runner.can_pick?(build) result = process_build(build, params)
next unless result
if result.valid?
register_success(result.build)
return result
else
# The usage of valid: is described in
# handling of ActiveRecord::StaleObjectError
valid = false
end
end
register_failure
Result.new(nil, valid)
end
# rubocop: enable CodeReuse/ActiveRecord
private
def process_build(build, params)
return unless runner.can_pick?(build)
begin
# In case when 2 runners try to assign the same build, second runner will be declined # In case when 2 runners try to assign the same build, second runner will be declined
# with StateMachines::InvalidTransition or StaleObjectError when doing run! or save method. # with StateMachines::InvalidTransition or StaleObjectError when doing run! or save method.
if assign_runner!(build, params) if assign_runner!(build, params)
register_success(build) Result.new(build, true)
return Result.new(build, true)
end end
rescue StateMachines::InvalidTransition, ActiveRecord::StaleObjectError rescue StateMachines::InvalidTransition, ActiveRecord::StaleObjectError
# We are looping to find another build that is not conflicting # We are looping to find another build that is not conflicting
...@@ -62,16 +81,16 @@ module Ci ...@@ -62,16 +81,16 @@ module Ci
# In case we hit the concurrency-access lock, # In case we hit the concurrency-access lock,
# we still have to return 409 in the end, # we still have to return 409 in the end,
# to make sure that this is properly handled by runner. # to make sure that this is properly handled by runner.
valid = false Result.new(nil, false)
end rescue => ex
end raise ex unless Feature.enabled?(:ci_doom_build, default_enabled: true)
register_failure scheduler_failure!(build)
Result.new(nil, valid) track_exception_for_build(ex, build)
end
# rubocop: enable CodeReuse/ActiveRecord
private # skip, and move to next one
nil
end
def assign_runner!(build, params) def assign_runner!(build, params)
build.runner_id = runner.id build.runner_id = runner.id
...@@ -96,6 +115,28 @@ module Ci ...@@ -96,6 +115,28 @@ module Ci
true true
end end
def scheduler_failure!(build)
Gitlab::OptimisticLocking.retry_lock(build, 3) do |subject|
subject.drop!(:scheduler_failure)
end
rescue => ex
build.doom!
# This requires extra exception, otherwise we would loose information
# why we cannot perform `scheduler_failure`
track_exception_for_build(ex, build)
end
def track_exception_for_build(ex, build)
Gitlab::Sentry.track_acceptable_exception(ex, extra: {
build_id: build.id,
build_name: build.name,
build_stage: build.stage,
pipeline_id: build.pipeline_id,
project_id: build.project_id
})
end
# rubocop: disable CodeReuse/ActiveRecord # rubocop: disable CodeReuse/ActiveRecord
def builds_for_shared_runner def builds_for_shared_runner
new_builds. new_builds.
......
- content_for(:page_title, _('Welcome to GitLab<br>%{username}!' % { username: html_escape(current_user.username) }).html_safe) - content_for(:page_title, _('Welcome to GitLab %{username}!') % { username: current_user.username })
- max_name_length = 128 - max_name_length = 128
.text-center.mb-3 .text-center.mb-3
= _('In order to tailor your experience with GitLab<br>we would like to know a bit more about you.').html_safe = _('In order to tailor your experience with GitLab<br>we would like to know a bit more about you.').html_safe
......
---
title: Show approval required status in license compliance
merge_request: 19114
author:
type: changed
---
title: Make `jobs/request` to be resillient
merge_request: 19150
author:
type: fixed
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
# If a setting requires an application restart say so in that screen. # # If a setting requires an application restart say so in that screen. #
# If you change this file in a Merge Request, please also create # # If you change this file in a Merge Request, please also create #
# a MR on https://gitlab.com/gitlab-org/omnibus-gitlab/merge_requests. # # a MR on https://gitlab.com/gitlab-org/omnibus-gitlab/merge_requests. #
# For more details see https://gitlab.com/gitlab-org/omnibus-gitlab/blob/0928cfb09f43993fd9454b0b14dbd1924b1407bc/doc/settings/gitlab.yml.md # # For more details see https://gitlab.com/gitlab-org/omnibus-gitlab/blob/master/doc/settings/gitlab.yml.md #
######################################################################## ########################################################################
# #
# #
......
...@@ -12,10 +12,13 @@ class RemoveRendundantIndexFromReleases < ActiveRecord::Migration[5.2] ...@@ -12,10 +12,13 @@ class RemoveRendundantIndexFromReleases < ActiveRecord::Migration[5.2]
disable_ddl_transaction! disable_ddl_transaction!
def up def up
remove_concurrent_index :releases, :project_id remove_concurrent_index_by_name :releases, 'index_releases_on_project_id'
# This is an extra index that is not present in db/schema.rb but known to exist on some installs
remove_concurrent_index_by_name :releases, 'releases_project_id_idx'
end end
def down def down
add_concurrent_index :releases, :project_id add_concurrent_index :releases, :project_id, name: 'index_releases_on_project_id'
end end
end end
...@@ -62,6 +62,7 @@ class SyncIssuablesStateId < ActiveRecord::Migration[5.2] ...@@ -62,6 +62,7 @@ class SyncIssuablesStateId < ActiveRecord::Migration[5.2]
CASE state CASE state
WHEN 'opened' THEN 1 WHEN 'opened' THEN 1
WHEN 'closed' THEN 2 WHEN 'closed' THEN 2
ELSE 2
END END
SQL SQL
end end
...@@ -73,6 +74,7 @@ class SyncIssuablesStateId < ActiveRecord::Migration[5.2] ...@@ -73,6 +74,7 @@ class SyncIssuablesStateId < ActiveRecord::Migration[5.2]
WHEN 'closed' THEN 2 WHEN 'closed' THEN 2
WHEN 'merged' THEN 3 WHEN 'merged' THEN 3
WHEN 'locked' THEN 4 WHEN 'locked' THEN 4
ELSE 2
END END
SQL SQL
end end
......
...@@ -24,7 +24,7 @@ class ScheduleEpicIssuesAfterEpicsMove < ActiveRecord::Migration[5.2] ...@@ -24,7 +24,7 @@ class ScheduleEpicIssuesAfterEpicsMove < ActiveRecord::Migration[5.2]
Epic.each_batch(of: BATCH_SIZE) do |batch, index| Epic.each_batch(of: BATCH_SIZE) do |batch, index|
range = batch.pluck('MIN(id)', 'MAX(id)').first range = batch.pluck('MIN(id)', 'MAX(id)').first
delay = index * interval delay = index * INTERVAL
BackgroundMigrationWorker.perform_in(delay, MIGRATION, *range) BackgroundMigrationWorker.perform_in(delay, MIGRATION, *range)
end end
end end
......
...@@ -66,6 +66,14 @@ The API can be explored interactively using the [GraphiQL IDE](../index.md#graph ...@@ -66,6 +66,14 @@ The API can be explored interactively using the [GraphiQL IDE](../index.md#graph
| `errors` | String! => Array | Reasons why the mutation failed. | | `errors` | String! => Array | Reasons why the mutation failed. |
| `note` | Note | The note after mutation | | `note` | Note | The note after mutation |
### CreateEpicPayload
| Name | Type | Description |
| --- | ---- | ---------- |
| `clientMutationId` | String | A unique identifier for the client performing the mutation. |
| `errors` | String! => Array | Reasons why the mutation failed. |
| `epic` | Epic | The created epic |
### CreateImageDiffNotePayload ### CreateImageDiffNotePayload
| Name | Type | Description | | Name | Type | Description |
......
...@@ -5,8 +5,7 @@ ...@@ -5,8 +5,7 @@
The SCIM API implements the [the RFC7644 protocol](https://tools.ietf.org/html/rfc7644). The SCIM API implements the [the RFC7644 protocol](https://tools.ietf.org/html/rfc7644).
NOTE: **Note:** NOTE: **Note:**
[Group SSO](../user/group/saml_sso/index.md) and the feature [Group SSO](../user/group/saml_sso/index.md) must be enabled for the group. For more information, see [SCIM setup documentation](../user/group/saml_sso/scim_setup.md#requirements).
flag `:group_scim` must be enabled for the group. For more information, see [SCIM setup documentation](../user/group/saml_sso/scim_setup.md#requirements).
## Get a list of SAML users ## Get a list of SAML users
......
...@@ -3,9 +3,10 @@ ...@@ -3,9 +3,10 @@
> - Introduced prior to GitLab 12.3 at the project level. > - Introduced prior to GitLab 12.3 at the project level.
> - [Introduced](https://gitlab.com/gitlab-org/gitlab/issues/12077) in [GitLab Premium](https://about.gitlab.com/pricing/) 12.3 at the group level. > - [Introduced](https://gitlab.com/gitlab-org/gitlab/issues/12077) in [GitLab Premium](https://about.gitlab.com/pricing/) 12.3 at the group level.
Cycle Analytics measures the time spent to go from an [idea to production] - also known Cycle Analytics measures the time spent to go from an
as cycle time - for each of your projects. Cycle Analytics displays the median time for an idea to [idea to production](https://about.gitlab.com/blog/2016/08/05/continuous-integration-delivery-and-deployment-with-gitlab/#from-idea-to-production-with-gitlab)
reach production, along with the time typically spent in each DevOps stage along the way. (also known as cycle time) for each of your projects. Cycle Analytics displays the median time
spent in each stage defined in the process.
NOTE: **Note:** NOTE: **Note:**
Use the `cycle_analytics` feature flag to enable at the group level. Use the `cycle_analytics` feature flag to enable at the group level.
...@@ -14,8 +15,8 @@ Cycle Analytics is useful in order to quickly determine the velocity of a given ...@@ -14,8 +15,8 @@ Cycle Analytics is useful in order to quickly determine the velocity of a given
project. It points to bottlenecks in the development process, enabling management project. It points to bottlenecks in the development process, enabling management
to uncover, triage, and identify the root cause of slowdowns in the software development life cycle. to uncover, triage, and identify the root cause of slowdowns in the software development life cycle.
Cycle Analytics is tightly coupled with the [GitLab flow] and calculates a separate median for each Cycle Analytics is tightly coupled with the [GitLab flow](../../topics/gitlab_flow.md) and
stage. calculates a separate median for each stage.
## Overview ## Overview
...@@ -46,6 +47,16 @@ There are seven stages that are tracked as part of the Cycle Analytics calculati ...@@ -46,6 +47,16 @@ There are seven stages that are tracked as part of the Cycle Analytics calculati
- **Production** (Total) - **Production** (Total)
- Total lifecycle time; i.e. the velocity of the project or team - Total lifecycle time; i.e. the velocity of the project or team
## Date ranges
> [Introduced](https://gitlab.com/gitlab-org/gitlab/issues/13216) in GitLab 12.4.
GitLab provides the ability to filter analytics based on a date range. To filter results:
1. Select a group.
1. Optionally select a project.
1. Select a date range using the available date pickers.
## How the data is measured ## How the data is measured
Cycle Analytics records cycle time and data based on the project issues with the Cycle Analytics records cycle time and data based on the project issues with the
...@@ -53,7 +64,8 @@ exception of the staging and production stages, where only data deployed to ...@@ -53,7 +64,8 @@ exception of the staging and production stages, where only data deployed to
production are measured. production are measured.
Specifically, if your CI is not set up and you have not defined a `production` Specifically, if your CI is not set up and you have not defined a `production`
or `production/*` [environment], then you will not have any data for those stages. or `production/*` [environment](../../ci/yaml/README.md#environment), then you will not have any
data for those stages.
Each stage of Cycle Analytics is further described in the table below. Each stage of Cycle Analytics is further described in the table below.
...@@ -64,11 +76,9 @@ Each stage of Cycle Analytics is further described in the table below. ...@@ -64,11 +76,9 @@ Each stage of Cycle Analytics is further described in the table below.
| Code | Measures the median time between pushing a first commit (previous stage) and creating a merge request (MR) related to that commit. The key to keep the process tracked is to include the [issue closing pattern](../project/issues/managing_issues.md#closing-issues-automatically) to the description of the merge request (for example, `Closes #xxx`, where `xxx` is the number of the issue related to this merge request). If the issue closing pattern is not present in the merge request description, the MR is not considered to the measurement time of the stage. | | Code | Measures the median time between pushing a first commit (previous stage) and creating a merge request (MR) related to that commit. The key to keep the process tracked is to include the [issue closing pattern](../project/issues/managing_issues.md#closing-issues-automatically) to the description of the merge request (for example, `Closes #xxx`, where `xxx` is the number of the issue related to this merge request). If the issue closing pattern is not present in the merge request description, the MR is not considered to the measurement time of the stage. |
| Test | Measures the median time to run the entire pipeline for that project. It's related to the time GitLab CI takes to run every job for the commits pushed to that merge request defined in the previous stage. It is basically the start->finish time for all pipelines. | | Test | Measures the median time to run the entire pipeline for that project. It's related to the time GitLab CI takes to run every job for the commits pushed to that merge request defined in the previous stage. It is basically the start->finish time for all pipelines. |
| Review | Measures the median time taken to review the merge request that has closing issue pattern, between its creation and until it's merged. | | Review | Measures the median time taken to review the merge request that has closing issue pattern, between its creation and until it's merged. |
| Staging | Measures the median time between merging the merge request with closing issue pattern until the very first deployment to production. It's tracked by the [environment] set to `production` or matching `production/*` (case-sensitive, `Production` won't work) in your GitLab CI configuration. If there isn't a production environment, this is not tracked. | | Staging | Measures the median time between merging the merge request with closing issue pattern until the very first deployment to production. It's tracked by the environment set to `production` or matching `production/*` (case-sensitive, `Production` won't work) in your GitLab CI configuration. If there isn't a production environment, this is not tracked. |
| Production| The sum of all time (medians) taken to run the entire process, from issue creation to deploying the code to production. | | Production| The sum of all time (medians) taken to run the entire process, from issue creation to deploying the code to production. |
---
How this works, behind the scenes: How this works, behind the scenes:
1. Issues and merge requests are grouped together in pairs, such that for each 1. Issues and merge requests are grouped together in pairs, such that for each
...@@ -81,12 +91,12 @@ How this works, behind the scenes: ...@@ -81,12 +91,12 @@ How this works, behind the scenes:
we need for the stages, like issue creation date, merge request merge time, we need for the stages, like issue creation date, merge request merge time,
etc. etc.
To sum up, anything that doesn't follow [GitLab flow] will not be tracked and the To sum up, anything that doesn't follow [GitLab flow](../../workflow/gitlab_flow.md) will not be tracked and the
Cycle Analytics dashboard will not present any data for: Cycle Analytics dashboard will not present any data for:
- merge requests that do not close an issue. - Merge requests that do not close an issue.
- issues not labeled with a label present in the Issue Board or for issues not assigned a milestone. - Issues not labeled with a label present in the Issue Board or for issues not assigned a milestone.
- staging and production stages, if the project has no `production` or `production/*` - Staging and production stages, if the project has no `production` or `production/*`
environment. environment.
## Example workflow ## Example workflow
...@@ -107,7 +117,7 @@ environments is configured. ...@@ -107,7 +117,7 @@ environments is configured.
1. Push branch and create a merge request that contains the [issue closing pattern](../project/issues/managing_issues.md#closing-issues-automatically) 1. Push branch and create a merge request that contains the [issue closing pattern](../project/issues/managing_issues.md#closing-issues-automatically)
in its description at 14:00 (stop of **Code** stage / start of **Test** and in its description at 14:00 (stop of **Code** stage / start of **Test** and
**Review** stages). **Review** stages).
1. The CI starts running your scripts defined in [`.gitlab-ci.yml`][yml] and 1. The CI starts running your scripts defined in [`.gitlab-ci.yml`](../../ci/yaml/README.md) and
takes 5min (stop of **Test** stage). takes 5min (stop of **Test** stage).
1. Review merge request, ensure that everything is OK and merge the merge 1. Review merge request, ensure that everything is OK and merge the merge
request at 19:00. (stop of **Review** stage / start of **Staging** stage). request at 19:00. (stop of **Review** stage / start of **Staging** stage).
...@@ -151,7 +161,7 @@ The current permissions on the Project Cycle Analytics dashboard are: ...@@ -151,7 +161,7 @@ The current permissions on the Project Cycle Analytics dashboard are:
- Internal projects - any authenticated user can access. - Internal projects - any authenticated user can access.
- Private projects - any member Guest and above can access. - Private projects - any member Guest and above can access.
You can [read more about permissions][permissions] in general. You can [read more about permissions](../../ci/yaml/README.md) in general.
NOTE: **Note:** NOTE: **Note:**
As of GitLab 12.3, the project-level page is deprecated. You should access As of GitLab 12.3, the project-level page is deprecated. You should access
...@@ -169,14 +179,6 @@ For Cycle Analytics functionality introduced in GitLab 12.3 and later: ...@@ -169,14 +179,6 @@ For Cycle Analytics functionality introduced in GitLab 12.3 and later:
Learn more about Cycle Analytics in the following resources: Learn more about Cycle Analytics in the following resources:
- [Cycle Analytics feature page](https://about.gitlab.com/product/cycle-analytics/) - [Cycle Analytics feature page](https://about.gitlab.com/product/cycle-analytics/).
- [Cycle Analytics feature preview](https://about.gitlab.com/blog/2016/09/16/feature-preview-introducing-cycle-analytics/) - [Cycle Analytics feature preview](https://about.gitlab.com/blog/2016/09/16/feature-preview-introducing-cycle-analytics/).
- [Cycle Analytics feature highlight](https://about.gitlab.com/blog/2016/09/21/cycle-analytics-feature-highlight/) - [Cycle Analytics feature highlight](https://about.gitlab.com/blog/2016/09/21/cycle-analytics-feature-highlight/).
[ce-5986]: https://gitlab.com/gitlab-org/gitlab-foss/merge_requests/5986
[ce-20975]: https://gitlab.com/gitlab-org/gitlab-foss/issues/20975
[environment]: ../../ci/yaml/README.md#environment
[GitLab flow]: ../../topics/gitlab_flow.md
[idea to production]: https://about.gitlab.com/blog/2016/08/05/continuous-integration-delivery-and-deployment-with-gitlab/#from-idea-to-production-with-gitlab
[permissions]: ../permissions.md
[yml]: ../../ci/yaml/README.md
...@@ -42,10 +42,19 @@ The following metrics and visualizations are available on a project or group lev ...@@ -42,10 +42,19 @@ The following metrics and visualizations are available on a project or group lev
- Number of lines of code per commit. - Number of lines of code per commit.
- Number of files touched. - Number of files touched.
- Scatterplot showing all MRs merged on a certain date, together with the days it took to complete the action and a 30 day rolling median. - Scatterplot showing all MRs merged on a certain date, together with the days it took to complete the action and a 30 day rolling median.
- Users can zoom in and out on specific days of interest.
- Table showing the list of merge requests with their respective time duration metrics. - Table showing the list of merge requests with their respective time duration metrics.
- Users can sort by any of the above metrics. - Users can sort by any of the above metrics.
## Date ranges
> [Introduced](https://gitlab.com/gitlab-org/gitlab/issues/13188) in GitLab 12.4.
GitLab has the ability to filter analytics based on a date range. To filter results:
1. Select a group.
1. Optionally select a project.
1. Select a date range using the available date pickers.
## Permissions ## Permissions
The **Productivity Analytics** dashboard can be accessed only: The **Productivity Analytics** dashboard can be accessed only:
......
...@@ -352,7 +352,10 @@ bottom of the screen with two buttons: ...@@ -352,7 +352,10 @@ bottom of the screen with two buttons:
Clicking **Submit review** will publish all comments. Any quick actions Clicking **Submit review** will publish all comments. Any quick actions
submitted are performed at this time. submitted are performed at this time.
Alternatively, every pending comment has a button to finish the entire review. Alternatively, to finish the entire review from a pending comment:
- Click the **Finish review** button on the comment.
- Use the `/submit_review` [quick action](../project/quick_actions.md) in the text of the comment.
![Review submission](img/review_preview.png) ![Review submission](img/review_preview.png)
......
...@@ -25,25 +25,6 @@ The following identity providers are supported: ...@@ -25,25 +25,6 @@ The following identity providers are supported:
## Requirements ## Requirements
- [Group SSO](index.md) needs to be configured. - [Group SSO](index.md) needs to be configured.
- The `scim_group` feature flag must be enabled:
Run the following commands in a Rails console:
```sh
# Omnibus GitLab
gitlab-rails console
# Installation from source
cd /home/git/gitlab
sudo -u git -H bin/rails console RAILS_ENV=production
```
To enable SCIM for a group named `group_name`:
```ruby
group = Group.find_by_full_path('group_name')
Feature.enable(:group_scim, group)
```
## GitLab configuration ## GitLab configuration
......
...@@ -68,7 +68,8 @@ The following quick actions are applicable to descriptions, discussions and thre ...@@ -68,7 +68,8 @@ The following quick actions are applicable to descriptions, discussions and thre
| `/remove_zoom` | ✓ | | | Remove Zoom meeting from this issue. ([Introduced in GitLab 12.4](https://gitlab.com/gitlab-org/gitlab/merge_requests/16609)) | | `/remove_zoom` | ✓ | | | Remove Zoom meeting from this issue. ([Introduced in GitLab 12.4](https://gitlab.com/gitlab-org/gitlab/merge_requests/16609)) |
| `/target_branch <local branch name>` | | ✓ | | Set target branch | | `/target_branch <local branch name>` | | ✓ | | Set target branch |
| `/wip` | | ✓ | | Toggle the Work In Progress status | | `/wip` | | ✓ | | Toggle the Work In Progress status |
| `/approve` | | ✓ | | Approve the merge request | | `/approve` | | ✓ | | Approve the merge request **(STARTER)** |
| `/submit_review` | | ✓ | | Submit a pending review. ([Introduced in GitLab 12.5](https://gitlab.com/gitlab-org/gitlab/issues/8041)) **(PREMIUM)** |
| `/merge` | | ✓ | | Merge (when pipeline succeeds) | | `/merge` | | ✓ | | Merge (when pipeline succeeds) |
| `/child_epic <epic>` | | | ✓ | Add child epic to `<epic>`. The `<epic>` value should be in the format of `&epic`, `group&epic`, or a URL to an epic. ([Introduced in GitLab 12.0](https://gitlab.com/gitlab-org/gitlab/issues/7330)) **(ULTIMATE)** | | `/child_epic <epic>` | | | ✓ | Add child epic to `<epic>`. The `<epic>` value should be in the format of `&epic`, `group&epic`, or a URL to an epic. ([Introduced in GitLab 12.0](https://gitlab.com/gitlab-org/gitlab/issues/7330)) **(ULTIMATE)** |
| `/remove_child_epic <epic>` | | | ✓ | Remove child epic from `<epic>`. The `<epic>` value should be in the format of `&epic`, `group&epic`, or a URL to an epic. ([Introduced in GitLab 12.0](https://gitlab.com/gitlab-org/gitlab/issues/7330)) **(ULTIMATE)** | | `/remove_child_epic <epic>` | | | ✓ | Remove child epic from `<epic>`. The `<epic>` value should be in the format of `&epic`, `group&epic`, or a URL to an epic. ([Introduced in GitLab 12.0](https://gitlab.com/gitlab-org/gitlab/issues/7330)) **(ULTIMATE)** |
......
...@@ -28,25 +28,32 @@ if (isESLint) { ...@@ -28,25 +28,32 @@ if (isESLint) {
testMatch = testMatch.map(path => path.replace('_spec.js', '')); testMatch = testMatch.map(path => path.replace('_spec.js', ''));
} }
// eslint-disable-next-line import/no-commonjs const moduleNameMapper = {
module.exports = {
testMatch,
moduleFileExtensions: ['js', 'json', 'vue'],
moduleNameMapper: {
'^~(/.*)$': '<rootDir>/app/assets/javascripts$1', '^~(/.*)$': '<rootDir>/app/assets/javascripts$1',
'^ee(/.*)$': '<rootDir>/ee/app/assets/javascripts$1', '^ee_component(/.*)$':
'^ee_component(/.*)$': IS_EE '<rootDir>/app/assets/javascripts/vue_shared/components/empty_component.js',
? '<rootDir>/ee/app/assets/javascripts$1' '^ee_else_ce(/.*)$': '<rootDir>/app/assets/javascripts$1',
: '<rootDir>/app/assets/javascripts/vue_shared/components/empty_component.js',
'^ee_else_ce(/.*)$': IS_EE
? '<rootDir>/ee/app/assets/javascripts$1'
: '<rootDir>/app/assets/javascripts$1',
'^helpers(/.*)$': '<rootDir>/spec/frontend/helpers$1', '^helpers(/.*)$': '<rootDir>/spec/frontend/helpers$1',
'^vendor(/.*)$': '<rootDir>/vendor/assets/javascripts$1', '^vendor(/.*)$': '<rootDir>/vendor/assets/javascripts$1',
'\\.(jpg|jpeg|png|svg)$': '<rootDir>/spec/frontend/__mocks__/file_mock.js', '\\.(jpg|jpeg|png|svg)$': '<rootDir>/spec/frontend/__mocks__/file_mock.js',
'emojis(/.*).json': '<rootDir>/fixtures/emojis$1.json', 'emojis(/.*).json': '<rootDir>/fixtures/emojis$1.json',
'^spec/test_constants$': '<rootDir>/spec/frontend/helpers/test_constants', '^spec/test_constants$': '<rootDir>/spec/frontend/helpers/test_constants',
}, };
if (IS_EE) {
const rootDirEE = '<rootDir>/ee/app/assets/javascripts$1';
Object.assign(moduleNameMapper, {
'^ee(/.*)$': rootDirEE,
'^ee_component(/.*)$': rootDirEE,
'^ee_else_ce(/.*)$': rootDirEE,
});
}
// eslint-disable-next-line import/no-commonjs
module.exports = {
testMatch,
moduleFileExtensions: ['js', 'json', 'vue'],
moduleNameMapper,
collectCoverageFrom: ['<rootDir>/app/assets/javascripts/**/*.{js,vue}'], collectCoverageFrom: ['<rootDir>/app/assets/javascripts/**/*.{js,vue}'],
coverageDirectory: '<rootDir>/coverage-frontend/', coverageDirectory: '<rootDir>/coverage-frontend/',
coverageReporters: ['json', 'lcov', 'text-summary', 'clover'], coverageReporters: ['json', 'lcov', 'text-summary', 'clover'],
......
...@@ -16,7 +16,9 @@ module Gitlab ...@@ -16,7 +16,9 @@ module Gitlab
stale_schedule: 'stale schedule', stale_schedule: 'stale schedule',
job_execution_timeout: 'job execution timeout', job_execution_timeout: 'job execution timeout',
archived_failure: 'archived failure', archived_failure: 'archived failure',
unmet_prerequisites: 'unmet prerequisites' unmet_prerequisites: 'unmet prerequisites',
scheduler_failure: 'scheduler failure',
data_integrity_failure: 'data integrity failure'
}.freeze }.freeze
private_constant :REASONS private_constant :REASONS
......
...@@ -58,11 +58,16 @@ module Gitlab ...@@ -58,11 +58,16 @@ module Gitlab
# wrong answer. We handle that by querying the full list - which fills # wrong answer. We handle that by querying the full list - which fills
# the cache - and using it directly to answer the question. # the cache - and using it directly to answer the question.
define_method("#{name}_include?") do |value| define_method("#{name}_include?") do |value|
if strong_memoized?(name) || !redis_set_cache.exist?(name) return __send__(name).include?(value) if strong_memoized?(name) # rubocop:disable GitlabSecurity/PublicSend
return __send__(name).include?(value) # rubocop:disable GitlabSecurity/PublicSend
end # If the member exists in the set, return as such early.
return true if redis_set_cache.include?(name, value)
# If it did not, make sure the collection exists.
# If the collection exists, then item does not.
return false if redis_set_cache.exist?(name)
redis_set_cache.include?(name, value) __send__(name).include?(value) # rubocop:disable GitlabSecurity/PublicSend
end end
end end
......
...@@ -25,7 +25,7 @@ module Gitlab ...@@ -25,7 +25,7 @@ module Gitlab
end end
def read(key) def read(key)
with { |redis| redis.smembers(cache_key(key)) } with { |redis| redis.sscan_each(cache_key(key)).to_a }
end end
def write(key, value) def write(key, value)
...@@ -47,12 +47,11 @@ module Gitlab ...@@ -47,12 +47,11 @@ module Gitlab
end end
def fetch(key, &block) def fetch(key, &block)
if exist?(key) result = read(key)
read(key) return result unless result.empty?
else
write(key, yield) write(key, yield)
end end
end
def include?(key, value) def include?(key, value)
with { |redis| redis.sismember(cache_key(key), value) } with { |redis| redis.sismember(cache_key(key), value) }
......
...@@ -9814,11 +9814,21 @@ msgid_plural "LicenseCompliance|License Compliance detected %d licenses for the ...@@ -9814,11 +9814,21 @@ msgid_plural "LicenseCompliance|License Compliance detected %d licenses for the
msgstr[0] "" msgstr[0] ""
msgstr[1] "" msgstr[1] ""
msgid "LicenseCompliance|License Compliance detected %d license for the source branch only; approval required"
msgid_plural "LicenseCompliance|License Compliance detected %d licenses for the source branch only; approval required"
msgstr[0] ""
msgstr[1] ""
msgid "LicenseCompliance|License Compliance detected %d new license" msgid "LicenseCompliance|License Compliance detected %d new license"
msgid_plural "LicenseCompliance|License Compliance detected %d new licenses" msgid_plural "LicenseCompliance|License Compliance detected %d new licenses"
msgstr[0] "" msgstr[0] ""
msgstr[1] "" msgstr[1] ""
msgid "LicenseCompliance|License Compliance detected %d new license; approval required"
msgid_plural "LicenseCompliance|License Compliance detected %d new licenses; approval required"
msgstr[0] ""
msgstr[1] ""
msgid "LicenseCompliance|License Compliance detected no licenses for the source branch only" msgid "LicenseCompliance|License Compliance detected no licenses for the source branch only"
msgstr "" msgstr ""
...@@ -15967,6 +15977,9 @@ msgstr "" ...@@ -15967,6 +15977,9 @@ msgstr ""
msgid "Subkeys" msgid "Subkeys"
msgstr "" msgstr ""
msgid "Submit a review"
msgstr ""
msgid "Submit as spam" msgid "Submit as spam"
msgstr "" msgstr ""
...@@ -15982,6 +15995,12 @@ msgstr "" ...@@ -15982,6 +15995,12 @@ msgstr ""
msgid "Submit search" msgid "Submit search"
msgstr "" msgstr ""
msgid "Submit the current review."
msgstr ""
msgid "Submitted the current review."
msgstr ""
msgid "Subscribe" msgid "Subscribe"
msgstr "" msgstr ""
...@@ -18792,6 +18811,9 @@ msgstr "" ...@@ -18792,6 +18811,9 @@ msgstr ""
msgid "Welcome to GitLab" msgid "Welcome to GitLab"
msgstr "" msgstr ""
msgid "Welcome to GitLab %{username}!"
msgstr ""
msgid "Welcome to the Guided GitLab Tour" msgid "Welcome to the Guided GitLab Tour"
msgstr "" msgstr ""
......
...@@ -14,11 +14,11 @@ gitlab: ...@@ -14,11 +14,11 @@ gitlab:
gitaly: gitaly:
resources: resources:
requests: requests:
cpu: 600m
memory: 200M
limits:
cpu: 1200m cpu: 1200m
memory: 420M memory: 240M
limits:
cpu: 1800m
memory: 360M
persistence: persistence:
size: 10G size: 10G
gitlab-exporter: gitlab-exporter:
...@@ -35,22 +35,22 @@ gitlab: ...@@ -35,22 +35,22 @@ gitlab:
gitlab-shell: gitlab-shell:
resources: resources:
requests: requests:
cpu: 125m cpu: 230m
memory: 20M memory: 25M
limits: limits:
cpu: 250m cpu: 345m
memory: 40M memory: 37.5M
maxReplicas: 3 maxReplicas: 3
hpa: hpa:
targetAverageValue: 130m targetAverageValue: 130m
sidekiq: sidekiq:
resources: resources:
requests: requests:
cpu: 500m cpu: 650m
memory: 800M memory: 880M
limits: limits:
cpu: 1000m cpu: 975m
memory: 1.6G memory: 1320M
task-runner: task-runner:
resources: resources:
requests: requests:
...@@ -62,11 +62,11 @@ gitlab: ...@@ -62,11 +62,11 @@ gitlab:
unicorn: unicorn:
resources: resources:
requests: requests:
cpu: 400m cpu: 500m
memory: 1.4G memory: 1540M
limits: limits:
cpu: 800m cpu: 750m
memory: 2.8G memory: 2310M
deployment: deployment:
readinessProbe: readinessProbe:
initialDelaySeconds: 5 # Default is 0 initialDelaySeconds: 5 # Default is 0
...@@ -75,11 +75,11 @@ gitlab: ...@@ -75,11 +75,11 @@ gitlab:
workhorse: workhorse:
resources: resources:
requests: requests:
cpu: 300m cpu: 250m
memory: 100M memory: 50M
limits: limits:
cpu: 600m cpu: 375m
memory: 200M memory: 75M
readinessProbe: readinessProbe:
initialDelaySeconds: 5 # Default is 0 initialDelaySeconds: 5 # Default is 0
periodSeconds: 15 # Default is 10 periodSeconds: 15 # Default is 10
...@@ -87,11 +87,11 @@ gitlab: ...@@ -87,11 +87,11 @@ gitlab:
gitlab-runner: gitlab-runner:
resources: resources:
requests: requests:
cpu: 355m cpu: 450m
memory: 300M memory: 100M
limits: limits:
cpu: 710m cpu: 675m
memory: 600M memory: 150M
minio: minio:
resources: resources:
requests: requests:
...@@ -108,10 +108,10 @@ nginx-ingress: ...@@ -108,10 +108,10 @@ nginx-ingress:
resources: resources:
requests: requests:
cpu: 100m cpu: 100m
memory: 250M memory: 450M
limits: limits:
cpu: 200m cpu: 200m
memory: 500M memory: 675M
minAvailable: 1 minAvailable: 1
service: service:
enableHttp: false enableHttp: false
...@@ -133,10 +133,11 @@ postgresql: ...@@ -133,10 +133,11 @@ postgresql:
enabled: false enabled: false
resources: resources:
requests: requests:
cpu: 250m cpu: 300m
memory: 256M memory: 250M
limits: limits:
cpu: 500m cpu: 450m
memory: 375M
prometheus: prometheus:
install: false install: false
redis: redis:
...@@ -157,8 +158,8 @@ registry: ...@@ -157,8 +158,8 @@ registry:
minReplicas: 1 minReplicas: 1
resources: resources:
requests: requests:
cpu: 50m
memory: 32M
limits:
cpu: 100m cpu: 100m
memory: 64M memory: 30M
limits:
cpu: 200m
memory: 45M
...@@ -56,8 +56,8 @@ describe Projects::ReleasesController do ...@@ -56,8 +56,8 @@ describe Projects::ReleasesController do
context 'when the project is private and the user is not logged in' do context 'when the project is private and the user is not logged in' do
let(:project) { private_project } let(:project) { private_project }
it 'renders a 302' do it 'returns a redirect' do
expect(response.status).to eq(302) expect(response).to have_gitlab_http_status(:redirect)
end end
end end
end end
...@@ -78,8 +78,8 @@ describe Projects::ReleasesController do ...@@ -78,8 +78,8 @@ describe Projects::ReleasesController do
context 'when the project is private and the user is not logged in' do context 'when the project is private and the user is not logged in' do
let(:project) { private_project } let(:project) { private_project }
it 'renders a 401' do it 'returns a redirect' do
expect(response.status).to eq(401) expect(response).to have_gitlab_http_status(:redirect)
end end
end end
end end
......
import Vue from 'vue'; import Vue from 'vue';
import { formatDate } from '~/lib/utils/datetime_utility'; import { formatDate } from '~/lib/utils/datetime_utility';
import { mount, createLocalVue } from '@vue/test-utils'; import { mount, createLocalVue } from '@vue/test-utils';
import { PathIdSeparator } from 'ee/related_issues/constants';
import RelatedIssuableItem from '~/vue_shared/components/issue/related_issuable_item.vue'; import RelatedIssuableItem from '~/vue_shared/components/issue/related_issuable_item.vue';
import { import {
defaultAssignees, defaultAssignees,
...@@ -13,7 +12,7 @@ describe('RelatedIssuableItem', () => { ...@@ -13,7 +12,7 @@ describe('RelatedIssuableItem', () => {
const props = { const props = {
idKey: 1, idKey: 1,
displayReference: 'gitlab-org/gitlab-test#1', displayReference: 'gitlab-org/gitlab-test#1',
pathIdSeparator: PathIdSeparator.Issue, pathIdSeparator: '#',
path: `${gl.TEST_HOST}/path`, path: `${gl.TEST_HOST}/path`,
title: 'title', title: 'title',
confidential: true, confidential: true,
......
...@@ -19,19 +19,23 @@ describe SyncIssuablesStateId, :migration, :sidekiq do ...@@ -19,19 +19,23 @@ describe SyncIssuablesStateId, :migration, :sidekiq do
it 'migrates state column to state_id as integer' do it 'migrates state column to state_id as integer' do
opened_issue = issues.create!(description: 'first', state: 'opened') opened_issue = issues.create!(description: 'first', state: 'opened')
closed_issue = issues.create!(description: 'second', state: 'closed') closed_issue = issues.create!(description: 'second', state: 'closed')
unknown_state_issue = issues.create!(description: 'second', state: 'unknown')
opened_merge_request = merge_requests.create!(state: 'opened', target_project_id: project.id, target_branch: 'feature1', source_branch: 'master') opened_merge_request = merge_requests.create!(state: 'opened', target_project_id: project.id, target_branch: 'feature1', source_branch: 'master')
closed_merge_request = merge_requests.create!(state: 'closed', target_project_id: project.id, target_branch: 'feature2', source_branch: 'master') closed_merge_request = merge_requests.create!(state: 'closed', target_project_id: project.id, target_branch: 'feature2', source_branch: 'master')
merged_merge_request = merge_requests.create!(state: 'merged', target_project_id: project.id, target_branch: 'feature3', source_branch: 'master') merged_merge_request = merge_requests.create!(state: 'merged', target_project_id: project.id, target_branch: 'feature3', source_branch: 'master')
locked_merge_request = merge_requests.create!(state: 'locked', target_project_id: project.id, target_branch: 'feature4', source_branch: 'master') locked_merge_request = merge_requests.create!(state: 'locked', target_project_id: project.id, target_branch: 'feature4', source_branch: 'master')
unknown_state_merge_request = merge_requests.create!(state: 'unknown', target_project_id: project.id, target_branch: 'feature4', source_branch: 'master')
migrate! migrate!
expect(opened_issue.reload.state_id).to eq(state_ids[:opened]) expect(opened_issue.reload.state_id).to eq(state_ids[:opened])
expect(closed_issue.reload.state_id).to eq(state_ids[:closed]) expect(closed_issue.reload.state_id).to eq(state_ids[:closed])
expect(unknown_state_issue.reload.state_id).to eq(state_ids[:closed])
expect(opened_merge_request.reload.state_id).to eq(state_ids[:opened]) expect(opened_merge_request.reload.state_id).to eq(state_ids[:opened])
expect(closed_merge_request.reload.state_id).to eq(state_ids[:closed]) expect(closed_merge_request.reload.state_id).to eq(state_ids[:closed])
expect(merged_merge_request.reload.state_id).to eq(state_ids[:merged]) expect(merged_merge_request.reload.state_id).to eq(state_ids[:merged])
expect(locked_merge_request.reload.state_id).to eq(state_ids[:locked]) expect(locked_merge_request.reload.state_id).to eq(state_ids[:locked])
expect(unknown_state_merge_request.reload.state_id).to eq(state_ids[:closed])
end end
end end
end end
...@@ -1587,7 +1587,7 @@ describe Ci::Build do ...@@ -1587,7 +1587,7 @@ describe Ci::Build do
end end
end end
describe '#retries_max' do describe '#options_retry_max' do
context 'with retries max config option' do context 'with retries max config option' do
subject { create(:ci_build, options: { retry: { max: 1 } }) } subject { create(:ci_build, options: { retry: { max: 1 } }) }
...@@ -1597,7 +1597,7 @@ describe Ci::Build do ...@@ -1597,7 +1597,7 @@ describe Ci::Build do
end end
it 'returns the number of configured max retries' do it 'returns the number of configured max retries' do
expect(subject.retries_max).to eq 1 expect(subject.options_retry_max).to eq 1
end end
end end
...@@ -1607,7 +1607,7 @@ describe Ci::Build do ...@@ -1607,7 +1607,7 @@ describe Ci::Build do
end end
it 'returns the number of configured max retries' do it 'returns the number of configured max retries' do
expect(subject.retries_max).to eq 1 expect(subject.options_retry_max).to eq 1
end end
end end
end end
...@@ -1615,16 +1615,16 @@ describe Ci::Build do ...@@ -1615,16 +1615,16 @@ describe Ci::Build do
context 'without retries max config option' do context 'without retries max config option' do
subject { create(:ci_build) } subject { create(:ci_build) }
it 'returns zero' do it 'returns nil' do
expect(subject.retries_max).to eq 0 expect(subject.options_retry_max).to be_nil
end end
end end
context 'when build is degenerated' do context 'when build is degenerated' do
subject { create(:ci_build, :degenerated) } subject { create(:ci_build, :degenerated) }
it 'returns zero' do it 'returns nil' do
expect(subject.retries_max).to eq 0 expect(subject.options_retry_max).to be_nil
end end
end end
...@@ -1632,17 +1632,17 @@ describe Ci::Build do ...@@ -1632,17 +1632,17 @@ describe Ci::Build do
subject { create(:ci_build, options: { retry: 1 }) } subject { create(:ci_build, options: { retry: 1 }) }
it 'returns the number of configured max retries' do it 'returns the number of configured max retries' do
expect(subject.retries_max).to eq 1 expect(subject.options_retry_max).to eq 1
end end
end end
end end
describe '#retry_when' do describe '#options_retry_when' do
context 'with retries when config option' do context 'with retries when config option' do
subject { create(:ci_build, options: { retry: { when: ['some_reason'] } }) } subject { create(:ci_build, options: { retry: { when: ['some_reason'] } }) }
it 'returns the configured when' do it 'returns the configured when' do
expect(subject.retry_when).to eq ['some_reason'] expect(subject.options_retry_when).to eq ['some_reason']
end end
end end
...@@ -1650,7 +1650,7 @@ describe Ci::Build do ...@@ -1650,7 +1650,7 @@ describe Ci::Build do
subject { create(:ci_build) } subject { create(:ci_build) }
it 'returns always array' do it 'returns always array' do
expect(subject.retry_when).to eq ['always'] expect(subject.options_retry_when).to eq ['always']
end end
end end
...@@ -1658,72 +1658,38 @@ describe Ci::Build do ...@@ -1658,72 +1658,38 @@ describe Ci::Build do
subject { create(:ci_build, options: { retry: 1 }) } subject { create(:ci_build, options: { retry: 1 }) }
it 'returns always array' do it 'returns always array' do
expect(subject.retry_when).to eq ['always'] expect(subject.options_retry_when).to eq ['always']
end end
end end
end end
describe '#retry_failure?' do describe '#retry_failure?' do
subject { create(:ci_build) } using RSpec::Parameterized::TableSyntax
context 'when retries max is zero' do
before do
expect(subject).to receive(:retries_max).at_least(:once).and_return(0)
end
it 'returns false' do
expect(subject.retry_failure?).to eq false
end
end
context 'when retries max equals retries count' do
before do
expect(subject).to receive(:retries_max).at_least(:once).and_return(1)
expect(subject).to receive(:retries_count).at_least(:once).and_return(1)
end
it 'returns false' do
expect(subject.retry_failure?).to eq false
end
end
context 'when retries max is higher than retries count' do let(:build) { create(:ci_build) }
before do
expect(subject).to receive(:retries_max).at_least(:once).and_return(2)
expect(subject).to receive(:retries_count).at_least(:once).and_return(1)
end
context 'and retry when is always' do subject { build.retry_failure? }
before do
expect(subject).to receive(:retry_when).at_least(:once).and_return(['always'])
end
it 'returns true' do where(:description, :retry_count, :options, :failure_reason, :result) do
expect(subject.retry_failure?).to eq true "retries are disabled" | 0 | { max: 0 } | nil | false
end "max equals count" | 2 | { max: 2 } | nil | false
"max is higher than count" | 1 | { max: 2 } | nil | true
"matching failure reason" | 0 | { when: %w[api_failure], max: 2 } | :api_failure | true
"not matching with always" | 0 | { when: %w[always], max: 2 } | :api_failure | true
"not matching reason" | 0 | { when: %w[script_error], max: 2 } | :api_failure | false
"scheduler failure override" | 1 | { when: %w[scheduler_failure], max: 1 } | :scheduler_failure | false
"default for scheduler failure" | 1 | {} | :scheduler_failure | true
end end
context 'and retry when includes the failure_reason' do with_them do
before do before do
expect(subject).to receive(:failure_reason).at_least(:once).and_return('some_reason') allow(build).to receive(:retries_count) { retry_count }
expect(subject).to receive(:retry_when).at_least(:once).and_return(['some_reason'])
end
it 'returns true' do build.options[:retry] = options
expect(subject.retry_failure?).to eq true build.failure_reason = failure_reason
end
end end
context 'and retry when does not include failure_reason' do it { is_expected.to eq(result) }
before do
expect(subject).to receive(:failure_reason).at_least(:once).and_return('some_reason')
expect(subject).to receive(:retry_when).at_least(:once).and_return(['some', 'other failure'])
end
it 'returns false' do
expect(subject.retry_failure?).to eq false
end
end
end end
end end
end end
......
...@@ -269,7 +269,7 @@ describe Ci::BuildPresenter do ...@@ -269,7 +269,7 @@ describe Ci::BuildPresenter do
let(:build) { create(:ci_build, :failed, :script_failure) } let(:build) { create(:ci_build, :failed, :script_failure) }
context 'when is a script or missing dependency failure' do context 'when is a script or missing dependency failure' do
let(:failure_reasons) { %w(script_failure missing_dependency_failure archived_failure) } let(:failure_reasons) { %w(script_failure missing_dependency_failure archived_failure scheduler_failure data_integrity_failure) }
it 'returns false' do it 'returns false' do
failure_reasons.each do |failure_reason| failure_reasons.each do |failure_reason|
......
...@@ -773,8 +773,8 @@ describe Ci::CreatePipelineService do ...@@ -773,8 +773,8 @@ describe Ci::CreatePipelineService do
it 'correctly creates builds with auto-retry value configured' do it 'correctly creates builds with auto-retry value configured' do
expect(pipeline).to be_persisted expect(pipeline).to be_persisted
expect(rspec_job.retries_max).to eq 2 expect(rspec_job.options_retry_max).to eq 2
expect(rspec_job.retry_when).to eq ['always'] expect(rspec_job.options_retry_when).to eq ['always']
end end
end end
...@@ -783,8 +783,8 @@ describe Ci::CreatePipelineService do ...@@ -783,8 +783,8 @@ describe Ci::CreatePipelineService do
it 'correctly creates builds with auto-retry value configured' do it 'correctly creates builds with auto-retry value configured' do
expect(pipeline).to be_persisted expect(pipeline).to be_persisted
expect(rspec_job.retries_max).to eq 2 expect(rspec_job.options_retry_max).to eq 2
expect(rspec_job.retry_when).to eq ['runner_system_failure'] expect(rspec_job.options_retry_when).to eq ['runner_system_failure']
end end
end end
end end
......
...@@ -502,6 +502,57 @@ module Ci ...@@ -502,6 +502,57 @@ module Ci
end end
end end
context 'when build has data integrity problem' do
let!(:pending_job) do
create(:ci_build, :pending, pipeline: pipeline)
end
before do
pending_job.update_columns(options: "string")
end
subject { execute(specific_runner, {}) }
it 'does drop the build and logs both failures' do
expect(Gitlab::Sentry).to receive(:track_acceptable_exception)
.with(anything, a_hash_including(extra: a_hash_including(build_id: pending_job.id)))
.twice
.and_call_original
expect(subject).to be_nil
pending_job.reload
expect(pending_job).to be_failed
expect(pending_job).to be_data_integrity_failure
end
end
context 'when build fails to be run!' do
let!(:pending_job) do
create(:ci_build, :pending, pipeline: pipeline)
end
before do
expect_any_instance_of(Ci::Build).to receive(:run!)
.and_raise(RuntimeError, 'scheduler error')
end
subject { execute(specific_runner, {}) }
it 'does drop the build and logs failure' do
expect(Gitlab::Sentry).to receive(:track_acceptable_exception)
.with(anything, a_hash_including(extra: a_hash_including(build_id: pending_job.id)))
.once
.and_call_original
expect(subject).to be_nil
pending_job.reload
expect(pending_job).to be_failed
expect(pending_job).to be_scheduler_failure
end
end
context 'when an exception is raised during a persistent ref creation' do context 'when an exception is raised during a persistent ref creation' do
before do before do
allow_any_instance_of(Ci::PersistentRef).to receive(:exist?) { false } allow_any_instance_of(Ci::PersistentRef).to receive(:exist?) { false }
......
# frozen_string_literal: true
require 'spec_helper' require 'spec_helper'
describe MergeRequests::AssignsMergeParams do describe MergeRequests::AssignsMergeParams do
......
File mode changed from 100755 to 100644
File mode changed from 100755 to 100644
...@@ -990,15 +990,15 @@ ...@@ -990,15 +990,15 @@
dependencies: dependencies:
vue-eslint-parser "^6.0.4" vue-eslint-parser "^6.0.4"
"@gitlab/svgs@^1.79.0": "@gitlab/svgs@^1.80.0":
version "1.79.0" version "1.80.0"
resolved "https://registry.yarnpkg.com/@gitlab/svgs/-/svgs-1.79.0.tgz#7e79666118d6adc0247bdb3b3b6b2b299aa5a439" resolved "https://registry.yarnpkg.com/@gitlab/svgs/-/svgs-1.80.0.tgz#52b2d25f002cdfe9bd7c366a043c1849687ad64b"
integrity sha512-0pTUviQqwyaKBOB6OL7Mmr2dQn/dGB03XslBMtL9lFZz1baB7d6xf+zxFU0GBAJUJan397IbBddE1jjUAQT8Fw== integrity sha512-hsyX3EZV/hk9bMTvvoxVcNC0EO6sy771BC2vXjqGtzjye4hTs0BTAzu3V0UPWuDompHtKXi/plVcJU+NxNLQ6Q==
"@gitlab/ui@7.0.0": "@gitlab/ui@7.3.0":
version "7.0.0" version "7.3.0"
resolved "https://registry.yarnpkg.com/@gitlab/ui/-/ui-7.0.0.tgz#74ca106856a47e7793df0b7448cbf2903634709c" resolved "https://registry.yarnpkg.com/@gitlab/ui/-/ui-7.3.0.tgz#9ed6d2144cb999c12675b309ecda3279c4b88bf6"
integrity sha512-uiRV2VuGpWcCpj+d4M6VA8ItyLkTxfzGnaNbyX8UcswInAKjMMDO7KspF9DWlFDJVH5qzDguOSgons9NQJy53g== integrity sha512-QMn84x7DrjDOCKD1/Exh26wwkAvdAjlIWjafvISTHZ+PAWY6XxEAYyjllM5k0fQpNZP3sw7sBWWYvezDVdLnmw==
dependencies: dependencies:
"@babel/standalone" "^7.0.0" "@babel/standalone" "^7.0.0"
"@gitlab/vue-toasted" "^1.2.1" "@gitlab/vue-toasted" "^1.2.1"
...@@ -1531,6 +1531,13 @@ ...@@ -1531,6 +1531,13 @@
"@webassemblyjs/wast-parser" "1.8.5" "@webassemblyjs/wast-parser" "1.8.5"
"@xtuc/long" "4.2.2" "@xtuc/long" "4.2.2"
"@wry/equality@^0.1.2":
version "0.1.9"
resolved "https://registry.yarnpkg.com/@wry/equality/-/equality-0.1.9.tgz#b13e18b7a8053c6858aa6c85b54911fb31e3a909"
integrity sha512-mB6ceGjpMGz1ZTza8HYnrPGos2mC6So4NhS1PtZ8s4Qt0K7fBiIGhpSxUbQmhwcSWE3no+bYxmI2OL6KuXYmoQ==
dependencies:
tslib "^1.9.3"
"@xtuc/ieee754@^1.2.0": "@xtuc/ieee754@^1.2.0":
version "1.2.0" version "1.2.0"
resolved "https://registry.yarnpkg.com/@xtuc/ieee754/-/ieee754-1.2.0.tgz#eef014a3145ae477a1cbc00cd1e552336dceb790" resolved "https://registry.yarnpkg.com/@xtuc/ieee754/-/ieee754-1.2.0.tgz#eef014a3145ae477a1cbc00cd1e552336dceb790"
...@@ -1706,26 +1713,25 @@ apollo-cache-inmemory@^1.5.1: ...@@ -1706,26 +1713,25 @@ apollo-cache-inmemory@^1.5.1:
ts-invariant "^0.2.1" ts-invariant "^0.2.1"
tslib "^1.9.3" tslib "^1.9.3"
apollo-cache@1.2.1, apollo-cache@^1.2.1: apollo-cache@1.3.2, apollo-cache@^1.2.1:
version "1.2.1" version "1.3.2"
resolved "https://registry.yarnpkg.com/apollo-cache/-/apollo-cache-1.2.1.tgz#aae71eb4a11f1f7322adc343f84b1a39b0693644" resolved "https://registry.yarnpkg.com/apollo-cache/-/apollo-cache-1.3.2.tgz#df4dce56240d6c95c613510d7e409f7214e6d26a"
integrity sha512-nzFmep/oKlbzUuDyz6fS6aYhRmfpcHWqNkkA9Bbxwk18RD6LXC4eZkuE0gXRX0IibVBHNjYVK+Szi0Yied4SpQ== integrity sha512-+KA685AV5ETEJfjZuviRTEImGA11uNBp/MJGnaCvkgr+BYRrGLruVKBv6WvyFod27WEB2sp7SsG8cNBKANhGLg==
dependencies: dependencies:
apollo-utilities "^1.2.1" apollo-utilities "^1.3.2"
tslib "^1.9.3" tslib "^1.9.3"
apollo-client@^2.5.1: apollo-client@^2.6.4:
version "2.5.1" version "2.6.4"
resolved "https://registry.yarnpkg.com/apollo-client/-/apollo-client-2.5.1.tgz#36126ed1d32edd79c3713c6684546a3bea80e6d1" resolved "https://registry.yarnpkg.com/apollo-client/-/apollo-client-2.6.4.tgz#872c32927263a0d34655c5ef8a8949fbb20b6140"
integrity sha512-MNcQKiqLHdGmNJ0rZ0NXaHrToXapJgS/5kPk0FygXt+/FmDCdzqcujI7OPxEC6e9Yw5S/8dIvOXcRNuOMElHkA== integrity sha512-oWOwEOxQ9neHHVZrQhHDbI6bIibp9SHgxaLRVPoGvOFy7OH5XUykZE7hBQAVxq99tQjBzgytaZffQkeWo1B4VQ==
dependencies: dependencies:
"@types/zen-observable" "^0.8.0" "@types/zen-observable" "^0.8.0"
apollo-cache "1.2.1" apollo-cache "1.3.2"
apollo-link "^1.0.0" apollo-link "^1.0.0"
apollo-link-dedup "^1.0.0" apollo-utilities "1.3.2"
apollo-utilities "1.2.1"
symbol-observable "^1.0.2" symbol-observable "^1.0.2"
ts-invariant "^0.2.1" ts-invariant "^0.4.0"
tslib "^1.9.3" tslib "^1.9.3"
zen-observable "^0.8.0" zen-observable "^0.8.0"
...@@ -1747,13 +1753,6 @@ apollo-link-batch@^1.1.12: ...@@ -1747,13 +1753,6 @@ apollo-link-batch@^1.1.12:
apollo-link "^1.2.11" apollo-link "^1.2.11"
tslib "^1.9.3" tslib "^1.9.3"
apollo-link-dedup@^1.0.0:
version "1.0.10"
resolved "https://registry.yarnpkg.com/apollo-link-dedup/-/apollo-link-dedup-1.0.10.tgz#7b94589fe7f969777efd18a129043c78430800ae"
integrity sha512-tpUI9lMZsidxdNygSY1FxflXEkUZnvKRkMUsXXuQUNoSLeNtEvUX7QtKRAl4k9ubLl8JKKc9X3L3onAFeGTK8w==
dependencies:
apollo-link "^1.2.3"
apollo-link-http-common@^0.2.13, apollo-link-http-common@^0.2.8: apollo-link-http-common@^0.2.13, apollo-link-http-common@^0.2.8:
version "0.2.13" version "0.2.13"
resolved "https://registry.yarnpkg.com/apollo-link-http-common/-/apollo-link-http-common-0.2.13.tgz#c688f6baaffdc7b269b2db7ae89dae7c58b5b350" resolved "https://registry.yarnpkg.com/apollo-link-http-common/-/apollo-link-http-common-0.2.13.tgz#c688f6baaffdc7b269b2db7ae89dae7c58b5b350"
...@@ -1763,7 +1762,7 @@ apollo-link-http-common@^0.2.13, apollo-link-http-common@^0.2.8: ...@@ -1763,7 +1762,7 @@ apollo-link-http-common@^0.2.13, apollo-link-http-common@^0.2.8:
ts-invariant "^0.3.2" ts-invariant "^0.3.2"
tslib "^1.9.3" tslib "^1.9.3"
apollo-link@^1.0.0, apollo-link@^1.2.11, apollo-link@^1.2.3, apollo-link@^1.2.6: apollo-link@^1.0.0, apollo-link@^1.2.11, apollo-link@^1.2.6:
version "1.2.11" version "1.2.11"
resolved "https://registry.yarnpkg.com/apollo-link/-/apollo-link-1.2.11.tgz#493293b747ad3237114ccd22e9f559e5e24a194d" resolved "https://registry.yarnpkg.com/apollo-link/-/apollo-link-1.2.11.tgz#493293b747ad3237114ccd22e9f559e5e24a194d"
integrity sha512-PQvRCg13VduLy3X/0L79M6uOpTh5iHdxnxYuo8yL7sJlWybKRJwsv4IcRBJpMFbChOOaHY7Og9wgPo6DLKDKDA== integrity sha512-PQvRCg13VduLy3X/0L79M6uOpTh5iHdxnxYuo8yL7sJlWybKRJwsv4IcRBJpMFbChOOaHY7Og9wgPo6DLKDKDA==
...@@ -1782,13 +1781,14 @@ apollo-upload-client@^10.0.0: ...@@ -1782,13 +1781,14 @@ apollo-upload-client@^10.0.0:
apollo-link-http-common "^0.2.8" apollo-link-http-common "^0.2.8"
extract-files "^5.0.0" extract-files "^5.0.0"
apollo-utilities@1.2.1, apollo-utilities@^1.2.1: apollo-utilities@1.3.2, apollo-utilities@^1.2.1, apollo-utilities@^1.3.2:
version "1.2.1" version "1.3.2"
resolved "https://registry.yarnpkg.com/apollo-utilities/-/apollo-utilities-1.2.1.tgz#1c3a1ebf5607d7c8efe7636daaf58e7463b41b3c" resolved "https://registry.yarnpkg.com/apollo-utilities/-/apollo-utilities-1.3.2.tgz#8cbdcf8b012f664cd6cb5767f6130f5aed9115c9"
integrity sha512-Zv8Udp9XTSFiN8oyXOjf6PMHepD4yxxReLsl6dPUy5Ths7jti3nmlBzZUOxuTWRwZn0MoclqL7RQ5UEJN8MAxg== integrity sha512-JWNHj8XChz7S4OZghV6yc9FNnzEXj285QYp/nLNh943iObycI5GTDO3NGR9Dth12LRrSFMeDOConPfPln+WGfg==
dependencies: dependencies:
"@wry/equality" "^0.1.2"
fast-json-stable-stringify "^2.0.0" fast-json-stable-stringify "^2.0.0"
ts-invariant "^0.2.1" ts-invariant "^0.4.0"
tslib "^1.9.3" tslib "^1.9.3"
append-buffer@^1.0.2: append-buffer@^1.0.2:
...@@ -12051,6 +12051,13 @@ ts-invariant@^0.3.2: ...@@ -12051,6 +12051,13 @@ ts-invariant@^0.3.2:
dependencies: dependencies:
tslib "^1.9.3" tslib "^1.9.3"
ts-invariant@^0.4.0:
version "0.4.4"
resolved "https://registry.yarnpkg.com/ts-invariant/-/ts-invariant-0.4.4.tgz#97a523518688f93aafad01b0e80eb803eb2abd86"
integrity sha512-uEtWkFM/sdZvRNNDL3Ehu4WVpwaulhwQszV8mrtcdeE8nN00BV9mAmQ88RkrBhFgl9gMgvjJLAQcZbnPXI9mlA==
dependencies:
tslib "^1.9.3"
ts-jest@24.0.0, ts-jest@^23.10.5: ts-jest@24.0.0, ts-jest@^23.10.5:
version "24.0.0" version "24.0.0"
resolved "https://registry.yarnpkg.com/ts-jest/-/ts-jest-24.0.0.tgz#3f26bf2ec1fa584863a5a9c29bd8717d549efbf6" resolved "https://registry.yarnpkg.com/ts-jest/-/ts-jest-24.0.0.tgz#3f26bf2ec1fa584863a5a9c29bd8717d549efbf6"
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment