Fix of saving number of approvals in merge request

Summary

It's pretty simple bug. Approvals doesn't saves any case.

Steps to reproduce

  1. Just create any MR
  2. Add any Approvers (users personally or groups, or both)
  3. Set any number of required approvals (I tried to set 1, 2, 3)
  4. Save the MR

What is the current bug behavior?

In this case you will receive message "No Approval required". This is true for both new MR and for changing existing one.

image image

What is the expected correct behavior?

I expect that the number of Approvals will respect to saved one.

Output of checks

Results of GitLab environment info

Expand for output related to GitLab environment info
$ sudo gitlab-rake gitlab:env:info

System information System: Ubuntu 16.04 Proxy: no Current User: git Using RVM: no Ruby Version: 2.4.4p296 Gem Version: 2.7.6 Bundler Version:1.16.2 Rake Version: 12.3.1 Redis Version: 3.2.11 Git Version: 2.17.1 Sidekiq Version:5.1.3 Go Version: unknown

GitLab information Version: 11.1.0-ee Revision: 9a9f41d Directory: /opt/gitlab/embedded/service/gitlab-rails DB Adapter: postgresql DB Version: 9.6.8 URL: https://gitlab..com HTTP Clone URL: https://gitlab..com/some-group/some-project.git SSH Clone URL: git@gitlab..com:some-group/some-project.git Elasticsearch: no Geo: no Using LDAP: no Using Omniauth: no

GitLab Shell Version: 7.1.4 Repository storage paths: - default: /var/opt/gitlab/git-data/repositories Hooks: /opt/gitlab/embedded/service/gitlab-shell/hooks Git: /opt/gitlab/embedded/bin/git

Results of GitLab application Check

Expand for output related to the GitLab application check

sudo gitlab-rake gitlab:check SANITIZE=true Checking GitLab Shell ...

GitLab Shell version >= 7.1.4 ? ... OK (7.1.4) Repo base directory exists? default... yes Repo storage directories are symlinks? default... no Repo paths owned by git:root, or git:git? default... yes Repo paths access is drwxrws---? default... yes hooks directories in repos are links: ... 1/1 ... ok 1/3 ... ok 2/4 ... ok 2/5 ... ok 11/6 ... repository is empty 15/8 ... repository is empty 4/9 ... repository is empty 16/10 ... ok 12/11 ... ok 12/12 ... ok 12/13 ... ok 19/14 ... ok 19/15 ... ok 19/16 ... ok 19/17 ... ok 19/18 ... ok 19/19 ... ok 19/20 ... ok 19/21 ... ok 19/22 ... ok 19/23 ... ok 19/24 ... ok 19/25 ... ok 19/26 ... ok 19/28 ... ok 19/29 ... ok 19/31 ... ok 19/33 ... ok 19/34 ... ok 19/35 ... ok 16/37 ... ok Running /opt/gitlab/embedded/service/gitlab-shell/bin/check Check GitLab API access: OK Redis available via internal API: OK

Access to /var/opt/gitlab/.ssh/authorized_keys: OK gitlab-shell self-check successful

Checking GitLab Shell ... Finished

Checking Sidekiq ...

Running? ... yes Number of Sidekiq processes ... 1

Checking Sidekiq ... Finished

Reply by email is disabled in config/gitlab.yml Checking LDAP ...

LDAP is disabled in config/gitlab.yml

Checking LDAP ... Finished

Checking GitLab ...

Git configured correctly? ... yes Database config exists? ... yes All migrations up? ... yes Database contains orphaned GroupMembers? ... no GitLab config exists? ... yes GitLab config up to date? ... yes Log directory writable? ... yes Tmp directory writable? ... yes Uploads directory exists? ... yes Uploads directory has correct permissions? ... yes Uploads directory tmp has correct permissions? ... yes Init script exists? ... skipped (omnibus-gitlab has no init script) Init script up-to-date? ... skipped (omnibus-gitlab has no init script) Projects have namespace: ... 1/1 ... yes 1/3 ... yes 2/4 ... yes 2/5 ... yes 11/6 ... yes 15/8 ... yes 4/9 ... yes 16/10 ... yes 12/11 ... yes 12/12 ... yes 12/13 ... yes 19/14 ... yes 19/15 ... yes 19/16 ... yes 19/17 ... yes 19/18 ... yes 19/19 ... yes 19/20 ... yes 19/21 ... yes 19/22 ... yes 19/23 ... yes 19/24 ... yes 19/25 ... yes 19/26 ... yes 19/28 ... yes 19/29 ... yes 19/31 ... yes 19/33 ... yes 19/34 ... yes 19/35 ... yes 16/37 ... yes Redis version >= 2.8.0? ... yes Ruby version >= 2.3.5 ? ... yes (2.4.4) Git version >= 2.9.5 ? ... yes (2.17.1) Git user has default SSH configuration? ... yes Active users: ... 12 Elasticsearch version 5.1 - 5.5? ... skipped (elasticsearch is disabled)

Checking GitLab ... Finished

Edited Sep 02, 2020 by 🤖 GitLab Bot 🤖
Assignee Loading
Time tracking Loading