Missing project permissions from shared group permissions on new project

Summary

When sharing groups with groups, newly created projects in nested "project" group are not accessible to users in the "teams" group.

Steps to reproduce

Have a group of users (all are "Maintainer" level in this group): /teams/my-group

Have a group "/projects" and invite above group "/teams/my-group" to it.

After inviting the group, all members of the group have access to projects within /projects and below, also to /projects/nested/groups/mylib. Fine. Now create a new project /projects/nested/groups/anotherlib.

Expected behavior: The users from /teams/my-group can also access /projects/nested/groups/anotherlib Observed behavior: The users from /teams/my-group get 404 when accessing /projects/nested/groups/anotherlib

Workaround: Revoke access to /projects for group /teams/my-group and re-invite the group. Now all members of /teams/my-group have access also to /projects/nested/groups/anotherlib

Expand for output related to GitLab environment info
System information
System:         Debian 9.12
Current User:   git
Using RVM:      no
Ruby Version:   2.6.5p114
Gem Version:    2.7.10
Bundler Version:1.17.3
Rake Version:   12.3.3
Redis Version:  5.0.7
Git Version:    2.24.1
Sidekiq Version:5.2.7
Go Version:     unknown

GitLab information
Version:        12.9.3
Revision:       571e31b8362
Directory:      /opt/gitlab/embedded/service/gitlab-rails
DB Adapter:     PostgreSQL
DB Version:     10.9
URL:            
HTTP Clone URL: 
SSH Clone URL:  
Using LDAP:     no
Using Omniauth: yes
Omniauth Providers:

GitLab Shell
Version:        12.0.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