Skip to content

ci(shared-core): resolve the framework over the unauthenticated download URL - #1391

Merged
bmc08gt merged 1 commit into
code/cashfrom
ci/shared-core-download-url
Sep 2, 2026
Merged

ci(shared-core): resolve the framework over the unauthenticated download URL#1391
bmc08gt merged 1 commit into
code/cashfrom
ci/shared-core-download-url

Conversation

@bmc08gt

@bmc08gt bmc08gt commented Sep 1, 2026

Copy link
Copy Markdown
Collaborator

The 0.4.0 publish run failed at its own verify step:

failed downloading 'https://api.github.com/repos/code-payments/flipcash-shared-core-spm/releases/assets/540211749.zip'
which is required by binary target 'SharedCore': badResponseStatusCode(403)

KMMBridge points the binary target at the release asset's API URL. That endpoint serves private repos, but it rate limits unauthenticated callers to 60 requests an hour per IP — which is what a shared macOS runner, or a developer resolving the package, hits. flipcash-shared-core-spm is public, so github.com/<repo>/releases/download/<tag>/SharedCore.xcframework.zip serves the same bytes with no limit and no credentials.

This step already existed: it was written for the 0.3.1 publish, which was dispatched from feat/shared-badge-cgpath. That branch never opened a PR, so code/cash has never carried the fix and the next publish from code/cash was the first to hit it. The workflow file here is byte-identical to the one 0.3.1 published from.

After the rewrite the step greps the URL back out of Package.swift and curl -Is it, so a wrong tag or a missing asset fails before the tag moves.

Fallout to clean up separately

Tag 0.4.0 and release 0.4.0 exist in flipcash-shared-core-spm — the release upload creates them before the verify step runs. Because "Commit and tag the Swift Package" was skipped, the tag still points at 5b1a6e83 ("SharedCore 0.3.1"), so 0.4.0 currently resolves to the 0.3.1 binary. It has to be deleted and re-cut, or skipped in favour of 0.4.1, before anything depends on it.

…oad URL

KMMBridge writes the release asset's API URL into `Package.swift`, and
`api.github.com` rate limits unauthenticated callers to 60 requests an hour per
IP. The 0.4.0 publish failed its own verify step on that limit:

    failed downloading '.../releases/assets/540211749.zip' which is required by
    binary target 'SharedCore': badResponseStatusCode(403)

The repo is public, so `github.com/.../releases/download/<tag>/...` serves the
same bytes with no limit and no credentials. Rewrite the variable to that form
after the upload, then check the URL is in the file and that it resolves.

This step was written for the 0.3.1 publish but was only ever run from an
unmerged branch, so `code/cash` has never had it.
@bmc08gt
bmc08gt requested a review from jeffyanta as a code owner September 1, 2026 22:14
@bmc08gt bmc08gt self-assigned this Sep 1, 2026
@bmc08gt
bmc08gt merged commit 82c2fdb into code/cash Sep 2, 2026
3 checks passed
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