Change: Use fnmatch for workflow path matching (#5250)

This commit is contained in:
shamoon
2024-01-05 11:15:14 -08:00
committed by GitHub
parent 355a434a07
commit d623af9c41
2 changed files with 51 additions and 1 deletions

View File

@@ -296,7 +296,10 @@ def consumable_document_matches_workflow(
if (
trigger.filter_path is not None
and len(trigger.filter_path) > 0
and not document.original_file.match(trigger.filter_path)
and not fnmatch(
document.original_file,
trigger.filter_path,
)
):
reason = (
f"Document path {document.original_file}"