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

kt

intellij {
    downloadSources.set(false)
    version.set("2023.1.2")
    type.set("PC") // Target IDE Platform
//    localPath.set("D:\\Soft\\JetBrains\\PyCharm 2022.3.3")
    plugins.set(listOf("PythonCore"))
}
0

Hi,

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.

0

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:
https://github.com/a3538333/pycharm-plugin-demo.git

0

请先登录再写评论。