maintainer can't inspect commits (no permission) in merge requests from other private repos
Created by: joernhees
how to reproduce:
- i (maintainer) have a private repo "upstream" and added a reporter to it...
- reporter found a bug
- reporter forked repo into an own repository "fork"
- reporter created commits on branch "fix" and pushed them to "fork/fix"
- reporter creates a merge request from "fork/fix" to "upstream/master"
- i (maintainer) go to "upstream/merge_requests" and inspect the merge request...
- i can see the combined changes of all commits in change tab
- i can see the commits overview in the commits tab
- bug:
- i can't inspect the commits (clicking on them i am directed to "fork/commit/...", but when reporter forked i didn't get any permissions on his private "fork" repo.).
- i also can't browse the tree for any of the given commits (same reasons as above)
- the manual merge via command line popup also doesn't work: it tells me to fetch code from "fork", but i don't have the permissions to do so.
In general it's a good thing that i don't automagically get any permissions on private forks of my repos, but i should in general be able to inspect everything that i merge into my repo.
I think github solves this issue by syncing the commits in a pull request into (in this case) "upstream/pull/num" where num is the merge request number. As i have all permissions below upstream, the permission system doesn't need to be changed to include any exceptions.
Running git ls-remote upstream
doesn't give me any refs on the remote upstream that i could use to inspect the merge requests :(. If it did i could also use a config line like remote.upstream.fetch=+refs/pull/*/head:refs/remotes/upstream/pull/*
to just fetch all commits in any merge_requests to inspect them locally...
Maybe a bugfix + awesome feature at once?