Skip to content

Vendor hex_core v0.21.0 - #1283

Merged
ericmj merged 2 commits into
mainfrom
vendor-hex-core-v0.21.0
Oct 21, 2026
Merged

ericmj merged 2 commits into
mainfrom
vendor-hex-core-v0.21.0

Conversation

@ericmj

@ericmj ericmj commented Oct 21, 2026

Copy link
Copy Markdown
Member

Vendors hex_core v0.21.0 with scripts/vendor_hex_core.sh.

hex_core now only asks the CI provider for an OIDC token for the configured audience, and returns {oidc_audience_not_allowed, Audience} when the API advertises another one (hexpm/hex_core#247). Hex.WorkloadIdentity describes that error, which raised FunctionClauseError before. The new workload_identity_audience config, overridden by HEX_WORKLOAD_IDENTITY_AUDIENCE, sets the audience, hexpm by default, for an api_url that points to a Hex server using another one.

hex_core also renews a token and retries when the server answers 401 with error="invalid_token", which hex.pm sends since hexpm/hexpm#2061 (hexpm/hex_core#244). It recognized only error="token_expired" before, which hex.pm never sends. In Hex this refreshes the mix hex.user auth session, and exchanges again a short-lived token from an organization key or Workload Identity.

The changelog gets entries for both, and the Workload Identity entry and the mix hex.publish docs now say that an organization's write workload identities with public packages publish the public packages it owns (hexpm/hexpm#2064).

hex_core v0.21.0 only requests the CI job's OIDC token for the
`hexpm` audience and returns `{oidc_audience_not_allowed, Audience}`
when the API advertises another one. Describe that error instead of
raising FunctionClauseError in Hex.WorkloadIdentity.describe/2.
The workload_identity_audience config, overridden by
HEX_WORKLOAD_IDENTITY_AUDIENCE, sets the audience Workload Identity
requests the OIDC token for, `hexpm` by default, so Workload Identity
works with an api_url that points to a Hex server using another
audience.

Add the changelog entries for hex_core v0.21.0, and say in the
changelog and the mix hex.publish docs that an organization's write
workload identities can publish the public packages it owns.
@ericmj
ericmj merged commit c58244c into main Oct 21, 2026
15 checks passed
@ericmj
ericmj deleted the vendor-hex-core-v0.21.0 branch October 21, 2026 13:38
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