How would I go on about making Semgrep check if my codebase is importing functions from the wrong place? E.g. in my django project:
from gettext import gettext
but we should really do from django.utils.translation import gettext
Any ideas on how to achieve this with semgrep?
Does this do what you want? Here's a live example link: https://semgrep.dev/s/0n0w