Skip to content

fix(build-dependency-cache): unset an empty region the restore ran without (SC-88184) - #24

Merged
samidalouche merged 1 commit into
mainfrom
fix/sc-88184/build-dependency-cache-drop-an-empty-region
Nov 24, 2026
Merged

samidalouche merged 1 commit into
mainfrom
fix/sc-88184/build-dependency-cache-drop-an-empty-region

Conversation

@samidalouche

Copy link
Copy Markdown
Contributor

Story

SC-88184: CI, keep sbt's, mise's and uv's caches in S3. A follow-up to #22.

What and why

Testing

  • tests/s3-cache.test.js: a save unsets a region that was unset when the restore ran; the 11 earlier tests still pass.
  • With the region unset and the credentials empty, aws s3api head-object goes on to look for credentials instead of failing on the endpoint.
  • After the release, narrative-connectors' global - dependency-graph on main should log saved … or … is already saved.

🤖 Generated with Claude Code

…thout (SC-88184)

v1.2.1 has the save take back the region its restore ran with, after configure-aws-credentials' post step sets
AWS_REGION and AWS_DEFAULT_REGION to "". It didn't cover a job that sets no region before the cache step and
configures credentials after it, as narrative-connectors' global-dependency-graph does: the restore ran with the region
unset, which the aws CLI resolves itself (it restored 5.47 GiB), so there was nothing to keep, and the save still got ""
and failed with "Invalid endpoint: https://s3..amazonaws.com".

- s3-cache.js: the save sees the region as the restore did. Each region variable that's now empty is set back to the
  restore's value, or unset when the restore had none.
- tests/s3-cache.test.js: a save unsets a region that was unset when the restore ran.
- README.md says so.

With the region unset and the credentials empty, `aws s3api head-object` goes on to look for credentials, as it does
with the region set, instead of failing on the endpoint.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@samidalouche
samidalouche merged commit 86abe13 into main Nov 24, 2026
3 checks passed
@samidalouche
samidalouche deleted the fix/sc-88184/build-dependency-cache-drop-an-empty-region branch November 24, 2026 21:48
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