diff --git a/pr_agent/algo/git_patch_processing.py b/pr_agent/algo/git_patch_processing.py index 30bdd8c9..83348d31 100644 --- a/pr_agent/algo/git_patch_processing.py +++ b/pr_agent/algo/git_patch_processing.py @@ -19,9 +19,9 @@ def extend_patch(original_file_str, patch_str, patch_extra_lines_before=0, return "" # skip patches - skip_types = get_settings().config.skip_types #[".md",".txt"] - if skip_types: - if any([filename.endswith(skip_type) for skip_type in skip_types]): + patch_extension_skip_types = get_settings().config.skip_types #[".md",".txt"] + if patch_extension_skip_types: + if any([filename.endswith(skip_type) for skip_type in patch_extension_skip_types]): return patch_str # dynamic context settings diff --git a/pr_agent/settings/configuration.toml b/pr_agent/settings/configuration.toml index 0ca90c35..7d609863 100644 --- a/pr_agent/settings/configuration.toml +++ b/pr_agent/settings/configuration.toml @@ -20,7 +20,7 @@ max_commits_tokens = 500 max_model_tokens = 32000 # Limits the maximum number of tokens that can be used by any model, regardless of the model's default capabilities. custom_model_max_tokens=-1 # for models not in the default list # patch extension logic -skip_types =[".md",".txt"] +patch_extension_skip_types =[".md",".txt"] allow_dynamic_context=false max_extra_lines_before_dynamic_context = 10 # will try to include up to 10 extra lines before the hunk in the patch, until we reach an enclosing function or class patch_extra_lines_before = 3 # Number of extra lines (+3 default ones) to include before each hunk in the patch