Verifies if there are python distributives for MacOS / Windows on ARM / X86 / X86_64
(cherry picked from commit 717f1a4540d12502e46e3b0fd29b08d2d2043281)
IJ-MR-121650
GitOrigin-RevId: 71ff849618c362bec369372f4952824a454d607d
also bump sdks.json to latest
(cherry picked from commit 14cc088c20a8b77ee49007d8f7b982920e40c6e6)
IJ-MR-121650
GitOrigin-RevId: db7c0d11a61e239e2f47bd2f1a8dd1156f3712b1
it prevents failures when the python was installed and deleted previously, or it is in a corrupted state (previous installation was cancelled for example)
GitOrigin-RevId: ca373847db5ed694501da3db6e8a7e88aa15efd5
Removed the "commons-collections" library across multiple modules as it is no longer needed. This clean up helps streamline dependencies and reduce project complexity.
GitOrigin-RevId: 3763cf649644d8782e03b7419d780e245c5f3eef
`readableFs` is redundant and unstable. Remove it: we will migrate to ijent anyway.
All validations are in `PathValidator.kt` now. They are used by `ManualPathEntryDialog` and sdk validation.
Lots of thread annotations added to prevent calling validation code from EDT.
In general, this change makes path validation ready for ijent: validation based on nio with slow IO access.
Validation is removed from old, non-target classes
(cherry picked from commit 185b4f7fe8cbd5d7a37dad609c8a4cb8163d6eed)
IJ-MR-112281
GitOrigin-RevId: 12c4a4f3d459d0523ef6694a9e4bb2db7a1582b7
No need to pollute logs with each call, so we cache calls and log it only once. Circular buffer is used to prevent memory leak
Merge-request: IJ-MR-107323
Merged-by: Ilya Kazakevich <ilya.kazakevich@jetbrains.com>
GitOrigin-RevId: ab20095f15a69f02cc971627865a65b396a54d64
``/usr/bin/python`` is symlink in many distros and can't be checked via 9P (``\\wsl$``). Hence, we provide ``Unknown`` for such cases.
See issue comment for more info
(cherry picked from commit 529eec2203f21e91c1ebc4f3df5d9b22ce4fcf3b)
IJ-MR-98852
(cherry picked from commit e4954edbc1d87709387ebaaf0a2cac0f150c5d05)
GitOrigin-RevId: d6b4b955a14e38fe217a20f33e6260c050af0984
Now we have Code Vision hints which determine the author via Git history and show it in the editor automatically, and this information is more accurate than the tags which were automatically added when files were created.
GitOrigin-RevId: f1b80125c2555d89f32aae4e5290d7771a357abf
Using `Sdk.getHomePath()` as the path to interpreter is not reliable for every case. For example, for legacy remote interpreters `Sdk.getHomePath()` contains prefix, which is used to distinguish different types of remote credentials (for example `sftp://` or `docker://`). It also contains the representation of the value of the remote credentials used. In this case the interpreter path is available via `PythonSdkAdditionalData.getInterpreterPath()`.
These changes fix the problem introduced in c63b57aac9b5a267b3a6710902670bfe7d10c722.
GitOrigin-RevId: a7dc2579d1b0b367353fbecf4b9fe4a56b098e9b
See last comment in PY-57226.
* Use console encoding for PythonExecution
* DO NOT provide ``PYTHONIOENCODING``
* Build PyCharm without of ``file.encoding``
Merge-request: IJ-MR-98463
Merged-by: Ilya Kazakevich <ilya.kazakevich@jetbrains.com>
GitOrigin-RevId: 943402d55d3c4aa5460b2fae2602ed43e88029ce
See ``TargetedCommandLineBuilder.addEnvVars`` doc for the main issue.
We also add fix to patch path in PythonScripts
GitOrigin-RevId: f42044338f91d5b444c5e1431957272392ab5f1c
What was wrong:
For SDK creation we execute python to get python path for homePath (see ``PyAddCondaTools``).
So, we execute python on conda before homePath set.
On each execution we read vars from ``activate.bat`` to workaround conda SSL in path problem and activate terminal (since cmd in terminal still uses old API).
``PySdkUtil`` can't read vars when homePath not set, hence caches empty vars for SDK and both terminal and conda workaround stop working until IDE restart.
We now stopped caching empty vars if homePath is empty.
GitOrigin-RevId: de3e37bbbc5281775e3fca79840089561ceed189
This is a quick-and-dirty for terminals. Regular conda execution shouldn't be affected since we store python path in ``homePath`` now.
With this change, ``activate.bat`` read by IJ and vars (including ``PATH``) are passed to the terminal
GitOrigin-RevId: 711e5ea84519894ad3779626d4411196abb5a6b6
``PYCHARM_HOSTED`` makes ``Coloroma`` assume that ``isatty() == true`` (even for bat file redirected to another file) which leads to problems on Windows. See issue comments for more info
GitOrigin-RevId: b82b25e7175330ae86604fc14012ef85e2b8ba0b
Each sdk has additional data with flavor and flavor-specific data. For target-based SDK there is also target information. ``PySdkExt`` has extension method that uses this data to execute code on some SDK. For Conda we store path to conda binary and env name.
GitOrigin-RevId: c63b57aac9b5a267b3a6710902670bfe7d10c722
The problem is ``sys.stdout.encoding``.
On Unix Python uses ``LC_`` which is UTF-8 since late 2000s.
But on Windows for non-console based executions (with stdout redirected) it uses one byte encoding (aka non-unicode programs charset) due to backward compatibility with 9x/me.
With one-byte charset you can't have both latin-1 and cyrillic characters.
To fix that, we provide ``PYTHONIOENCODING`` which sets charset explicitly
GitOrigin-RevId: 5c3304e002d80fb5780f11f05fe5f4d1b6aef3ad