Skip to content

chore!: raise minimum macOS to 11, tvOS to 15 and watchOS to 10 - #906

Merged
turnipdabeets merged 2 commits into
chore/v4-remove-deprecatedfrom
chore/v4-raise-apple-platform-minimums
Oct 6, 2026
Merged

turnipdabeets merged 2 commits into
chore/v4-remove-deprecatedfrom
chore/v4-raise-apple-platform-minimums

Conversation

@turnipdabeets

@turnipdabeets turnipdabeets commented Oct 5, 2026 •

Copy link
Copy Markdown
Contributor

💡 Motivation and Context

Part of the 4.0 stack, on top of #898 (Xcode 26) and #876 (iOS 15).

Raises the minimum deployment targets to macOS 11, tvOS 15, watchOS 10. iOS stays 15, visionOS stays 1.0, Mac Catalyst follows iOS (15).

Why: #898 makes Xcode 26 the minimum toolchain, and Xcode 26 supports deployment targets of "iOS 15–26 · tvOS 15–26 · watchOS 8-26 · visionOS 1–26 · macOS 11-26" (Apple). Our current macOS 10.15 / tvOS 13 / watchOS 6 floors are below what the required toolchain supports, so they're support claims we can't build or test. Xcode 26.4.1 still compiles a package declaring them without a warning, and Xcode 27 silently clamps macOS to 12.

What peers do (default-branch Package.swift, 2026-10-05)

SDK macOS tvOS watchOS Last bump
Sentry 12 15 9 9.25.0, Jul 2026 ("Xcode 27 no longer supports earlier versions")
Datadog 12 15 9 3.17–3.19, Aug–Sep 2026
LaunchDarkly 12 15 9 11.6.2, Sep 2026 (for Xcode 27)
Firebase (main, v13 RC) 11 15 8 Sep 2026
Amplitude, Segment, RevenueCat, Mixpanel, Bugsnag, Statsig ≤10.15 ≤13 ≤7 2022–2024, no recent bump

macOS and tvOS match Firebase and the Xcode 26 floor. watchOS goes to 10, past the Xcode 26 floor of 8, because no posthog-ios events came from watchOS 9 or earlier (see below), and watchOS 10 runs on the same hardware as watchOS 9 (Apple Watch Series 4 and later). macOS stays at 11 rather than Xcode 27's 12 because macOS 11 still sends events, and 4.0 doesn't require Xcode 27. tvOS stays at 15 for the same reason: tvOS 15 and 16 still send events.

Who this affects

  • tvOS: no hardware is dropped. tvOS 26 still runs on the Apple TV HD (2015), the oldest device that runs tvOS 13.

  • Customer data (last 30 days, US and EU Cloud, events with $lib = 'posthog-ios'):

    Dropped range Events Projects
    macOS 10.15 4 (from one user) 1
    tvOS 13–14 0 0
    watchOS 6–9 0 0

    The oldest versions still sending events are macOS 11 (under 0.01% of macOS events), tvOS 15 and watchOS 10, all of which this PR keeps supporting.

Wrapper SDKs

Nothing downstream depends on our tvOS or watchOS floors. The macOS floor reaches the wrappers that support macOS, which would need macOS 11 when they adopt 4.0:

Wrapper macOS today
posthog-flutter 10.15; PostHog/posthog-flutter#637 (adopts 4.0) raises it to 11
React Native plugin osx 10.15; PostHog/posthog-js#5194 (plugin 3.0) raises it to 11
posthog-kmp 10.15 (macosArm64)

What changed

  • Targets: Package.swift, PostHog.podspec, PostHog.xcodeproj (SDK, test and example targets), the downgrade-compatibility smoke package, AGENTS.md.
  • Availability cleanup: 28 checks removed (14 in the SDK, 14 in tests), with 3 dead else branches. Examples: the watchOS 7 WKApplication notification checks, the macOS 11 push-open checks, isiOSAppOnMac. The macOS 13 / tvOS 16 checks stay. The $locale check still names watchOS 9, which is now always true, but it shares the check with iOS 16.
  • Changesets: new v4-raise-apple-platform-minimums.md (major). The "macOS/tvOS/watchOS minimums are unchanged" line in chore!: raise minimum iOS deployment target to 15 #876's changeset is removed so the 4.0 changelog doesn't contradict itself.

Public API change: no symbols change; the API snapshot has no diff.

