René's URL Explorer Experiment


Title: Non Portable binary, doesn't work with sudo or without LD_LIBRARY_PATH · Issue #871 · actions/setup-python · GitHub

Open Graph Title: Non Portable binary, doesn't work with sudo or without LD_LIBRARY_PATH · Issue #871 · actions/setup-python

X Title: Non Portable binary, doesn't work with sudo or without LD_LIBRARY_PATH · Issue #871 · actions/setup-python

Description: Description: Python binary is compiled with rpath that's /opt/hostedtoolcache/Python. Now, latest github runners define RUNNER_TOOL_CACHE/AGENT_TOOLSDIRECTORY differently than /opt/hostedtoolcache and that installs python at /home/runner...

Open Graph Description: Description: Python binary is compiled with rpath that's /opt/hostedtoolcache/Python. Now, latest github runners define RUNNER_TOOL_CACHE/AGENT_TOOLSDIRECTORY differently than /opt/hostedtoolcache ...

X Description: Description: Python binary is compiled with rpath that's /opt/hostedtoolcache/Python. Now, latest github runners define RUNNER_TOOL_CACHE/AGENT_TOOLSDIRECTORY differently than /opt/hostedtoolca...

Opengraph URL: https://github.com/actions/setup-python/issues/871

X: @github

direct link

Domain: github.com


