René's URL Explorer Experiment


Title: Allow partial cache keys · Issue #627 · actions/setup-python · GitHub

Open Graph Title: Allow partial cache keys · Issue #627 · actions/setup-python

X Title: Allow partial cache keys · Issue #627 · actions/setup-python

Description: Description: When restoring cache, the current cache management system only uses the primary cache key. GitHub Actions cache allows specifying multiple prefixes, and restoring older caches, to speed up setup even when there has been a de...

Open Graph Description: Description: When restoring cache, the current cache management system only uses the primary cache key. GitHub Actions cache allows specifying multiple prefixes, and restoring older caches, to spee...

X Description: Description: When restoring cache, the current cache management system only uses the primary cache key. GitHub Actions cache allows specifying multiple prefixes, and restoring older caches, to spee...

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

X: @github

direct link

Domain: github.com


Hey, it has json ld scripts:
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Allow partial cache keys","articleBody":"**Description:**\r\n\r\nWhen restoring cache, the current cache management system only uses the primary cache key.\r\n\r\nGitHub Actions cache allows specifying multiple prefixes, and restoring older caches, to speed up setup even when there has been a dependency change. Cf [corresponding documentation](https://docs.github.com/en/actions/using-workflows/caching-dependencies-to-speed-up-workflows#matching-a-cache-key)\r\n\r\nI'd recommend setting this as an opt-in behaviour, toggleable with a new input, because :\r\n* That way, this would not be a breaking change\r\n* Never rebuilding from scratch means stale data could stay forever in cache, which can be dangerous (e.g. a former dependency still present in a virtualenv)\r\n\r\nHere's an example of what the configuration could look like (for poetry) : \r\n\r\n```yaml\r\n    - uses: actions/setup-python@v4\r\n      id: setup-python\r\n      with:\r\n        python-version: \"3.10\"\r\n        cache: \"poetry\"\r\n        allow-partial-restores: true\r\n```\r\n\r\nHere's a configuration roughly equivalent to what I'm proposing here (the cache key is slightly different, but the idea is the same)\r\n\r\n```yaml\r\n    - uses: actions/setup-python@v4\r\n      id: setup-python\r\n      with:\r\n        python-version: \"3.10\"\r\n    - uses: actions/cache@v3\r\n      with:\r\n        path: /home/runner/.cache/pypoetry/virtualenvs\r\n        key: poetry-${{ steps.setup-python.outputs.python-version }}-${{ hashFiles('poetry.lock') }}\r\n        restore-keys: |\r\n          poetry-${{ steps.setup-python.outputs.python-version }}-${{ hashFiles('poetry.lock') }}\r\n          poetry-${{ steps.setup-python.outputs.python-version }}-\r\n```\r\n\r\nWe could also expose cache key management to the users through an input parameter, but that seems much more complex and brittle.\r\n\r\n**Justification:**\r\n\r\nThis change can represent a significant performance improvement on lockfile change, easily several minutes, depending on the project.\r\n\r\n**Are you willing to submit a PR?**\r\nNot at the time, as I have a working workaround (presented above).","author":{"url":"https://github.com/toadjaune","@type":"Person","name":"toadjaune"},"datePublished":"2023-03-15T16:27:45.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":4},"url":"https://github.com/627/setup-python/issues/627"}

route-pattern/_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format)
route-controllervoltron_issues_fragments
route-actionissue_layout
fetch-noncev2:40671554-7fa9-cb17-6e8e-e7cbbeed246f
current-catalog-service-hash81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114
request-idE4EE:150E55:10C209F:10FDE7D:6A4D552E
html-safe-nonce368217a1dc8504487011c0b0f852a1155b34ed77f40c48a79ce0f688dcab4ac9
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJFNEVFOjE1MEU1NToxMEMyMDlGOjEwRkRFN0Q6NkE0RDU1MkUiLCJ2aXNpdG9yX2lkIjoiMzQ5MjIxNDM0Njg0MTY3NDcxIiwicmVnaW9uX2VkZ2UiOiJzZWEiLCJyZWdpb25fcmVuZGVyIjoic2VhIn0=
visitor-hmac63be6561ecbb4c924dcbe139430d0f6b1821d7944ee3cce28c6c2f7da9af1f54
hovercard-subject-tagissue:1625859125
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/627/issue_layout
twitter:imagehttps://opengraph.githubassets.com/d313737a1a61c07301696dbb43be6b36fff9fb7cdd112eabd3a7e0879b47f914/actions/setup-python/issues/627
twitter:cardsummary_large_image
og:imagehttps://opengraph.githubassets.com/d313737a1a61c07301696dbb43be6b36fff9fb7cdd112eabd3a7e0879b47f914/actions/setup-python/issues/627
og:image:altDescription: When restoring cache, the current cache management system only uses the primary cache key. GitHub Actions cache allows specifying multiple prefixes, and restoring older caches, to spee...
og:image:width1200
og:image:height600
og:site_nameGitHub
og:typeobject
og:author:usernametoadjaune
hostnamegithub.com
expected-hostnamegithub.com
None92571a8944142227b7e19cd10918b1ddd06e5066c1ad5bc7e4769cf6140a87e6
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
release56fc8347865a14e2ec811533d68f929cf4e0ec19
ui-targetfull
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://github.com/actions/setup-python/issues/627#start-of-content
https://github.com/
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Factions%2Fsetup-python%2Fissues%2F627
GitHub CopilotWrite better code with AIhttps://github.com/features/copilot
GitHub Copilot appDirect agents from issue to mergehttps://github.com/features/ai/github-app
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
View all resourceshttps://github.com/resources
GitHub SponsorsFund open source developershttps://github.com/sponsors
Security Labhttps://securitylab.github.com
Maintainer Communityhttps://maintainers.github.com
Acceleratorhttps://github.com/accelerator
GitHub Starshttps://stars.github.com
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%2F627
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/627
Reloadhttps://github.com/actions/setup-python/issues/627
Reloadhttps://github.com/actions/setup-python/issues/627
Please reload this pagehttps://github.com/actions/setup-python/issues/627
actions https://github.com/actions
setup-pythonhttps://github.com/actions/setup-python
Notifications https://github.com/login?return_to=%2Factions%2Fsetup-python
Fork 726 https://github.com/login?return_to=%2Factions%2Fsetup-python
Star 2.2k https://github.com/login?return_to=%2Factions%2Fsetup-python
Code https://github.com/actions/setup-python
Issues 43 https://github.com/actions/setup-python/issues
Pull requests 33 https://github.com/actions/setup-python/pulls
Actions https://github.com/actions/setup-python/actions
Projects https://github.com/actions/setup-python/projects
Security and quality 0 https://github.com/actions/setup-python/security
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 and quality https://github.com/actions/setup-python/security
Insights https://github.com/actions/setup-python/pulse
Allow partial cache keyshttps://github.com/actions/setup-python/issues/627#top
feature requestNew feature or request to improve the current logichttps://github.com/actions/setup-python/issues?q=state%3Aopen%20label%3A%22feature%20request%22
https://github.com/toadjaune
toadjaunehttps://github.com/toadjaune
on Mar 15, 2023https://github.com/actions/setup-python/issues/627#issue-1625859125
corresponding documentationhttps://docs.github.com/en/actions/using-workflows/caching-dependencies-to-speed-up-workflows#matching-a-cache-key
feature requestNew feature or request to improve the current logichttps://github.com/actions/setup-python/issues?q=state%3Aopen%20label%3A%22feature%20request%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.