PyCharm plugin development: Issue with user modifying project name.


I have developed a PyCharm plugin, and there are several functionalities that require accessing the Project object. However, I have encountered an issue where, during the usage of the plugin, if the user modifies the project name or folder name, the names obtained through the API are not the updated ones but the previous ones.

Steps to Reproduce

1. Create a class that implements the interface ToolWindowFactory. Use the createToolWindowContent

2. Create an Action and use the actionPerformed method to obtain the ProjectName from the AnActionEvent object.

Expected Result

Obtain the new project path and name.

Actual Result

Obtain the old data, and even after restarting, the issue remains unresolved.

pycharm version


intellij {
    type.set("PC") // Target IDE Platform
//    localPath.set("D:\\Soft\\JetBrains\\PyCharm 2022.3.3")


Your steps to reproduce are very general. Please provide a minimal project implementation that allows reproducing the issue.

Due to the large number of support requests, we cannot spend time implementing the logic to reproduce issues. We need a ready to run project that doesn't require any additional effort.


I apologize for the inconvenience. I have now written a project to reproduce the issue, which is attached to this response. Please have a look and help me with it. Thank you very much.

project git:


Please sign in to leave a comment.