Skip to content

ci: run the release jobs in a release environment - #1226

Merged
thomson-t merged 1 commit into
mainfrom
ci/run-the-release-jobs-in-a-release-environment
Nov 17, 2026
Merged

thomson-t merged 1 commit into
mainfrom
ci/run-the-release-jobs-in-a-release-environment

Conversation

@nickolas-dimitrakas

Copy link
Copy Markdown
Contributor

Why

Release automation should hold release credentials only where releases run. Release jobs read their signing, publishing and GitHub App credentials from repository- and organization-level secrets, which every workflow on every branch can read.

Programme

Standalone change, no programme.

What changes

  • The Release – Publish jobs that sign, mirror, release and push to CocoaPods, and the Release Draft job, run in the release environment, which allows only main.
  • A secret not yet set in the environment still resolves from the repository or organization, so promoting this before the secrets move breaks nothing.

No changelog entry, because nothing in the published package changes.

Linked work

Related: the same change in ROKT/rokt-sdk-react-native#336.

Rollout

Path: CI only; nothing is published.

  1. Before merging: the release environment allows only main and holds the credentials.
  2. Merge, then run Release – Publish with dry_run from main; it covers signing and the GitHub App. The next release covers the CocoaPods token.
  3. Remove the repository-level copies that nothing reads any more.

Feature flags: none.
Turning it off: revert this pull request.
What we watch: the dry run succeeds, and the next release's CocoaPods jobs push without the trunk warning.

Risks

  • A credential added to the environment with a wrong value overrides the repository copy; the next run fails at the step that uses it; the value is fixed or removed from the environment.

Risk class: low.

Who

Written by: an automated coding agent (Claude Code), at an engineer's request.
Code reviewed before opening: an independent review agent; no person yet.
Checked: the changed workflows pass actionlint, and the environment's rule was read back through the GitHub API.
Not checked: a run on a real runner, which the next run after merging covers.

Size

Hand-written: 2 files, 5 lines added.
Generated: none.

@nickolas-dimitrakas nickolas-dimitrakas self-assigned this Nov 17, 2026
@github-actions

Copy link
Copy Markdown

🐦 Swift Migration Progress

Production implementation code at 8c2a7b707350 compared with 828d537d5d3d.

Area Goal Progress Base This PR Swift SLOC Objective-C remaining Change
Core SDK Short term — in scope ██████████ 100.00% 100.00% 16,211 0 ➖ 0.00 pp
Core SDK Long term — all Objective-C ███████░░░ 69.46% 69.46% 16,211 7,126 ➖ 0.00 pp
SDK kit infrastructure Short term — in scope ██████████ 100.00% 100.00% 2,404 0 ➖ 0.00 pp
SDK kit infrastructure Long term — all Objective-C ████▉░░░░░ 48.19% 48.19% 2,404 2,585 ➖ 0.00 pp
Standalone kits Short term — in scope ▊░░░░░░░░░ 7.10% 7.10% 1,210 15,831 ➖ 0.00 pp
Standalone kits Long term — all Objective-C ▊░░░░░░░░░ 7.10% 7.10% 1,210 15,831 ➖ 0.00 pp

Objective-C retained by design: Core SDK 7,126 · SDK kit infrastructure 2,585 · Standalone kits 0.

This PR's code movement

Area Swift lines added Objective-C lines removed
Core SDK 0 0
SDK kit infrastructure 0 0
Standalone kits 0 0
How this is measured
  • Current composition uses production source lines of code (SLOC) from cloc; comments and blank lines are excluded.
  • Short term — in scope excludes the Objective-C the migration will not delete, so 100% completes the in-scope conversions: every in-scope implementation gone. Migration continues on main after the integration branch merge.
  • Long term — all Objective-C keeps the full denominator. Reaching 100% there means the public API itself becomes Swift, which is a breaking change reserved for a future major release.
  • The gap between the two rows is the retained public/kit contract, runtime-identity, and boundary-glue surface listed in Tools/swift-migration-retained-objc.txt.
  • Retained wrappers keep their Objective-C interface but still shed logic to Swift. That thinning moves the long-term row and the retained figure, not the short-term row.
  • Both revisions are measured with the manifest from the head revision, so a manifest edit does not by itself move the reported change. A retained file this pull request renamed or deleted still counts as retained at the base.
  • Pull request movement uses physical additions/deletions from git diff base...head --numstat; it counts retained files too and is intentionally separate from SLOC totals.
  • Core excludes SDK kit infrastructure and vendored libraries. Standalone kits include only files below Kits/**/Sources.
  • Tests, examples, headers, build outputs, vendored libraries, and the MParticle/Sources Swift overlay are excluded.
  • Objective-C++ (.mm) is included in the Objective-C figures and removed counts.

