Skip patchset-level comments in diff view
Starting in Gerrit 3.3, comments can include a special file-id of /PATCHSET_LEVEL and these comments have no code context, thus no line numbers or related files. Skip these when enumerating comments in diff view because there is no relevant context for them. Thanks to Paul Fertser for reporting and debugging this problem. Change-Id: I6505d08b62ba7ad8877561a82732889e142873c3
This commit is contained in:
parent
cd60a82f6a
commit
699aa18766
@ -236,6 +236,8 @@ class BaseDiffView(urwid.WidgetWrap, mywid.Searchable):
|
||||
comment_filenames = set()
|
||||
for comment in new_comments:
|
||||
path = comment.file.path
|
||||
if path == '/PATCHSET_LEVEL': # patchset-level comments in 3.3
|
||||
continue
|
||||
if comment.parent:
|
||||
if old_revision: # we're not looking at the base
|
||||
continue
|
||||
|
Loading…
x
Reference in New Issue
Block a user