From 52a33410efea146ed87fbc79699e57d96f39e5dc Mon Sep 17 00:00:00 2001 From: TheNoumanDev Date: Sun, 13 Sep 2026 19:42:55 +0500 Subject: [PATCH 1/2] fix(firebase_core_tvos): regenerate Pigeon for the 14-element payload and drop the interface pin --- packages/firebase_core_tvos/CHANGELOG.md | 21 +++++++++++++++++++ packages/firebase_core_tvos/README.md | 4 ++-- packages/firebase_core_tvos/pubspec.yaml | 16 ++++++-------- .../tvos/Classes/FLTFirebaseCorePlugin.m | 2 -- .../include/firebase_core/messages.g.h | 4 +--- .../tvos/Classes/messages.g.m | 10 ++------- .../tvos/firebase_core_tvos.podspec | 2 +- 7 files changed, 33 insertions(+), 26 deletions(-) diff --git a/packages/firebase_core_tvos/CHANGELOG.md b/packages/firebase_core_tvos/CHANGELOG.md index 127d875..d726852 100644 --- a/packages/firebase_core_tvos/CHANGELOG.md +++ b/packages/firebase_core_tvos/CHANGELOG.md @@ -1,3 +1,24 @@ +## 0.0.3 + +* Regenerate the native Pigeon sources against the 14-element `CoreFirebaseOptions` payload and + widen the `firebase_core_platform_interface` pin to `^8.1.0`. + + 8.1.0 dropped `recaptchaSiteKey`, shortening the payload from 15 elements to 14. The generated + code decoded index 14 through a bare `NSArray` subscript, so on 8.1.x + `Firebase.initializeApp(options: ...)` raised `NSRangeException` before any Dart ran. 0.0.2 + avoided that by pinning to the 15-element window; this release regenerates instead. + + Sources come from `firebase_core` 4.13.0 — the last release whose iOS implementation is still + Objective-C (4.14.0 rewrote it in Swift), and the first on the 14-element payload. The delta + against the previous files is exclusively `recaptchaSiteKey`. + + The pin is a caret, matching what `firebase_core` declares for itself. Arity moved only during + one add/remove cycle — 7.1.0 introduced `recaptchaSiteKey` for reCAPTCHA support that was + "gradually rolling out", and 8.1.0 withdrew it when that moved to the provider API — across 23 + published minor lines. + + **Breaking:** now requires `firebase_core >= 4.13.0`. + ## 0.0.2 * Constrain `firebase_core_platform_interface` to `>=7.1.0 <8.1.0`. diff --git a/packages/firebase_core_tvos/README.md b/packages/firebase_core_tvos/README.md index b76d31f..c5b8e34 100644 --- a/packages/firebase_core_tvos/README.md +++ b/packages/firebase_core_tvos/README.md @@ -15,8 +15,8 @@ it: ```yaml dependencies: - firebase_core: ^4.11.0 - firebase_core_tvos: ^0.0.2 + firebase_core: ^4.13.0 + firebase_core_tvos: ^0.0.3 ``` The native plugin registers automatically through flutter-tvos' plugin diff --git a/packages/firebase_core_tvos/pubspec.yaml b/packages/firebase_core_tvos/pubspec.yaml index 615142c..cb43ff0 100644 --- a/packages/firebase_core_tvos/pubspec.yaml +++ b/packages/firebase_core_tvos/pubspec.yaml @@ -2,7 +2,7 @@ name: firebase_core_tvos description: >- tvOS (Apple TV) implementation of the firebase_core Flutter plugin, enabling Firebase initialization on Apple TV via the flutter-tvos toolchain. -version: 0.0.2 +version: 0.0.3 homepage: https://fluttertv.dev repository: https://github.com/fluttertv/plugins/tree/main/packages/firebase_core_tvos issue_tracker: https://github.com/fluttertv/plugins/issues @@ -16,15 +16,11 @@ environment: dependencies: flutter: sdk: flutter - firebase_core: ^4.11.0 - # Pinned to the window where CoreFirebaseOptions is a 15-element Pigeon - # payload, which is what this package's generated native side decodes - # (tvos/Classes/messages.g.m reads index 14). 7.0.x and 8.1.0 send 14 - # elements — 8.1.0 dropped `recaptchaSiteKey` — so either end of this range - # makes Firebase.initializeApp(options: ...) read past the end of the list. - # Only 7.1.0 and 8.0.0 are compatible. Widening this requires regenerating - # the native Pigeon sources first. - firebase_core_platform_interface: ">=7.1.0 <8.1.0" + # First release targeting the 14-element payload; older ones expect 15. + firebase_core: ^4.13.0 + # Matches what firebase_core itself declares; messages.g.m decodes the 14-element + # CoreFirebaseOptions payload 8.1.0 settled on. + firebase_core_platform_interface: ^8.1.0 dev_dependencies: flutter_lints: ^4.0.0 diff --git a/packages/firebase_core_tvos/tvos/Classes/FLTFirebaseCorePlugin.m b/packages/firebase_core_tvos/tvos/Classes/FLTFirebaseCorePlugin.m index 192f984..23b3f7b 100644 --- a/packages/firebase_core_tvos/tvos/Classes/FLTFirebaseCorePlugin.m +++ b/packages/firebase_core_tvos/tvos/Classes/FLTFirebaseCorePlugin.m @@ -93,8 +93,6 @@ - (CoreFirebaseOptions *)optionsFromFIROptions:(FIROptions *)options { pigeonOptions.iosBundleId = (id)options.bundleID ?: [NSNull null]; pigeonOptions.iosClientId = (id)options.clientID ?: [NSNull null]; pigeonOptions.appGroupId = (id)options.appGroupID ?: [NSNull null]; - // recaptchaSiteKey is currently only exposed by Firebase JS options. - pigeonOptions.recaptchaSiteKey = [NSNull null]; return pigeonOptions; } diff --git a/packages/firebase_core_tvos/tvos/Classes/include/firebase_core/messages.g.h b/packages/firebase_core_tvos/tvos/Classes/include/firebase_core/messages.g.h index 561383c..913fdbb 100644 --- a/packages/firebase_core_tvos/tvos/Classes/include/firebase_core/messages.g.h +++ b/packages/firebase_core_tvos/tvos/Classes/include/firebase_core/messages.g.h @@ -32,8 +32,7 @@ NS_ASSUME_NONNULL_BEGIN androidClientId:(nullable NSString *)androidClientId iosClientId:(nullable NSString *)iosClientId iosBundleId:(nullable NSString *)iosBundleId - appGroupId:(nullable NSString *)appGroupId - recaptchaSiteKey:(nullable NSString *)recaptchaSiteKey; + appGroupId:(nullable NSString *)appGroupId; @property(nonatomic, copy) NSString *apiKey; @property(nonatomic, copy) NSString *appId; @property(nonatomic, copy) NSString *messagingSenderId; @@ -48,7 +47,6 @@ NS_ASSUME_NONNULL_BEGIN @property(nonatomic, copy, nullable) NSString *iosClientId; @property(nonatomic, copy, nullable) NSString *iosBundleId; @property(nonatomic, copy, nullable) NSString *appGroupId; -@property(nonatomic, copy, nullable) NSString *recaptchaSiteKey; @end @interface CoreInitializeResponse : NSObject diff --git a/packages/firebase_core_tvos/tvos/Classes/messages.g.m b/packages/firebase_core_tvos/tvos/Classes/messages.g.m index 4499443..b1a0a1e 100644 --- a/packages/firebase_core_tvos/tvos/Classes/messages.g.m +++ b/packages/firebase_core_tvos/tvos/Classes/messages.g.m @@ -143,8 +143,7 @@ + (instancetype)makeWithApiKey:(NSString *)apiKey androidClientId:(nullable NSString *)androidClientId iosClientId:(nullable NSString *)iosClientId iosBundleId:(nullable NSString *)iosBundleId - appGroupId:(nullable NSString *)appGroupId - recaptchaSiteKey:(nullable NSString *)recaptchaSiteKey { + appGroupId:(nullable NSString *)appGroupId { CoreFirebaseOptions *pigeonResult = [[CoreFirebaseOptions alloc] init]; pigeonResult.apiKey = apiKey; pigeonResult.appId = appId; @@ -160,7 +159,6 @@ + (instancetype)makeWithApiKey:(NSString *)apiKey pigeonResult.iosClientId = iosClientId; pigeonResult.iosBundleId = iosBundleId; pigeonResult.appGroupId = appGroupId; - pigeonResult.recaptchaSiteKey = recaptchaSiteKey; return pigeonResult; } + (CoreFirebaseOptions *)fromList:(NSArray *)list { @@ -179,7 +177,6 @@ + (CoreFirebaseOptions *)fromList:(NSArray *)list { pigeonResult.iosClientId = GetNullableObjectAtIndex(list, 11); pigeonResult.iosBundleId = GetNullableObjectAtIndex(list, 12); pigeonResult.appGroupId = GetNullableObjectAtIndex(list, 13); - pigeonResult.recaptchaSiteKey = GetNullableObjectAtIndex(list, 14); return pigeonResult; } + (nullable CoreFirebaseOptions *)nullableFromList:(NSArray *)list { @@ -201,7 +198,6 @@ + (nullable CoreFirebaseOptions *)nullableFromList:(NSArray *)list { self.iosClientId ?: [NSNull null], self.iosBundleId ?: [NSNull null], self.appGroupId ?: [NSNull null], - self.recaptchaSiteKey ?: [NSNull null], ]; } - (BOOL)isEqual:(id)object { @@ -225,8 +221,7 @@ - (BOOL)isEqual:(id)object { FLTPigeonDeepEquals(self.androidClientId, other.androidClientId) && FLTPigeonDeepEquals(self.iosClientId, other.iosClientId) && FLTPigeonDeepEquals(self.iosBundleId, other.iosBundleId) && - FLTPigeonDeepEquals(self.appGroupId, other.appGroupId) && - FLTPigeonDeepEquals(self.recaptchaSiteKey, other.recaptchaSiteKey); + FLTPigeonDeepEquals(self.appGroupId, other.appGroupId); } - (NSUInteger)hash { @@ -245,7 +240,6 @@ - (NSUInteger)hash { result = result * 31 + FLTPigeonDeepHash(self.iosClientId); result = result * 31 + FLTPigeonDeepHash(self.iosBundleId); result = result * 31 + FLTPigeonDeepHash(self.appGroupId); - result = result * 31 + FLTPigeonDeepHash(self.recaptchaSiteKey); return result; } @end diff --git a/packages/firebase_core_tvos/tvos/firebase_core_tvos.podspec b/packages/firebase_core_tvos/tvos/firebase_core_tvos.podspec index ec41bce..93a32c4 100644 --- a/packages/firebase_core_tvos/tvos/firebase_core_tvos.podspec +++ b/packages/firebase_core_tvos/tvos/firebase_core_tvos.podspec @@ -6,7 +6,7 @@ # Pod::Spec.new do |s| s.name = 'firebase_core_tvos' - s.version = '0.0.2' + s.version = '0.0.3' s.summary = 'tvOS implementation of firebase_core.' s.description = <<-DESC tvOS implementation of firebase_core, the federated platform From cf36379ea8a324ab5fd238b05d42475292155bad Mon Sep 17 00:00:00 2001 From: TheNoumanDev Date: Mon, 14 Sep 2026 03:55:00 +0500 Subject: [PATCH 2/2] fix(firebase_core_tvos): trim the 0.0.3 changelog, bump the example Review follow-ups on #25: * Cut the 0.0.3 entry to what changed; the payload history and release-note detail live in the PR description. * Drop the "Breaking" label. Users on older firebase_core resolve to 0.0.2, so no build breaks. * Bump the example to firebase_core ^4.13.0 to match the package. --- packages/firebase_core_tvos/CHANGELOG.md | 22 ++++--------------- .../firebase_core_tvos/example/pubspec.yaml | 2 +- 2 files changed, 5 insertions(+), 19 deletions(-) diff --git a/packages/firebase_core_tvos/CHANGELOG.md b/packages/firebase_core_tvos/CHANGELOG.md index d726852..e3ef9cb 100644 --- a/packages/firebase_core_tvos/CHANGELOG.md +++ b/packages/firebase_core_tvos/CHANGELOG.md @@ -1,23 +1,9 @@ ## 0.0.3 -* Regenerate the native Pigeon sources against the 14-element `CoreFirebaseOptions` payload and - widen the `firebase_core_platform_interface` pin to `^8.1.0`. - - 8.1.0 dropped `recaptchaSiteKey`, shortening the payload from 15 elements to 14. The generated - code decoded index 14 through a bare `NSArray` subscript, so on 8.1.x - `Firebase.initializeApp(options: ...)` raised `NSRangeException` before any Dart ran. 0.0.2 - avoided that by pinning to the 15-element window; this release regenerates instead. - - Sources come from `firebase_core` 4.13.0 — the last release whose iOS implementation is still - Objective-C (4.14.0 rewrote it in Swift), and the first on the 14-element payload. The delta - against the previous files is exclusively `recaptchaSiteKey`. - - The pin is a caret, matching what `firebase_core` declares for itself. Arity moved only during - one add/remove cycle — 7.1.0 introduced `recaptchaSiteKey` for reCAPTCHA support that was - "gradually rolling out", and 8.1.0 withdrew it when that moved to the provider API — across 23 - published minor lines. - - **Breaking:** now requires `firebase_core >= 4.13.0`. +* Regenerate the native Pigeon sources from `firebase_core` 4.13.0, which decode the + 14-element `CoreFirebaseOptions` payload that `firebase_core_platform_interface` 8.1.0 + settled on. 0.0.2 pinned to the 15-element window instead. +* Widen `firebase_core_platform_interface` to `^8.1.0`; require `firebase_core` `^4.13.0`. ## 0.0.2 diff --git a/packages/firebase_core_tvos/example/pubspec.yaml b/packages/firebase_core_tvos/example/pubspec.yaml index 8d1ca16..b7ccf2b 100644 --- a/packages/firebase_core_tvos/example/pubspec.yaml +++ b/packages/firebase_core_tvos/example/pubspec.yaml @@ -6,7 +6,7 @@ environment: flutter: '>=3.27.0' dependencies: - firebase_core: ^4.11.0 + firebase_core: ^4.13.0 firebase_core_tvos: path: ../ flutter: