Intellij SonarLint - "java.nio.file.InvalidPathException" when using remote interpreter on python

System info:

  • Operating system: Win11
  • SonarLint plugin version: 10.7.0.78874
  • Programming language you’re coding in: Python
  • Is connected mode used: NO

I’m encountering an error when invoking SonarLint analysis (ctrl+shift+s) on my Python module through Intellij Ultimate (not pycharm). The error occurs when SonarLint tries to analyze ANYFILE within my python module. And it does not happen in any other modules (ex: Java, Typescript)

java.nio.file.InvalidPathException: Illegal char <:> at index 14: docker-compose://[C:/Users/_____/IdeaProjects/python-tinker2/docker-compose.yml]:python-app//bin/python3

After some digging, I realize it is due to I have configured to use docker-compose remote interpreter as my python interpreter at my module SDK.

So the value of my “python sdk home path” - really has a colon at index 14 (=15th letter).

docker-compose:\\[C:\Users\______\IdeaProjects\python-tinker2\docker-compose.yml]:python-app\\bin\python3

If I switch to normal local interpreter, then this error is gone when I invoke SonarLint analysis (ctrl+shift+s)

I have searched a bit on Jetbrains’ Youtrack, a similar issue at IDE side is below, maybe interesting as reference?

Hope this bug can get fixed or any workaround?

Hello @Stadia_Yoyo, we are aware of some issues related to remote projects of any kind. I will make sure to get back to you whenever I investigate the case. Thank you.

Could you send us the full SonarLint logs when this issue occurs? It would be better if you could try with the latest version of SonarLint, 10.8.1.

Thank you.