Merge request approvers in list sometimes doesnt show correct number
### Summary (Summarize the bug encountered concisely) In my test instance, I created multiple merge requests that require 2 approvers as Administrator and got this as a result. ![Screenshot_2019-07-01_at_10.13.35](/uploads/73951d74d699b8989285f3e74d2cdad4/Screenshot_2019-07-01_at_10.13.35.png) Where only the one 3 days old shows the correct number. I tried to reproduce this with my dummy account on my test instance but never got that to work. ![Screenshot_2019-07-01_at_10.13.10](/uploads/545fcbf057a23d80bff8a19249bb7a32/Screenshot_2019-07-01_at_10.13.10.png) Now this problem doesn't happen all the time. I tried several steps to try and reproduce this. ### What is the current *bug* behavior? 1. Set approvers number in the merge request, created a merge request. 2. Set approvers number in the settings, created a merge request. 3. Set selected approvers in the settings, created a merge request. Now depending on the project this either shows the correct number at `/merge_requests` while sometimes it just shows `0 of 0` ### What is the expected *correct* behavior? It should always show the correct number of approvers required and already approved. #### Results of GitLab environment info <details> <summary>Expand for output related to GitLab environment info</summary> <pre> root@rz-gltest:/# sudo gitlab-rake gitlab:env:info System information System: Ubuntu 16.04 Proxy: no Current User: git Using RVM: no Ruby Version: 2.6.3p62 Gem Version: 2.7.9 Bundler Version:1.17.3 Rake Version: 12.3.2 Redis Version: 3.2.12 Git Version: 2.21.0 Sidekiq Version:5.2.7 Go Version: go1.6.2 linux/amd64 GitLab information Version: 12.0.2-ee Revision: ef76b54fc1e Directory: /opt/gitlab/embedded/service/gitlab-rails DB Adapter: PostgreSQL DB Version: 10.7 URL: http://178.128.44.26 HTTP Clone URL: http://178.128.44.26/some-group/some-project.git SSH Clone URL: git@178.128.44.26:some-group/some-project.git Elasticsearch: yes Geo: no Using LDAP: no Using Omniauth: yes Omniauth Providers: gitlab GitLab Shell Version: 9.3.0 Repository storage paths: - default: /var/opt/gitlab/git-data/repositories GitLab Shell path: /opt/gitlab/embedded/service/gitlab-shell Git: /opt/gitlab/embedded/bin/git </pre> </details> #### Results of GitLab application Check <details> <summary>Expand for output related to the GitLab application check</summary> <pre> root@rz-gltest:/# sudo gitlab-rake gitlab:check SANITIZE=true Checking GitLab subtasks ... Checking GitLab Shell ... GitLab Shell: ... GitLab Shell version >= 9.3.0 ? ... OK (9.3.0) 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 Gitaly ... Gitaly: ... default ... OK Checking Gitaly ... Finished Checking Sidekiq ... Sidekiq: ... Running? ... yes Number of Sidekiq processes ... 1 Checking Sidekiq ... Finished Checking Incoming Email ... Incoming Email: ... Reply by email is disabled in config/gitlab.yml Checking Incoming Email ... Finished Checking LDAP ... LDAP: ... LDAP is disabled in config/gitlab.yml Checking LDAP ... Finished Checking GitLab App ... 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/2 ... yes 2/3 ... yes 1/4 ... yes 1/5 ... yes 4/6 ... yes 13/7 ... yes 5/8 ... yes 1/9 ... yes 1/10 ... yes 4/11 ... yes 1/12 ... yes Redis version >= 2.8.0? ... yes Ruby version >= 2.5.3 ? ... yes (2.6.3) Git version >= 2.21.0 ? ... yes (2.21.0) Git user has default SSH configuration? ... yes Active users: ... 3 Elasticsearch version 5.6 - 6.x? ... yes (6.6.0) Checking GitLab App ... Finished Checking GitLab subtasks ... Finished </pre> </details> ### Possible fixes Zendesk: https://gitlab.zendesk.com/agent/tickets/124778 (internal)
issue