Use jre of PyCharm
There is an Abandoned variant of PyCharm by Berny32 that uses the JRE that is included with PyCharm: https://sourceforge.net/projects/pycharm-portable/
=>Could you please adapt this project to use the JRE of Pycharm?
Here are my current settings:
[Launch] ProgramExecutable=\PyCharm\jbr\bin\javaw.exe CommandLineArguments=-Djb.vmOptionsFile="%PAL:AppDir%\PyCharm\bin\pycharm64.exe.vmoptions" -XX:ErrorFile="%PAL:DataDir%\java_error_in_pycharm.log" -XX:HeapDumpPath="%PAL:DataDir%\java_error_in_pycharm.hprof" -Didea.properties.file="%PAL:AppDir%\PyCharm\bin\idea.properties" -Didea.config.path="%PAL:DataDir%\config" -Didea.system.path="%PAL:DataDir%\system" -Didea.plugins.path="%PAL:DataDir%\config\plugins" -Didea.log.path="%PAL:DataDir%\system\log" -Didea.platform.prefix=PyCharmCore -cp "%PAL:AppDir%\PyCharm\lib\bootstrap.jar;%PAL:AppDir%\PyCharm\lib\util.jar;%PAL:AppDir%\PyCharm\lib\jdom.jar;%PAL:AppDir%\PyCharm\lib\log4j.jar;%PAL:AppDir%\PyCharm\lib\jna.jar" com.intellij.idea.Main WorkingDirectory=%PAL:AppDir%\PyCharm DirectoryMoveOK=yes SupportsUNC=yes
[Activate] Registry=false XML=true
[Environment] JAVA_HOME=%PAL:AppDir%\PyCharm\jbr PYTHON=%PAL:AppDir%\WinPython\python-3.9.4.amd64\python.exe PYTHON_PATH=%PAL:AppDir%\WinPython\python-3.9.4.amd64;%PAL:AppDir%\WinPython\python-3.9.4.amd64\Scripts;%PAL:AppDir%\WinPython\python-3.9.4\Lib VEUSZ=%PAL:AppDir%\Veusz CPLEX=%PAL:AppDir%\cplex\bin\x64_win64 WINGLPK=%PAL:AppDir%\WinGlpk\w64 GUROBI=%PAL:AppDir%\gurobi\win64 PATH=%PYTHON_PATH%;%VEUSZ%;%CPLEX%;%WINGLPK%;%GUROBI%;%PATH%