void (@NotNull Project project, @NotNull ProblemDescriptor descriptor) { final PsiElement element = PyQuickFixUtil.dereference(descriptor.getPsiElement()); if (element == null) { return; } if (element instanceof PyTargetExpression) { final String name = ((PyTargetExpression)element).getName(); if (name == null) return; final VirtualFile virtualFile = element.getContainingFile().getVirtualFile(); if (virtualFile != null) { final String publicName = StringUtil.trimLeading(name, '_'); PythonUiService.getInstance().runRenameProcessor(project, element, publicName, false, false); } } }