From bdee6f9f3624b9b090b2d24d19b6b3e07ce481e0 Mon Sep 17 00:00:00 2001 From: furikake6000 Date: Mon, 21 Jul 2025 10:15:57 +0000 Subject: [PATCH] fix: add error handling to bitbucket file filtering --- pr_agent/algo/file_filter.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pr_agent/algo/file_filter.py b/pr_agent/algo/file_filter.py index 0812759f..3177d0b1 100644 --- a/pr_agent/algo/file_filter.py +++ b/pr_agent/algo/file_filter.py @@ -57,7 +57,7 @@ def filter_ignored(files, platform = 'github'): continue files = files_o elif platform == 'bitbucket_server': - files = [f for f in files if not r.match(f['path']['toString'])] + files = [f for f in files if f.get('path', {}).get('toString') and not r.match(f['path']['toString'])] elif platform == 'gitlab': # files = [f for f in files if (f['new_path'] and not r.match(f['new_path']))] files_o = []