Fix GitHub importer for PRs of deleted forked repositories
What does this MR do?
Adds additional checks to prevent errors with nil
source repository, and adds another branch_name pattern when we can't retrieve the original namespace/repository
path as the repository was deleted and the API doesn't keep historic data.
Are there points in the code the reviewer needs to double check?
We need to make sure we are not breaking existing functionality like the removal of the branch after the MR is restored, etc.
Why was this MR needed?
Import was failing with a undefined method
id' for nil:NilClass `
Does this MR meet the acceptance criteria?
-
Changelog entry added -
Documentation created/updated -
API support added - Tests
-
Added for this feature/bug -
All builds are passing
-
-
Conform by the merge request performance guides -
Conform by the style guides -
Branch has no merge conflicts with master
(if it does - rebase it please) -
Squashed related commits together
What are the relevant issue numbers?
https://gitlab.zendesk.com/agent/tickets/67647
Closes #29541 (closed)