Important source file changes not visible for merge request

Summary

I have a branch with many changes to merge back into the master branch. The majority of the changes are in our python test script below a folder named QA_Test. The really important changes are in the C/C++ source files below a folder named src.

The gitlab merge request does not show the changes for the files below src, neither in the file browser nor in the diff-view. (They are only visible in the plain diff view as generated by git-diff.)

This issue seems to be similar to gitlab-ce#13759 (but I can not reopen this one) and maybe related to gitlab-ce#33421 .

Steps to reproduce

  • Create a project with sub-folders a/ to s/
  • create some branch for this project, with
    • change about 300 files in the sub-folders a/ to e/
    • change about 10 files in sub-folder s/
  • Create e merge request to merge back the branch into master

Example Project

  • Create example project

What is the current bug behavior?

I have a branch with many changes to merge back into the master branch. The majority of the changes are in our python test script below a folder named QA_Test. The really important changes are in the C/C++ source files below a folder named src.

The gitlab merge request does not show the changes for the files below src, neither in the file browser nor in the diff-view. (They are only visible in the plain diff view as generated by git-diff.)

In the first place gitlab reported 318+ files changed, not counting the files changed in src/. After changing 2 more files below QA_Test/, gitlab reported 320+ files changed, with the additional 2 changed files. But still without the files below src/.

The file browser of the gitlab merge request shows changes in the following sub directories:

  • QA_Test/
  • bin/
  • doc/
  • gen/
  • include/

Therefore I guess, that the important src/ directory is excluded by alphabetical order.

What is the expected correct behavior?

Because gitlab-ce#33421 requested, that for performance reasons not all changes are shown, the user should have some means to prioritize the files which are shown. The file browser of the merge request page offers already an input field to specify a file name filter. This could be used to specify a pathspec argument for git-diff. So for example, if a user specifies the path src/ then the gitlab merge request changes page should be based on the output of git diff master -- src/.

Relevant logs and/or screenshots

(Paste any relevant logs - please use code blocks (```) to format console output, logs, and code as it's tough to read otherwise.)

Output of checks

Results of GitLab environment info

Expand for output related to GitLab environment info

Linux wklj 4.19.0-5-amd64 #1 SMP Debian 4.19.37-5+deb10u1 (2019-07-19) x86_64

The programs included with the Debian GNU/Linux system are free software; the exact distribution terms for each program are described in the individual files in /usr/share/doc/*/copyright.

Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent permitted by applicable law. Last login: Mon Jul 29 08:48:12 2019 from 192.168.25.142 root@wklj:~# gitlab-rake gitlab:env:info

System information System: Debian 10 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: unknown

GitLab information Version: 12.1.1 Revision: f9abaa7d833 Directory: /opt/gitlab/embedded/service/gitlab-rails DB Adapter: PostgreSQL DB Version: 10.7 URL: http://wklj.inat.internal HTTP Clone URL: http://wklj.inat.internal/some-group/some-project.git SSH Clone URL: git@wklj.inat.internal:some-group/some-project.git Using LDAP: no Using Omniauth: yes Omniauth Providers:

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

Results of GitLab application Check

Expand for output related to the GitLab application check

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: ... 2/1 ... yes 2/2 ... yes 4/3 ... yes 28/4 ... yes 4/5 ... yes 4/8 ... yes 4/9 ... yes 4/10 ... yes 2/11 ... yes 2/12 ... yes 13/13 ... yes 13/14 ... yes 11/15 ... yes 14/17 ... yes 4/18 ... yes 4/19 ... yes 21/20 ... yes 12/21 ... yes 5/22 ... yes 4/23 ... yes 4/24 ... yes 4/25 ... yes 4/26 ... yes 4/27 ... yes 4/28 ... yes 21/29 ... yes 4/30 ... yes 4/31 ... yes 4/32 ... yes 11/33 ... yes 11/34 ... yes 4/35 ... yes 5/36 ... yes 5/37 ... yes 4/38 ... yes 28/39 ... yes 28/41 ... yes 28/42 ... yes 13/43 ... yes 28/44 ... yes 28/45 ... yes 28/46 ... yes 4/47 ... yes 11/48 ... 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: ... 21

Checking GitLab App ... Finished

Checking GitLab subtasks ... Finished

Edited by Juergen Kosel