Hey, it has json ld scripts:
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Non Portable binary, doesn't work with sudo or without LD_LIBRARY_PATH","articleBody":"**Description:**\r\nPython binary is [compiled](https://github.com/actions/python-versions/blob/main/builders/ubuntu-python-builder.psm1#L34) with `rpath` that's `/opt/hostedtoolcache/Python`. Now, latest github runners  define `RUNNER_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. \r\n1.  `sudo python --version` doesn't work  ( See Error section) because most systems's doesn't allow passing LD_LIBRARY_PATH due to security issues.\r\n2. `python --version` doesn't work without setting environment variable **_LD_LIBRARY_PATH_**\r\n\r\noutput of ldd : \r\n```\r\nrunner@arss-runner-xxxx-runner-5jvhz:~/_work/_tool/Python/3.12.3/x64/bin$ ldd python3\r\n\tlinux-vdso.so.1 (0x00007ffceb776000)\r\n\tlibpython3.12.so.1.0 =\u003e not found\r\n\tlibc.so.6 =\u003e /lib/x86_64-linux-gnu/libc.so.6 (0x00007f7ccc75c000)\r\n\t/lib64/ld-linux-x86-64.so.2 (0x00007f7ccc991000)\r\n```\r\n\r\nError:\r\n```\r\npython: error while loading shared libraries: libpython3.9.so.1.0: \r\ncannot open shared object file: No such file or directory\r\n```\r\n\r\n**What could be the reason:**\r\n\r\n 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/275\r\n\r\n**Action version:**\r\nv5.1.0\r\n\r\n**Platform:**\r\n- [x] Ubuntu\r\n- [ ] macOS\r\n- [ ] Windows\r\n\r\n**Runner type:**\r\n- [ ] Hosted\r\n- [x] Self-hosted\r\n\r\n**Tools version:**\r\nAll versions of Python 3.9.x, 3.10.x, etc.\r\n\r\n**Repro steps:**  \r\nYou can easily reproduce using following steps. And also, you can unset `LD_LIBRARY_PATH` and just use without sudo\r\n```\r\n    steps:\r\n      - uses: actions/setup-python@v5\r\n        with:\r\n          python-version: '3.12'\r\n      - run: |\r\n          sudo python --version\r\n```\r\n\r\n**Expected behavior:**\r\nThere 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.\r\n\r\n**Actual behavior:**\r\n`sudo python --version` to work.","author":{"url":"https://github.com/jaswanthikolla","@type":"Person","name":"jaswanthikolla"},"datePublished":"2024-05-19T00:36:54.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":14},"url":"https://github.com/871/setup-python/issues/871"}

route-pattern/_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format)
route-controllervoltron_issues_fragments
route-actionissue_layout
fetch-noncev2:e620d752-0341-faef-1702-9e230ba26ab8
current-catalog-service-hash81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114
request-id8E08:1610AC:38E6DE:4CF726:69696BBC
html-safe-noncedee9eb4a70b9e332dcd728324e9bc4105155431ea74144dbe28db54b27b8a9e9
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI4RTA4OjE2MTBBQzozOEU2REU6NENGNzI2OjY5Njk2QkJDIiwidmlzaXRvcl9pZCI6IjQwMDc2ODQxMDM2Mzk0OTM1NjQiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ==
visitor-hmac5cb7b2648cf48e6118256cb2117c43d7dd6005a840f8abe60c8549a7699caa42
hovercard-subject-tagissue:2304359248
github-keyboard-shortcutsrepository,issues,actions,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///voltron/issues_fragments/issue_layout
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/actions/setup-python/871/issue_layout
twitter:imagehttps://opengraph.githubassets.com/b5fe7dd2604d43239ba84185ac24771d0d2d30ee3cc4f55d3d80a402193b7bfa/actions/setup-python/issues/871
twitter:cardsummary_large_image
og:imagehttps://opengraph.githubassets.com/b5fe7dd2604d43239ba84185ac24771d0d2d30ee3cc4f55d3d80a402193b7bfa/actions/setup-python/issues/871
og:image:altDescription: Python binary is compiled with rpath that's /opt/hostedtoolcache/Python. Now, latest github runners define RUNNER_TOOL_CACHE/AGENT_TOOLSDIRECTORY differently than /opt/hostedtoolcache ...
og:image:width1200
og:image:height600
og:site_nameGitHub
og:typeobject
og:author:usernamejaswanthikolla
hostnamegithub.com
expected-hostnamegithub.com
Nonec6f193beb8ff08443adc07685d75302ab8aaf0a135f6e251c3ff3112c8deb881
turbo-cache-controlno-preview
go-importgithub.com/actions/setup-python git https://github.com/actions/setup-python.git
octolytics-dimension-user_id44036562
octolytics-dimension-user_loginactions
octolytics-dimension-repository_id192625525
octolytics-dimension-repository_nwoactions/setup-python
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id192625525
octolytics-dimension-repository_network_root_nwoactions/setup-python
turbo-body-classeslogged-out env-production page-responsive
disable-turbofalse
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
releaseec4d88fbe7ed62446d90b0a6d8e6db4248a8f8b8
ui-targetfull
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://github.com/actions/setup-python/issues/871#start-of-content
https://github.com/
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Factions%2Fsetup-python%2Fissues%2F871
GitHub CopilotWrite better code with AIhttps://github.com/features/copilot
GitHub SparkBuild and deploy intelligent appshttps://github.com/features/spark
GitHub ModelsManage and compare promptshttps://github.com/features/models
MCP RegistryNewIntegrate external toolshttps://github.com/mcp
ActionsAutomate any workflowhttps://github.com/features/actions
CodespacesInstant dev environmentshttps://github.com/features/codespaces
IssuesPlan and track workhttps://github.com/features/issues
Code ReviewManage code changeshttps://github.com/features/code-review
GitHub Advanced SecurityFind and fix vulnerabilitieshttps://github.com/security/advanced-security
Code securitySecure your code as you buildhttps://github.com/security/advanced-security/code-security
Secret protectionStop leaks before they starthttps://github.com/security/advanced-security/secret-protection
Why GitHubhttps://github.com/why-github
Documentationhttps://docs.github.com
Bloghttps://github.blog
Changeloghttps://github.blog/changelog
Marketplacehttps://github.com/marketplace
View all featureshttps://github.com/features
Enterpriseshttps://github.com/enterprise
Small and medium teamshttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
App Modernizationhttps://github.com/solutions/use-case/app-modernization
DevSecOpshttps://github.com/solutions/use-case/devsecops
DevOpshttps://github.com/solutions/use-case/devops
CI/CDhttps://github.com/solutions/use-case/ci-cd
View all use caseshttps://github.com/solutions/use-case
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
View all industrieshttps://github.com/solutions/industry
View all solutionshttps://github.com/solutions
AIhttps://github.com/resources/articles?topic=ai
Software Developmenthttps://github.com/resources/articles?topic=software-development
DevOpshttps://github.com/resources/articles?topic=devops
Securityhttps://github.com/resources/articles?topic=security
View all topicshttps://github.com/resources/articles
Customer storieshttps://github.com/customer-stories
Events & webinarshttps://github.com/resources/events
Ebooks & reportshttps://github.com/resources/whitepapers
Business insightshttps://github.com/solutions/executive-insights
GitHub Skillshttps://skills.github.com
Documentationhttps://docs.github.com
Customer supporthttps://support.github.com
Community forumhttps://github.com/orgs/community/discussions
Trust centerhttps://github.com/trust-center
Partnershttps://github.com/partners
GitHub SponsorsFund open source developershttps://github.com/sponsors
Security Labhttps://securitylab.github.com
Maintainer Communityhttps://maintainers.github.com
Acceleratorhttps://github.com/accelerator
Archive Programhttps://archiveprogram.github.com
Topicshttps://github.com/topics
Trendinghttps://github.com/trending
Collectionshttps://github.com/collections
Enterprise platformAI-powered developer platformhttps://github.com/enterprise
GitHub Advanced SecurityEnterprise-grade security featureshttps://github.com/security/advanced-security
Copilot for BusinessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/premium-support
Pricinghttps://github.com/pricing
Search syntax tipshttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
documentationhttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Factions%2Fsetup-python%2Fissues%2F871
Sign up https://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fvoltron%2Fissues_fragments%2Fissue_layout&source=header-repo&source_repo=actions%2Fsetup-python
Reloadhttps://github.com/actions/setup-python/issues/871
Reloadhttps://github.com/actions/setup-python/issues/871
Reloadhttps://github.com/actions/setup-python/issues/871
actions https://github.com/actions
setup-pythonhttps://github.com/actions/setup-python
Notifications https://github.com/login?return_to=%2Factions%2Fsetup-python
Fork 692 https://github.com/login?return_to=%2Factions%2Fsetup-python
Star 2.1k https://github.com/login?return_to=%2Factions%2Fsetup-python
Code https://github.com/actions/setup-python
Issues 39 https://github.com/actions/setup-python/issues
Pull requests 36 https://github.com/actions/setup-python/pulls
Actions https://github.com/actions/setup-python/actions
Projects 0 https://github.com/actions/setup-python/projects
Security Uh oh! There was an error while loading. Please reload this page. https://github.com/actions/setup-python/security
Please reload this pagehttps://github.com/actions/setup-python/issues/871
Insights https://github.com/actions/setup-python/pulse
Code https://github.com/actions/setup-python
Issues https://github.com/actions/setup-python/issues
Pull requests https://github.com/actions/setup-python/pulls
Actions https://github.com/actions/setup-python/actions
Projects https://github.com/actions/setup-python/projects
Security https://github.com/actions/setup-python/security
Insights https://github.com/actions/setup-python/pulse
New issuehttps://github.com/login?return_to=https://github.com/actions/setup-python/issues/871
New issuehttps://github.com/login?return_to=https://github.com/actions/setup-python/issues/871
Non Portable binary, doesn't work with sudo or without LD_LIBRARY_PATHhttps://github.com/actions/setup-python/issues/871#top
https://github.com/priya-kinthali
bugSomething isn't workinghttps://github.com/actions/setup-python/issues?q=state%3Aopen%20label%3A%22bug%22
https://github.com/jaswanthikolla
https://github.com/jaswanthikolla
jaswanthikollahttps://github.com/jaswanthikolla
on May 19, 2024https://github.com/actions/setup-python/issues/871#issue-2304359248
compiledhttps://github.com/actions/python-versions/blob/main/builders/ubuntu-python-builder.psm1#L34
actions/python-versions#275https://github.com/actions/python-versions/pull/275
priya-kinthalihttps://github.com/priya-kinthali
bugSomething isn't workinghttps://github.com/actions/setup-python/issues?q=state%3Aopen%20label%3A%22bug%22
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.