Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[firebase_auth]: handleSignInWithApple EXC_BAD_ACCESS (KERN_INVALID_ADDRESS) #16845

Open
1 task done
Tom3652 opened this issue Dec 8, 2024 · 1 comment
Open
1 task done
Labels
platform: ios Issues / PRs which are specifically for iOS. plugin: auth resolution: needs-repro This issue could not be reproduced or needs an up to date reproduction on latest FlutterFire plugin. type: bug Something isn't working

Comments

@Tom3652
Copy link

Tom3652 commented Dec 8, 2024

Is there an existing issue for this?

  • I have searched the existing issues.

Which plugins are affected?

Auth

Which platforms are affected?

iOS

Description

A crash is happening when trying to sign in with Apple on my iOS live app with firebase_auth and using the AppleAuthProvider class.

Reproducing the issue

I have no idea how to reproduce it since it happened only to my live users and i have tested the Sign in With Apple multiple times after without any success to reproduce the issue...

Here is the code i am calling in my released app to sign in with Apple :

Future<bool> signInWithApple() async {
    AppleAuthProvider appleAuthProvider = AppleAuthProvider();
    appleAuthProvider.addScope("email");
    appleAuthProvider.addScope("fullName");
    try {
       UserCredential? userCredential = await FirebaseAuth.instance.signInWithProvider(appleAuthProvider);
       return userCredential != null;
    } catch (error) {
       print("Error sign in with Apple $error");
    }
    return false;
}

Firebase Core version

3.8.1

Flutter Version

3.24.5

Relevant Log Output

Crashed: com.apple.main-thread
0  Runner                         0x5a8614 handleSignInWithApple + 369 (FLTFirebaseAuthPlugin.m:369)
1  Runner                         0x5a8724 __78-[FLTFirebaseAuthPlugin authorizationController:didCompleteWithAuthorization:]_block_invoke_2 + 433 (FLTFirebaseAuthPlugin.m:433)
2  FirebaseAuth                   0x1985c thunk for @escaping @callee_unowned @convention(block) (@unowned ActionCodeInfo?, @unowned NSError?) -> () + 68 (<compiler-generated>:68)
3  FirebaseAuth                   0x28678 partial apply for thunk for @escaping @callee_guaranteed (@guaranteed AuthDataResult?, @guaranteed Error?) -> () + 24 (<compiler-generated>:24)
4  FirebaseAuth                   0x2963c partial apply for specialized closure #1 in static Auth.wrapMainAsync<A>(callback:withParam:error:) + 40
5  FirebaseAuth                   0xd4c4 thunk for @escaping @callee_guaranteed () -> () + 28
6  libdispatch.dylib              0x2370 _dispatch_call_block_and_release + 32
7  libdispatch.dylib              0x40d0 _dispatch_client_callout + 20
8  libdispatch.dylib              0x129e0 _dispatch_main_queue_drain + 980
9  libdispatch.dylib              0x125fc _dispatch_main_queue_callback_4CF + 44
10 CoreFoundation                 0x56204 __CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__ + 16
11 CoreFoundation                 0x53440 __CFRunLoopRun + 1996
12 CoreFoundation                 0x52830 CFRunLoopRunSpecific + 588
13 GraphicsServices               0x11c4 GSEventRunModal + 164
14 UIKitCore                      0x3d2eb0 -[UIApplication _run] + 816
15 UIKitCore                      0x4815b4 UIApplicationMain + 340
16 UIKitCore                      0x7bbfa8 block_destroy_helper.23 + 10212
17 Runner                         0x91e0 main + 4333703648 (AppDelegate.swift:4333703648)
18 ???                            0x1af672ec8 (Missing)

Flutter dependencies

Expand Flutter dependencies snippet
Dart SDK 3.5.4
Flutter SDK 3.24.5
login 0.0.1

dependencies:
- connectivity_plus 6.1.0 [flutter flutter_web_plugins connectivity_plus_platform_interface web meta nm collection]
- firebase_app_check 0.3.1+7 [firebase_app_check_platform_interface firebase_app_check_web firebase_core firebase_core_platform_interface flutter]
- firebase_auth 5.3.4 [firebase_auth_platform_interface firebase_auth_web firebase_core firebase_core_platform_interface flutter meta]
- firebase_core 3.8.1 [firebase_core_platform_interface firebase_core_web flutter meta]
- flutter 0.0.0 [characters collection material_color_utilities meta vector_math sky_engine]
- google_sign_in 6.2.2 [flutter google_sign_in_android google_sign_in_ios google_sign_in_platform_interface google_sign_in_web]

