Pull from Remote Repository allows self-reference
Summary
It is possible to enter the current repository name as the remote repository to mirror.
Steps to reproduce
- Go to
https://gitlab.com/<org>/<project>/settings/repository - Expand 'Pull from a remote repository'
- Enter
https://gitlab.com/<org>/<project>as the remote repository, wherehttps://gitlab.com/<org>/<project>is the same repository. Click Save.
Example Project
I did this unintentionally on https://gitlab.com/coala/package_manager/settings/repository , but it has been just disabled.
What is the current bug behavior?
The self-mirroring is allowed, and seems to work, but isnt sane.
What is the expected correct behavior?
UI prevents saving. Ideally there is also a cyclic check to prevent B mirroring A, and A mirroring B. The UI should error when A is trying to add a mirror which is a mirror that eventually loops back to A.
Relevant logs and/or screenshots
None.
Output of checks
This bug happens on GitLab.com
Edited by John Vandenberg