private static boolean isPythonLanguage(@NotNull PsiFile file, int offset) {
    return PsiUtilCore.getLanguageAtOffset(file, offset).isKindOf(PythonLanguage.getInstance());
  }
private static boolean isPythonLanguage(@NotNull PsiFile file, int offset)