From f66b78f6b39157e263a1c8ecb5e43fab2ad41d48 Mon Sep 17 00:00:00 2001 From: Alex Vandiver Date: Fri, 21 Jun 2024 19:30:02 +0000 Subject: [PATCH] semgrep: Allow zerver.lib.mime_types imports in migrations. --- tools/semgrep-py.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/tools/semgrep-py.yml b/tools/semgrep-py.yml index 535b3b9cb8..d3fb6b352d 100644 --- a/tools/semgrep-py.yml +++ b/tools/semgrep-py.yml @@ -54,6 +54,7 @@ rules: - id: dont-import-models-in-migrations patterns: + - pattern-not: from zerver.lib.mime_types import guess_type - pattern-not: from zerver.lib.redis_utils import get_redis_client - pattern-not: from zerver.lib.utils import generate_api_key - pattern-not: from zerver.models.linkifiers import filter_pattern_validator