💚 How did you test it?

  • swift build --build-tests: no warnings in PostHog/.
  • swift test (macOS): XCTest 169 tests, 0 failures. Swift Testing 961 tests with 13 issues, all the PostHogStorageTest group-container cases that fail the same way on the base commit on this machine.
  • make apiCheck: snapshot up to date.
  • xcodebuild build for iOS, macOS, Mac Catalyst, tvOS, watchOS and visionOS: all succeed. Every warning is in vendor/PHPLCrashReporter, matching a base build.
  • make lint: no new warnings.
  • Not run: example app builds, the iOS simulator suite (CI covers it), and running on real macOS 11 / tvOS 15 / watchOS 10 devices.

📝 Checklist

  • I reviewed the submitted code.
  • I added tests to verify the changes.
  • I updated the docs if needed.
  • No breaking change or entry added to the changelog.

If releasing new changes

  • Ran pnpm changeset to generate a changeset file

The changeset is major and was written by hand.

🤖 Agent context

Autonomy: Human-driven (agent-assisted)

  • Written with Claude Code (Opus 5.5). Peer floors, Apple's Xcode table and the customer counts were gathered in the same session.

🤖 Generated with Claude Code

@turnipdabeets turnipdabeets self-assigned this Oct 5, 2026
@greptile-apps

greptile-apps Bot commented Oct 5, 2026 •

Copy link
Copy Markdown
Contributor

Retrigger

[High risk] Raises minimum deployment targets across Apple platforms.

The PR appears safe to merge based on the changes since the previous review.

Reviews (2) · Last reviewed commit: "chore!: raise minimum watchOS to 10"

@github-actions

github-actions Bot commented Oct 5, 2026 •

Copy link
Copy Markdown
Contributor

posthog-ios Compliance Report

Date: 2026-10-05 23:10:23 UTC
Duration: 204877ms

⚠️ Some Tests Failed

44/45 tests passed, 1 failed


Capture Tests

⚠️ 28/29 tests passed, 1 failed

View Details
Test Status Duration
Format Validation.Event Has Required Fields ✅ 2957ms
Format Validation.Event Has Uuid ✅ 2855ms
Format Validation.Event Has Lib Properties ✅ 2778ms
Format Validation.Distinct Id Is String ✅ 2981ms
Format Validation.Token Is Present ✅ 2862ms
Format Validation.Custom Properties Preserved ✅ 2816ms
Format Validation.Event Has Timestamp ✅ 2724ms
Retry Behavior.Retries On 503 ✅ 5518ms
Retry Behavior.Does Not Retry On 400 ✅ 2352ms
Retry Behavior.Does Not Retry On 401 ✅ 2441ms
Retry Behavior.Respects Retry After Header ✅ 5408ms
Retry Behavior.Implements Backoff ✅ 21179ms
Retry Behavior.Retries On 500 ✅ 5502ms
Retry Behavior.Retries On 502 ✅ 9277ms
Retry Behavior.Retries On 504 ✅ 9413ms
Retry Behavior.Max Retries Respected ❌ 15439ms
Deduplication.Generates Unique Uuids ✅ 2919ms
Deduplication.Preserves Uuid On Retry ✅ 9294ms
Deduplication.Preserves Uuid And Timestamp On Retry ✅ 16368ms
Deduplication.Preserves Uuid And Timestamp On Batch Retry ✅ 8338ms
Deduplication.No Duplicate Events In Batch ✅ 2957ms
Deduplication.Different Events Have Different Uuids ✅ 2719ms
Compression.Sends Gzip When Enabled ✅ 415ms
Batch Format.Uses Proper Batch Structure ✅ 421ms
Batch Format.Flush With No Events Sends Nothing ✅ 305ms
Batch Format.Multiple Events Batched Together ✅ 3065ms
Error Handling.Does Not Retry On 403 ✅ 4668ms
Error Handling.Does Not Retry On 413 ✅ 2418ms
Error Handling.Retries On 408 ✅ 8808ms

Failures

retry_behavior.max_retries_respected

Expected 4 requests, got 5

Feature_Flags Tests

✅ 16/16 tests passed

