Skip to content

Remove the cache machinery left behind when caching was dropped - #6

Open
jolierabideau wants to merge 1 commit into
sync-retryfrom
remove-vestigial-cache-code
Open

jolierabideau wants to merge 1 commit into
sync-retryfrom
remove-vestigial-cache-code

Conversation

@jolierabideau

@jolierabideau jolierabideau commented Sep 10, 2026

Copy link
Copy Markdown

Problem

d88e189 removed the caching step from action.yaml, but the code and documentation supporting it stayed behind:

  • cache_key() has no remaining caller.
  • configure_macports still wrote a cache-key entry to $GITHUB_OUTPUT. action.yaml does not declare such an output, so nothing could read it. That line also carried a typo inherited from upstream (3ab7103, pre-fork): printf 'cache-key=%sn\n' appended a stray n to every key. Still live upstream, where it does matter.
  • The macos variable in main() existed only to build the cache key — likewise package, which was never used.
  • README.md advertised "the caching of an installation" in its opening paragraph and kept a ## Cache scopes section describing behaviour this action no longer has.

Change

Delete all of it. No behaviour change: none of it was reachable, and the three outputs action.yaml actually declares — package, prefix, version — are all still written. I cross-checked declared outputs against emitted ones.

parameters is also emitted without being declared, but that predates and is unrelated to caching, so I left it alone.

Verification

  • sh -n configure_macports passes
  • Full testsuite passes locally (macos, macports, failwith)
  • Declared outputs vs. emitted outputs cross-checked

Why this is based on sync-retry

Stacked on #4 (which is itself stacked on #5) so CI can actually go green. Based on main this would fail for two reasons that have nothing to do with it — the stale port version assertion (#5) and the silent ports-tree sync failure (#4). Review order: #5, then #4, then this. GitHub retargets each automatically as its parent merges.

If you would rather merge this independently of the other two, say so and I will retarget it to main; just expect its CI to be red until those land.

Context

Found while auditing melusina-org/setup-macports for changes worth carrying over. Three of upstream's four commits since the fork are caching work that does not apply here, and this is the code they would have touched. Worth noting for the future: upstream's 8326514 fixes the cache key to account for architecture (x86_64 vs arm64 were being conflated) and adds a probe_architecture helper — both worth taking if caching is ever restored.

🤖 Generated with Claude Code


This change is Reviewable

d88e189 removed the caching step from action.yaml, but the code and
documentation supporting it stayed:

- cache_key() had no remaining caller.
- configure_macports still wrote a cache-key entry to GITHUB_OUTPUT,
  and action.yaml does not declare such an output, so nothing could
  read it. That line also carried a typo inherited from upstream,
  `printf 'cache-key=%sn\n'`, which appended a stray "n" to every key.
- The macos variable in main() existed only to build the cache key.
- README.md advertised "the caching of an installation" and kept a
  "Cache scopes" section describing behaviour the action no longer has.

None of this was reachable, so there is no behaviour change: the three
outputs action.yaml declares — package, prefix and version — are all
still written.

Should caching ever be restored, note that upstream has since fixed the
cache key to account for the architecture, in melusina-org/setup-macports
8326514, along with a probe_architecture helper worth taking at the same
time.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant