The problem was introduced in a5884f47c5f29e20915481944c4ad9390708f752
and then fixed in fb7c98e8df472dbe8cc0510f002fdde72f0b8770.
Namely, for a non-existing value of the system PYTHONPATH we ended up adding
an extra ":" at the end of our PYTHONPATH before running the syspath.py helper.
Whenever Python interpreter encounters a non-absolute entry in PYTHONPATH
it tries to resolve it relatively to the current working directory and for
the PyCharm process on macOS the latter was "/". Hence, we ended up with
the filesystem root among detected interpreter paths and started indexing it.
I added protection against such entries in syspath.py, assuming that no one
is going to intentionally include an IDE's working directory into PYTHONPATH,
as well as handling of an empty list of path entries in
PythonScripts.appendToPythonPath.
GitOrigin-RevId: d1f3ee4b844edf95e0d24e3245ab73b4a39194f5
Previously, it relied on the path the script was launched with to detect and
exclude "helpers" root from the results. Now it uses __file__ to find
the directory it resides in.
GitOrigin-RevId: fd3edce1a6a33fd82607953f75cafa5c558373cd