From ffe7c069a4e16f77b80c7159690a4c8060dd74d9 Mon Sep 17 00:00:00 2001 From: GitLab Bot Date: Thu, 3 Feb 2022 09:14:03 +0000 Subject: Add latest changes from gitlab-org/gitlab@master --- .gitlab/issue_templates/Deprecations.md | 4 +- .gitlab/merge_request_templates/Removals.md | 5 +- app/assets/javascripts/google_tag_manager/index.js | 8 +- app/assets/javascripts/pipeline_new/constants.js | 7 +- .../settings/components/shared_runners_toggle.vue | 23 +- .../javascripts/projects/settings/constants.js | 7 + app/models/ci/pipeline.rb | 6 - app/models/concerns/ci/contextable.rb | 47 +- .../ci_use_variables_builder_definitions.yml | 8 - .../20220107064845_populate_vulnerability_reads.rb | 25 + db/schema_migrations/20220107064845 | 1 + .../populate_vulnerability_reads.rb | 84 + lib/gitlab/ci/variables/builder.rb | 3 - locale/am_ET/gitlab.po | 1518 +- locale/ar_SA/gitlab.po | 1546 +- locale/as_IN/gitlab.po | 1518 +- locale/az_AZ/gitlab.po | 1518 +- locale/ba_RU/gitlab.po | 1511 +- locale/bg/gitlab.po | 1518 +- locale/bn_BD/gitlab.po | 1518 +- locale/bn_IN/gitlab.po | 1518 +- locale/br_FR/gitlab.po | 1539 +- locale/bs_BA/gitlab.po | 1525 +- locale/ca_ES/gitlab.po | 1518 +- locale/cs_CZ/gitlab.po | 1532 +- locale/cy_GB/gitlab.po | 1546 +- locale/da_DK/gitlab.po | 1576 +- locale/de/gitlab.po | 1570 +- locale/el_GR/gitlab.po | 1518 +- locale/eo/gitlab.po | 1518 +- locale/es/gitlab.po | 2480 +- locale/et_EE/gitlab.po | 1518 +- locale/fa_IR/gitlab.po | 1518 +- locale/fi_FI/gitlab.po | 1518 +- locale/fil_PH/gitlab.po | 1518 +- locale/fr/gitlab.po | 1620 +- locale/gitlab.pot | 6 + locale/gl_ES/gitlab.po | 1518 +- locale/he_IL/gitlab.po | 1532 +- locale/hi_IN/gitlab.po | 1518 +- locale/hr_HR/gitlab.po | 1525 +- locale/hu_HU/gitlab.po | 1518 +- locale/hy_AM/gitlab.po | 1518 +- locale/id_ID/gitlab.po | 1511 +- locale/ig_NG/gitlab.po | 1511 +- locale/is_IS/gitlab.po | 1518 +- locale/it/gitlab.po | 1518 +- locale/ja/gitlab.po | 1553 +- locale/ka_GE/gitlab.po | 1518 +- locale/kab/gitlab.po | 1518 +- locale/ko/gitlab.po | 2147 +- locale/ku_TR/gitlab.po | 1518 +- locale/ky_KG/gitlab.po | 1518 +- locale/lt_LT/gitlab.po | 1532 +- locale/mk_MK/gitlab.po | 1518 +- locale/mn_MN/gitlab.po | 1518 +- locale/nb_NO/gitlab.po | 1550 +- locale/nl_NL/gitlab.po | 1518 +- locale/or_IN/gitlab.po | 43744 +++++++++++++++++++ locale/pa_IN/gitlab.po | 1518 +- locale/pl_PL/gitlab.po | 1534 +- locale/pt_BR/gitlab.po | 2006 +- locale/pt_PT/gitlab.po | 1518 +- locale/ro_RO/gitlab.po | 1769 +- locale/ru/gitlab.po | 3522 +- locale/si_LK/gitlab.po | 1518 +- locale/sk_SK/gitlab.po | 1532 +- locale/sl_SI/gitlab.po | 1532 +- locale/sq_AL/gitlab.po | 1518 +- locale/sr_CS/gitlab.po | 1525 +- locale/sr_SP/gitlab.po | 1525 +- locale/sv_SE/gitlab.po | 1518 +- locale/sw_KE/gitlab.po | 1518 +- locale/ta_IN/gitlab.po | 1518 +- locale/tr_TR/gitlab.po | 1532 +- locale/uk/gitlab.po | 1668 +- locale/ur_PK/gitlab.po | 1518 +- locale/uz_UZ/gitlab.po | 1518 +- locale/vi_VN/gitlab.po | 1511 +- locale/zh_CN/gitlab.po | 1915 +- locale/zh_HK/gitlab.po | 1511 +- locale/zh_TW/gitlab.po | 1511 +- spec/frontend/google_tag_manager/index_spec.js | 12 +- .../populate_vulnerability_reads_spec.rb | 93 + spec/lib/gitlab/ci/variables/builder_spec.rb | 151 +- ...0107064845_populate_vulnerability_reads_spec.rb | 107 + spec/models/ci/build_spec.rb | 168 - 87 files changed, 116650 insertions(+), 34888 deletions(-) delete mode 100644 config/feature_flags/development/ci_use_variables_builder_definitions.yml create mode 100644 db/post_migrate/20220107064845_populate_vulnerability_reads.rb create mode 100644 db/schema_migrations/20220107064845 create mode 100644 lib/gitlab/background_migration/populate_vulnerability_reads.rb create mode 100644 locale/or_IN/gitlab.po create mode 100644 spec/lib/gitlab/background_migration/populate_vulnerability_reads_spec.rb create mode 100644 spec/migrations/20220107064845_populate_vulnerability_reads_spec.rb diff --git a/.gitlab/issue_templates/Deprecations.md b/.gitlab/issue_templates/Deprecations.md index d833efd61f4..1de64088ca6 100644 --- a/.gitlab/issue_templates/Deprecations.md +++ b/.gitlab/issue_templates/Deprecations.md @@ -1,3 +1,5 @@ +For guidance on the overall deprecations, removals and breaking changes workflow, please visit https://about.gitlab.com/handbook/product/gitlab-the-product/#breaking-changes-deprecations-and-removing-features + ### Deprecation Summary @@ -75,4 +77,4 @@ Use the following resources to find the appropriate labels: /label ~"type::deprecation" - \ No newline at end of file + diff --git a/.gitlab/merge_request_templates/Removals.md b/.gitlab/merge_request_templates/Removals.md index 341ea5e831b..c169cd87ac7 100644 --- a/.gitlab/merge_request_templates/Removals.md +++ b/.gitlab/merge_request_templates/Removals.md @@ -6,10 +6,11 @@ **Be sure to link this MR to the relevant issue(s).** -- Removal Issue (or earlier deprecation issue): +- Deprecation issue: +- Removal issue: - MR that removes the feature (optional): -If there is no relevant removal or deprecation issue, hit pause and: +If there is no relevant deprecation issue, hit pause and: - Review the [process for deprecating and removing features](https://about.gitlab.com/handbook/product/gitlab-the-product/#process-for-deprecating-and-removing-a-feature). - Connect with the Product Manager DRI. diff --git a/app/assets/javascripts/google_tag_manager/index.js b/app/assets/javascripts/google_tag_manager/index.js index 0bb4f450101..d6767001eed 100644 --- a/app/assets/javascripts/google_tag_manager/index.js +++ b/app/assets/javascripts/google_tag_manager/index.js @@ -8,14 +8,14 @@ const PRODUCT_INFO = { // eslint-disable-next-line @gitlab/require-i18n-strings name: 'Premium', id: '0002', - price: 228, + price: '228', variant: 'SaaS', }, [SKU_ULTIMATE]: { // eslint-disable-next-line @gitlab/require-i18n-strings name: 'Ultimate', id: '0001', - price: 1188, + price: '1188', variant: 'SaaS', }, }; @@ -220,8 +220,8 @@ export const trackTransaction = (transactionDetails) => { id: transactionId, affiliation: 'GitLab', option: paymentOption, - revenue, - tax, + revenue: revenue.toString(), + tax: tax.toString(), }, products: [product], }, diff --git a/app/assets/javascripts/pipeline_new/constants.js b/app/assets/javascripts/pipeline_new/constants.js index a6c9f3cb746..43f7634083b 100644 --- a/app/assets/javascripts/pipeline_new/constants.js +++ b/app/assets/javascripts/pipeline_new/constants.js @@ -1,3 +1,4 @@ +import { __ } from '~/locale'; import { DEFAULT_DEBOUNCE_AND_THROTTLE_MS } from '~/lib/utils/constants'; export const VARIABLE_TYPE = 'env_var'; @@ -7,5 +8,7 @@ export const CONFIG_VARIABLES_TIMEOUT = 5000; export const BRANCH_REF_TYPE = 'branch'; export const TAG_REF_TYPE = 'tag'; -export const CC_VALIDATION_REQUIRED_ERROR = - 'Credit card required to be on file in order to create a pipeline'; +// must match pipeline/chain/validate/after_config.rb +export const CC_VALIDATION_REQUIRED_ERROR = __( + 'Credit card required to be on file in order to create a pipeline', +); diff --git a/app/assets/javascripts/projects/settings/components/shared_runners_toggle.vue b/app/assets/javascripts/projects/settings/components/shared_runners_toggle.vue index 91d8fca0487..aa3235b1515 100644 --- a/app/assets/javascripts/projects/settings/components/shared_runners_toggle.vue +++ b/app/assets/javascripts/projects/settings/components/shared_runners_toggle.vue @@ -2,6 +2,7 @@ import { GlAlert, GlToggle, GlTooltip } from '@gitlab/ui'; import axios from '~/lib/utils/axios_utils'; import { __, s__ } from '~/locale'; +import { CC_VALIDATION_REQUIRED_ERROR } from '../constants'; const DEFAULT_ERROR_MESSAGE = __('An error occurred while updating the configuration.'); const REQUIRES_VALIDATION_TEXT = s__( @@ -47,11 +48,13 @@ export default { }; }, computed: { - showCreditCardValidation() { + ccRequiredError() { + return this.errorMessage === CC_VALIDATION_REQUIRED_ERROR && !this.ccAlertDismissed; + }, + genericError() { return ( - this.isCreditCardValidationRequired && - !this.isSharedRunnerEnabled && - !this.successfulValidation && + this.errorMessage && + this.errorMessage !== CC_VALIDATION_REQUIRED_ERROR && !this.ccAlertDismissed ); }, @@ -62,6 +65,7 @@ export default { }, toggleSharedRunners() { this.isLoading = true; + this.ccAlertDismissed = false; this.errorMessage = null; axios @@ -82,20 +86,19 @@ export default {