dev dependencies:
- flutter_lints 5.0.0 [lints]
- flutter_test 0.0.0 [flutter test_api matcher path fake_async clock stack_trace vector_math leak_tracker_flutter_testing async boolean_selector characters collection leak_tracker leak_tracker_testing material_color_utilities meta source_span stream_channel string_scanner term_glyph vm_service]

transitive dependencies:
- _flutterfire_internals 1.3.47 [collection firebase_core firebase_core_platform_interface flutter meta]
- args 2.6.0
- async 2.11.0 [collection meta]
- boolean_selector 2.1.1 [source_span string_scanner]
- characters 1.3.0
- clock 1.1.1
- collection 1.18.0
- connectivity_plus_platform_interface 2.0.1 [flutter meta plugin_platform_interface]
- dbus 0.7.10 [args ffi meta xml]
- fake_async 1.3.1 [clock collection]
- ffi 2.1.3
- firebase_app_check_platform_interface 0.1.0+41 [_flutterfire_internals firebase_core flutter meta plugin_platform_interface]
- firebase_app_check_web 0.2.0+3 [_flutterfire_internals firebase_app_check_platform_interface firebase_core firebase_core_web flutter flutter_web_plugins web]
- firebase_auth_platform_interface 7.4.10 [_flutterfire_internals collection firebase_core flutter meta plugin_platform_interface]
- firebase_auth_web 5.13.5 [firebase_auth_platform_interface firebase_core firebase_core_web flutter flutter_web_plugins http_parser meta web]
- firebase_core_platform_interface 5.3.1 [collection flutter flutter_test meta plugin_platform_interface]
- firebase_core_web 2.18.2 [firebase_core_platform_interface flutter flutter_web_plugins meta web]
- flutter_web_plugins 0.0.0 [flutter characters collection material_color_utilities meta vector_math]
- google_identity_services_web 0.3.3 [meta web]
- google_sign_in_android 6.1.33 [flutter google_sign_in_platform_interface]
- google_sign_in_ios 5.7.8 [flutter google_sign_in_platform_interface]
- google_sign_in_platform_interface 2.4.5 [flutter plugin_platform_interface]
- google_sign_in_web 0.12.4+3 [flutter flutter_web_plugins google_identity_services_web google_sign_in_platform_interface http web]
- http 1.2.2 [async http_parser meta web]
- http_parser 4.0.2 [collection source_span string_scanner typed_data]
- leak_tracker 10.0.5 [clock collection meta path vm_service]
- leak_tracker_flutter_testing 3.0.5 [flutter leak_tracker leak_tracker_testing matcher meta]
- leak_tracker_testing 3.0.1 [leak_tracker matcher meta]
- lints 5.0.0
- matcher 0.12.16+1 [async meta stack_trace term_glyph test_api]
- material_color_utilities 0.11.1 [collection]
- meta 1.15.0
- nm 0.5.0 [dbus]
- path 1.9.0
- petitparser 6.0.2 [meta]
- plugin_platform_interface 2.1.8 [meta]
- sky_engine 0.0.99
- source_span 1.10.0 [collection path term_glyph]
- stack_trace 1.11.1 [path]
- stream_channel 2.1.2 [async]
- string_scanner 1.2.0 [source_span]
- term_glyph 1.2.1
- test_api 0.7.2 [async boolean_selector collection meta source_span stack_trace stream_channel string_scanner term_glyph]
- typed_data 1.4.0 [collection]
- vector_math 2.1.4
- vm_service 14.2.5
- web 1.1.0
- xml 6.5.0 [collection meta petitparser]

Additional context and comments

No response

@Tom3652 Tom3652 added Needs Attention This issue needs maintainer attention. type: bug Something isn't working labels Dec 8, 2024
@SelaseKay SelaseKay added plugin: auth platform: ios Issues / PRs which are specifically for iOS. resolution: needs-repro This issue could not be reproduced or needs an up to date reproduction on latest FlutterFire plugin. labels Dec 9, 2024
@Tom3652
Copy link
Author

Tom3652 commented Dec 11, 2024

So far i have received 4 crashes on 4 different phones :

Capture d’écran 2024-12-11 à 13 42 16 Capture d’écran 2024-12-11 à 13 42 25 Capture d’écran 2024-12-11 à 13 42 35 Capture d’écran 2024-12-11 à 13 42 47

@SelaseKay SelaseKay removed the Needs Attention This issue needs maintainer attention. label Dec 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
platform: ios Issues / PRs which are specifically for iOS. plugin: auth resolution: needs-repro This issue could not be reproduced or needs an up to date reproduction on latest FlutterFire plugin. type: bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants