Open jaswanthikolla opened 1 month ago
Hello @jaswanthikolla, Thank you for creating this issue and we will get back to you once we have some feedback on this :)
@aparnajyothi-y I raised the issue just for documentation. PR is already raised to fix this issue, Can you review that.
@jaswanthikolla thank you for your efforts thus far, it's a shame there hasn't been more movement on this.
@aparnajyothi-y This is affecting certain ansible modules as well now. I am unable to run my checks now due to this.
Description: Python binary is compiled with
rpath
that's/opt/hostedtoolcache/Python
. Now, latest github runners defineRUNNER_TOOL_CACHE/AGENT_TOOLSDIRECTORY
differently than/opt/hostedtoolcache
and that installs python at/home/runner/_work/_tool/Python/
. So, with this, there are 2 issues.sudo python --version
doesn't work ( See Error section) because most systems's doesn't allow passing LD_LIBRARY_PATH due to security issues.python --version
doesn't work without setting environment variable _LD_LIBRARYPATHoutput of ldd :
Error:
What could be the reason:
rpath is hardcoded to
/opt/hostedtoolcache/Python
. if we use $ORIGIN, binaries will be portable. Fix is raised here https://github.com/actions/python-versions/pull/275Action version: v5.1.0
Platform:
Runner type:
Tools version: All versions of Python 3.9.x, 3.10.x, etc.
Repro steps:
You can easily reproduce using following steps. And also, you can unset
LD_LIBRARY_PATH
and just use without sudoExpected behavior: There are times we need to use
sudo python
and Most system ( also not acceptable to pass) doesn't pass LD_LIBRARY_PATH as environment variable due to security issues.Actual behavior:
sudo python --version
to work.