# HG changeset patch # User Marcin Kuzminski # Date 2020-08-11 10:34:28 # Node ID f5835fa99b771ef316db2d11b047c591f2095d04 # Parent 0186d5e239336c611bc33933c82a9ed1f8e576d8 pull-requests: log a mismatch of name changed during a display of a PR. If long-living PR was altered that the names of repo doesn't match anymore, we'll show a warning instead of silent 404. diff --git a/rhodecode/apps/repository/views/repo_pull_requests.py b/rhodecode/apps/repository/views/repo_pull_requests.py --- a/rhodecode/apps/repository/views/repo_pull_requests.py +++ b/rhodecode/apps/repository/views/repo_pull_requests.py @@ -351,6 +351,8 @@ class RepoPullRequestsView(RepoAppView, # pull_requests repo_name we opened it against # ie. target_repo must match if self.db_repo_name != pull_request_at_ver.target_repo.repo_name: + log.warning('Mismatch between the current repo: %s, and target %s', + self.db_repo_name, pull_request_at_ver.target_repo.repo_name) raise HTTPNotFound() c.shadow_clone_url = PullRequestModel().get_shadow_clone_url(