Generated with cloc 2.10. This report is informational and does not gate migration direction.

@nickolas-dimitrakas
nickolas-dimitrakas marked this pull request as ready for review November 17, 2026 04:53
@nickolas-dimitrakas
nickolas-dimitrakas requested a review from a team as a code owner November 17, 2026 04:53
@github-actions

Copy link
Copy Markdown

📦 SDK Size Impact Report

Measures how much the SDK adds to an app's size (with-SDK minus without-SDK).

Metric Target Branch This PR Change
App Bundle Impact 2.71 MB 2.72 MB +16 KB
Executable Impact 848 bytes 848 bytes +N/A
Framework binary (ships) 2.95 MB 2.96 MB +16 KB

mParticle Core + Rokt kit

The SDK and the Rokt kit built from source by SwiftPM and linked statically, as a
SwiftPM app takes them. Kit on top of the SDK is measured against the SDK built
the same way. Both sides resolve the same Rokt SDK versions, the latest the kit allows.
Report-only: the size budget applies to the core number above.

Metric Target Branch This PR Change
App Bundle Impact 8.00 MB 8.00 MB +0 KB
Kit on top of the SDK 5.68 MB 5.68 MB +0 KB

➡️ SDK size impact change is minimal.

Where the bytes are

Component Target branch This PR Change
Executable code (__text) 1251.7 KB 1250.8 KB -0.8 KB
Swift metadata (__swift5_*) 66.1 KB 66.1 KB +0.0 KB
ObjC metadata (__objc_*) 376.3 KB 376.3 KB +0.0 KB
Symbol tables (__LINKEDIT) 768.0 KB 768.0 KB +0.0 KB
Mach-O images 2 2 +0
Exported symbols 5841 5841 +0
Debug symbols (not shipped to users)

The SDK is embedded as a dynamic framework, so the app's own executable barely
moves and App Bundle Impact is the number that tracks shipped code.
xcodebuild -create-xcframework folds the dSYM in beside the framework, so the
xcframework total is mostly debug symbols and is not a shipping cost.

Target Branch This PR
dSYMs 3.32 MB 3.32 MB
XCFramework total 6.27 MB 6.29 MB
Raw measurements

Target branch (main):

{"baseline_app_size_kb":84,"baseline_executable_size_bytes":75464,"with_sdk_app_size_kb":2856,"with_sdk_executable_size_bytes":76312,"sdk_impact_kb":2772,"sdk_executable_impact_bytes":848,"xcframework_size_kb":6420,"framework_size_kb":3020,"dsym_size_kb":3396,"core_source_app_size_kb":2456,"kit_app_size_kb":8276,"kit_executable_size_bytes":8439856,"kit_impact_kb":8192,"kit_over_core_kb":5820}

This PR:

{"baseline_app_size_kb":84,"baseline_executable_size_bytes":75464,"with_sdk_app_size_kb":2872,"with_sdk_executable_size_bytes":76312,"sdk_impact_kb":2788,"sdk_executable_impact_bytes":848,"xcframework_size_kb":6436,"framework_size_kb":3036,"dsym_size_kb":3396,"core_source_app_size_kb":2456,"kit_app_size_kb":8276,"kit_executable_size_bytes":8439856,"kit_impact_kb":8192,"kit_over_core_kb":5820}

@thomson-t thomson-t left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changing the publish environment

@thomson-t
thomson-t merged commit d981649 into main Nov 17, 2026
87 checks passed
@thomson-t
thomson-t deleted the ci/run-the-release-jobs-in-a-release-environment branch November 17, 2026 16:04
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.

2 participants