View Details
Test Status Duration
Request Payload.Request With Person Properties Device Id ✅ 2732ms
Request Payload.Flags Request Uses V2 Query Param ✅ 2802ms
Request Payload.Flags Request Hits Flags Path Not Decide ✅ 2760ms
Request Payload.Flags Request Omits Authorization Header ✅ 2683ms
Request Payload.Token In Flags Body Matches Init ✅ 2793ms
Request Payload.Groups Round Trip ✅ 2770ms
Request Payload.Groups Default To Empty Object ✅ 2817ms
Request Payload.Person Properties Distinct Id Auto Populated When Caller Omits It ✅ 2905ms
Request Payload.Disable Geoip False Propagates As Geoip Disable False ✅ 2872ms
Request Payload.Disable Geoip Omitted Defaults To False ✅ 2878ms
Request Payload.Flag Keys To Evaluate Contains Only Requested Key ✅ 2739ms
Request Lifecycle.No Flags Request On Init Alone ✅ 95ms
Request Lifecycle.No Flags Request On Normal Capture ✅ 2705ms
Request Lifecycle.Two Flag Calls Produce Two Remote Requests ✅ 5395ms
Request Lifecycle.Mock Response Value Is Returned To Caller ✅ 2771ms
Side Effect Events.Get Feature Flag Captures Feature Flag Called Event ✅ 2966ms

turnipdabeets added a commit to PostHog/posthog-js that referenced this pull request Oct 5, 2026
posthog-ios 4.0 raises its macOS minimum to 11 (PostHog/posthog-ios#906).

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
turnipdabeets added a commit to PostHog/posthog-flutter that referenced this pull request Oct 5, 2026
posthog-ios 4.0 raises its macOS minimum to 11 (PostHog/posthog-ios#906).
Also drops the macOS 11 / iOS 14 availability check that is now always true.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@turnipdabeets turnipdabeets changed the title chore!: raise minimum macOS to 11, tvOS to 15 and watchOS to 8 chore!: raise minimum macOS to 11, tvOS to 15 and watchOS to 10 Oct 5, 2026
@turnipdabeets
turnipdabeets marked this pull request as ready for review October 5, 2026 20:39
@turnipdabeets
turnipdabeets requested a review from a team as a code owner October 5, 2026 20:39
@turnipdabeets
turnipdabeets force-pushed the chore/v4-swift-tools-6 branch from 3c380b4 to 4352748 Compare October 5, 2026 22:48
Base automatically changed from chore/v4-swift-tools-6 to chore/v4-remove-deprecated October 5, 2026 22:54
turnipdabeets and others added 2 commits October 5, 2026 18:55
Xcode 26, which the package now requires, supports deployment targets
down to macOS 11, tvOS 15 and watchOS 8, so the old 10.15 / 13 / 6
floors could no longer be built or tested. Raise them in Package.swift,
the podspec, PostHog.xcodeproj and the downgrade smoke package, and
remove the availability checks and fallbacks the new floors make dead.
iOS 15, Mac Catalyst and visionOS 1 are unchanged.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
No posthog-ios events came from watchOS 9 or earlier in the last 30 days
on US or EU Cloud, and watchOS 10 supports the same hardware as watchOS 9
(Apple Watch Series 4 and later).

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@turnipdabeets
turnipdabeets merged commit ba2031f into chore/v4-remove-deprecated Oct 6, 2026
43 checks passed
@turnipdabeets
turnipdabeets deleted the chore/v4-raise-apple-platform-minimums branch October 6, 2026 17:37
turnipdabeets added a commit that referenced this pull request Oct 7, 2026
* chore!: raise minimum macOS to 11, tvOS to 15 and watchOS to 8

Xcode 26, which the package now requires, supports deployment targets
down to macOS 11, tvOS 15 and watchOS 8, so the old 10.15 / 13 / 6
floors could no longer be built or tested. Raise them in Package.swift,
the podspec, PostHog.xcodeproj and the downgrade smoke package, and
remove the availability checks and fallbacks the new floors make dead.
iOS 15, Mac Catalyst and visionOS 1 are unchanged.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>

* chore!: raise minimum watchOS to 10

No posthog-ios events came from watchOS 9 or earlier in the last 30 days
on US or EU Cloud, and watchOS 10 supports the same hardware as watchOS 9
(Apple Watch Series 4 and later).

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
turnipdabeets added a commit that referenced this pull request Oct 9, 2026
* chore!: raise minimum macOS to 11, tvOS to 15 and watchOS to 8

Xcode 26, which the package now requires, supports deployment targets
down to macOS 11, tvOS 15 and watchOS 8, so the old 10.15 / 13 / 6
floors could no longer be built or tested. Raise them in Package.swift,
the podspec, PostHog.xcodeproj and the downgrade smoke package, and
remove the availability checks and fallbacks the new floors make dead.
iOS 15, Mac Catalyst and visionOS 1 are unchanged.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>

* chore!: raise minimum watchOS to 10

No posthog-ios events came from watchOS 9 or earlier in the last 30 days
on US or EU Cloud, and watchOS 10 supports the same hardware as watchOS 9
(Apple Watch Series 4 and later).

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 5.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.

2 participants