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

🐛 [core, auth, analytics] Usage of deprecated APIs #3876

Closed
sidrao2006 opened this issue Oct 16, 2020 · 40 comments
Closed

🐛 [core, auth, analytics] Usage of deprecated APIs #3876

sidrao2006 opened this issue Oct 16, 2020 · 40 comments
Labels
impact: crowd Affects many people, though not necessarily a specific customer with an assigned label. (P2) platform: android Issues / PRs which are specifically for Android. platform: ios Issues / PRs which are specifically for iOS. plugin: analytics plugin: auth plugin: core type: bug Something isn't working

Comments

@sidrao2006
Copy link
Contributor

Bug report

Describe the bug

Usage of deprecated APIs

Steps to reproduce

Run app

Logs

Note: C:\Users\Aneesh\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\firebase_core-0.5.0+1\android\src\main\java\io\flutter\plugins\firebase\core\FlutterFirebaseCorePlugin.java uses or overrides a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
Note: C:\Users\Aneesh\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\firebase_analytics-6.0.2\android\src\main\java\io\flutter\plugins\firebaseanalytics\FirebaseAnalyticsPlugin.java uses or overrides a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
Note: C:\Users\Aneesh\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\firebase_auth-0.18.1+2\android\src\main\java\io\flutter\plugins\firebase\auth\FlutterFirebaseAuthPlugin.java uses or overrides a deprecated API.
Note: Recompile with -Xlint:deprecation for details

Flutter doctor

Run flutter doctor and paste the output below:

Click To Expand
[√] Flutter (Channel beta, 1.23.0-18.1.pre, on Microsoft Windows [Version 10.0.19041.546], locale en-US)
    • Flutter version 1.23.0-18.1.pre at C:\Users\Aneesh\flutter
    • Framework revision 198df796aa (10 hours ago), 2020-10-15 12:04:33 -0700
    • Engine revision 1d12d82d9c
    • Dart version 2.11.0 (build 2.11.0-213.1.beta)

 
[√] Android toolchain - develop for Android devices (Android SDK version 30.0.2)
    • Android SDK at C:\Users\Aneesh\AppData\Local\Android\Sdk
    • Platform android-30, build-tools 30.0.2
    • ANDROID_SDK_ROOT = C:\Users\Aneesh\AppData\Local\Android\Sdk
    • Java binary at: C:\Program Files\Android\Android Studio\jre\bin\java
    • Java version OpenJDK Runtime Environment (build 1.8.0_242-release-1644-b01)
    • All Android licenses accepted.

[√] Chrome - develop for the web
    • Chrome at C:\Program Files (x86)\Google\Chrome\Application\chrome.exe

[√] Android Studio (version 4.0)
    • Android Studio at C:\Program Files\Android\Android Studio
    • Flutter plugin version 50.0.2
    • Dart plugin version 201.9002
    • Java version OpenJDK Runtime Environment (build 1.8.0_242-release-1644-b01)

[√] VS Code (version 1.50.1)
    • VS Code at C:\Users\Aneesh\AppData\Local\Programs\Microsoft VS Code
    • Flutter extension version 3.15.1

[√] Connected device (4 available)
    • sdk gphone x86 (mobile) • emulator-5554 • android-x86    • Android 10 (API 29) (emulator)
    • Web Server (web)        • web-server    • web-javascript • Flutter Tools
    • Chrome (web)            • chrome        • web-javascript • Google Chrome 86.0.4240.75
    • Edge (web)              • edge          • web-javascript • Microsoft Edge 86.0.622.38

• No issues found!

Flutter dependencies

Click To Expand
Dart SDK 2.11.0-213.1.beta
Flutter SDK 1.23.0-18.1.pre
arcygnus 0.0.1+5
|-- auto_size_text 2.1.0
|   '-- flutter...
|-- cached_network_image 2.3.2+1
|   |-- flutter...
|   |-- flutter_cache_manager 1.4.2
|   |   |-- clock...
|   |   |-- file...
|   |   |-- flutter...
|   |   |-- http...
|   |   |-- path...
|   |   |-- path_provider...
|   |   |-- pedantic...
|   |   |-- rxdart 0.24.1
|   |   |-- sqflite 1.3.1+1
|   |   |   |-- flutter...
|   |   |   |-- path...
|   |   |   '-- sqflite_common 1.0.2+1
|   |   |       |-- meta...
|   |   |       |-- path...
|   |   |       '-- synchronized 2.2.0+2
|   |   '-- uuid 2.2.2
|   |       |-- convert...
|   |       '-- crypto...
|   '-- octo_image 0.3.0
|       |-- flutter...
|       '-- flutter_blurhash 0.5.0
|           |-- flutter...
|           '-- meta...
|-- draggable_scrollbar 0.0.4
|   '-- flutter...
|-- dynamic_fonts 1.1.0+1
|   |-- crypto 2.1.5
|   |   |-- collection...
|   |   |-- convert...
|   |   '-- typed_data...
|   |-- flutter...
|   |-- http 0.12.2
|   |   |-- http_parser...
|   |   |-- path...
|   |   '-- pedantic...
|   |-- path_provider 1.6.21
|   |   |-- flutter...
|   |   |-- path_provider_linux...
|   |   |-- path_provider_macos 0.0.4+4
|   |   |   '-- flutter...
|   |   |-- path_provider_platform_interface...
|   |   '-- path_provider_windows...
|   '-- pedantic 1.10.0-nullsafety.1
|-- email_validator 1.0.6
|-- emojis 0.9.3
|-- firebase_analytics 6.0.2
|   |-- firebase_analytics_platform_interface 1.0.3
|   |   |-- flutter...
|   |   '-- meta...
|   |-- firebase_analytics_web 0.1.1
|   |   |-- firebase...
|   |   |-- firebase_analytics_platform_interface...
|   |   |-- flutter...
|   |   |-- flutter_web_plugins...
|   |   '-- meta...
|   |-- firebase_core...
|   |-- flutter...
|   '-- meta...
|-- firebase_auth 0.18.1+2
|   |-- firebase_auth_platform_interface 2.1.1
|   |   |-- firebase_core...
|   |   |-- flutter...
|   |   |-- meta...
|   |   '-- plugin_platform_interface...
|   |-- firebase_auth_web 0.3.1+1
|   |   |-- firebase...
|   |   |-- firebase_auth_platform_interface...
|   |   |-- firebase_core...
|   |   |-- flutter...
|   |   |-- flutter_web_plugins...
|   |   |-- http_parser 3.1.4
|   |   |   |-- charcode...
|   |   |   |-- collection...
|   |   |   |-- source_span...
|   |   |   |-- string_scanner...
|   |   |   '-- typed_data...
|   |   |-- intl 0.16.1
|   |   |   '-- path...
|   |   |-- js...
|   |   '-- meta...
|   |-- firebase_core...
|   |-- firebase_core_platform_interface...
|   |-- flutter...
|   '-- meta...
|-- firebase_core 0.5.0+1
|   |-- firebase_core_platform_interface 2.0.0
|   |   |-- flutter...
|   |   |-- meta...
|   |   |-- plugin_platform_interface 1.0.3
|   |   |   '-- meta...
|   |   '-- quiver...
|   |-- firebase_core_web 0.2.0
|   |   |-- firebase 7.3.2
|   |   |   |-- http...
|   |   |   |-- http_parser...
|   |   |   '-- js...
|   |   |-- firebase_core_platform_interface...
|   |   |-- flutter...
|   |   |-- flutter_web_plugins 0.0.0
|   |   |   |-- characters...
|   |   |   |-- collection...
|   |   |   |-- flutter...
|   |   |   |-- js...
|   |   |   |-- meta...
|   |   |   |-- typed_data...
|   |   |   '-- vector_math...
|   |   |-- js...
|   |   '-- meta...
|   |-- flutter...
|   |-- meta...
|   '-- quiver 2.1.3
|       |-- matcher...
|       '-- meta...
|-- flutter 0.0.0
|   |-- characters 1.1.0-nullsafety.3
|   |-- collection 1.15.0-nullsafety.3
|   |-- meta 1.3.0-nullsafety.4
|   |-- sky_engine 0.0.99
|   |-- typed_data 1.3.0-nullsafety.3
|   |   '-- collection...
|   '-- vector_math 2.1.0-nullsafety.3
|-- flutter_driver 0.0.0
|   |-- archive 2.0.13
|   |   |-- args...
|   |   |-- crypto...
|   |   '-- path...
|   |-- args 1.6.0
|   |-- async 2.5.0-nullsafety.1
|   |   '-- collection...
|   |-- boolean_selector 2.1.0-nullsafety.1
|   |   |-- source_span...
|   |   '-- string_scanner...
|   |-- characters...
|   |-- charcode 1.2.0-nullsafety.1
|   |-- clock 1.1.0-nullsafety.1
|   |-- collection...
|   |-- convert 2.1.1
|   |   |-- charcode...
|   |   '-- typed_data...
|   |-- crypto...
|   |-- fake_async 1.2.0-nullsafety.1
|   |   |-- clock...
|   |   '-- collection...
|   |-- file 6.0.0-nullsafety.2
|   |   |-- meta...
|   |   '-- path...
|   |-- flutter...
|   |-- flutter_test 0.0.0
|   |   |-- async...
|   |   |-- boolean_selector...
|   |   |-- characters...
|   |   |-- charcode...
|   |   |-- clock...
|   |   |-- collection...
|   |   |-- fake_async...
|   |   |-- flutter...
|   |   |-- matcher...
|   |   |-- meta...
|   |   |-- path...
|   |   |-- source_span...
|   |   |-- stack_trace...
|   |   |-- stream_channel...
|   |   |-- string_scanner...
|   |   |-- term_glyph...
|   |   |-- test_api...
|   |   |-- typed_data...
|   |   '-- vector_math...
|   |-- fuchsia_remote_debug_protocol 0.0.0
|   |   |-- archive...
|   |   |-- args...
|   |   |-- async...
|   |   |-- boolean_selector...
|   |   |-- charcode...
|   |   |-- clock...
|   |   |-- collection...
|   |   |-- convert...
|   |   |-- crypto...
|   |   |-- fake_async...
|   |   |-- file...
|   |   |-- flutter_driver...
|   |   |-- flutter_test...
|   |   |-- json_rpc_2...
|   |   |-- matcher...
|   |   |-- meta...
|   |   |-- path...
|   |   |-- platform...
|   |   |-- process...
|   |   |-- pub_semver...
|   |   |-- source_span...
|   |   |-- stack_trace...
|   |   |-- stream_channel...
|   |   |-- string_scanner...
|   |   |-- sync_http...
|   |   |-- term_glyph...
|   |   |-- test_api...
|   |   |-- typed_data...
|   |   |-- vector_math...
|   |   |-- vm_service_client...
|   |   |-- web_socket_channel...
|   |   '-- webdriver...
|   |-- json_rpc_2 2.2.2
|   |   |-- stack_trace...
|   |   '-- stream_channel...
|   |-- matcher 0.12.10-nullsafety.1
|   |   '-- stack_trace...
|   |-- meta...
|   |-- path 1.8.0-nullsafety.1
|   |-- platform 3.0.0-nullsafety.2
|   |-- process 4.0.0-nullsafety.2
|   |   |-- file...
|   |   |-- path...
|   |   '-- platform...
|   |-- pub_semver 1.4.4
|   |   '-- collection...
|   |-- source_span 1.8.0-nullsafety.2
|   |   |-- charcode...
|   |   |-- collection...
|   |   |-- path...
|   |   '-- term_glyph...
|   |-- stack_trace 1.10.0-nullsafety.2
|   |   '-- path...
|   |-- stream_channel 2.1.0-nullsafety.1
|   |   '-- async...
|   |-- string_scanner 1.1.0-nullsafety.1
|   |   |-- charcode...
|   |   '-- source_span...
|   |-- sync_http 0.2.0
|   |-- term_glyph 1.2.0-nullsafety.1
|   |-- test_api 0.2.19-nullsafety.2
|   |   |-- async...
|   |   |-- boolean_selector...
|   |   |-- collection...
|   |   |-- matcher...
|   |   |-- meta...
|   |   |-- path...
|   |   |-- source_span...
|   |   |-- stack_trace...
|   |   |-- stream_channel...
|   |   |-- string_scanner...
|   |   '-- term_glyph...
|   |-- typed_data...
|   |-- vector_math...
|   |-- vm_service_client 0.2.6+2
|   |   |-- async...
|   |   |-- collection...
|   |   |-- json_rpc_2...
|   |   |-- pub_semver...
|   |   |-- source_span...
|   |   |-- stack_trace...
|   |   |-- stream_channel...
|   |   '-- web_socket_channel...
|   |-- web_socket_channel 1.1.0
|   |   |-- async...
|   |   |-- crypto...
|   |   '-- stream_channel...
|   '-- webdriver 2.1.2
|       |-- archive...
|       |-- matcher...
|       |-- path...
|       |-- stack_trace...
|       '-- sync_http...
|-- flutter_screenutil 3.1.1
|   '-- flutter...
|-- flutter_svg 0.19.0
|   |-- flutter...
|   |-- meta...
|   |-- path_drawing 0.4.1+1
|   |   |-- flutter...
|   |   |-- meta...
|   |   |-- path_parsing 0.1.4
|   |   |   |-- meta...
|   |   |   '-- vector_math...
|   |   '-- vector_math...
|   |-- vector_math...
|   '-- xml 4.5.1
|       |-- collection...
|       |-- convert...
|       |-- meta...
|       '-- petitparser 3.1.0
|           '-- meta...
|-- lint 1.3.0
|-- modal_progress_hud 0.1.3
|   '-- flutter...
|-- shared_preferences 0.5.12+2
|   |-- flutter...
|   |-- meta...
|   |-- shared_preferences_linux 0.0.2+2
|   |   |-- file...
|   |   |-- flutter...
|   |   |-- meta...
|   |   |-- path...
|   |   |-- path_provider_linux 0.0.1+2
|   |   |   |-- flutter...
|   |   |   |-- path...
|   |   |   |-- path_provider_platform_interface...
|   |   |   '-- xdg_directories 0.1.2
|   |   |       |-- meta...
|   |   |       |-- path...
|   |   |       '-- process...
|   |   '-- shared_preferences_platform_interface...
|   |-- shared_preferences_macos 0.0.1+10
|   |   |-- flutter...
|   |   '-- shared_preferences_platform_interface...
|   |-- shared_preferences_platform_interface 1.0.4
|   |   |-- flutter...
|   |   '-- meta...
|   |-- shared_preferences_web 0.1.2+7
|   |   |-- flutter...
|   |   |-- flutter_web_plugins...
|   |   |-- meta...
|   |   '-- shared_preferences_platform_interface...
|   '-- shared_preferences_windows 0.0.1+1
|       |-- ffi 0.1.3
|       |-- file...
|       |-- flutter...
|       |-- meta...
|       |-- path...
|       |-- path_provider_platform_interface 1.0.3
|       |   |-- flutter...
|       |   |-- meta...
|       |   |-- platform...
|       |   '-- plugin_platform_interface...
|       |-- path_provider_windows 0.0.4+1
|       |   |-- ffi...
|       |   |-- flutter...
|       |   |-- meta...
|       |   |-- path...
|       |   |-- path_provider_platform_interface...
|       |   '-- win32 1.7.3
|       |       '-- ffi...
|       '-- shared_preferences_platform_interface...
|-- sliding_up_panel 1.0.2
|   '-- flutter...
'-- test 1.16.0-nullsafety.5
    |-- analyzer 0.40.4
    |   |-- _fe_analyzer_shared 11.0.0
    |   |   '-- meta...
    |   |-- args...
    |   |-- charcode...
    |   |-- cli_util 0.2.0
    |   |   '-- path...
    |   |-- collection...
    |   |-- convert...
    |   |-- crypto...
    |   |-- glob 1.2.0
    |   |   |-- async...
    |   |   |-- collection...
    |   |   |-- node_io 1.1.1
    |   |   |   |-- node_interop 1.1.1
    |   |   |   |   '-- js...
    |   |   |   '-- path...
    |   |   |-- path...
    |   |   |-- pedantic...
    |   |   '-- string_scanner...
    |   |-- meta...
    |   |-- package_config...
    |   |-- path...
    |   |-- pub_semver...
    |   |-- source_span...
    |   |-- watcher 0.9.7+15
    |   |   |-- async...
    |   |   |-- path...
    |   |   '-- pedantic...
    |   '-- yaml...
    |-- async...
    |-- boolean_selector...
    |-- coverage 0.14.1
    |   |-- args...
    |   |-- logging 0.11.4
    |   |-- package_config...
    |   |-- path...
    |   |-- source_maps 0.10.10-nullsafety.1
    |   |   '-- source_span...
    |   |-- stack_trace...
    |   '-- vm_service 5.2.0
    |       '-- meta...
    |-- http...
    |-- http_multi_server 2.2.0
    |   '-- async...
    |-- io 0.3.4
    |   |-- charcode...
    |   |-- meta...
    |   |-- path...
    |   '-- string_scanner...
    |-- js 0.6.3-nullsafety.1
    |-- node_preamble 1.4.12
    |-- package_config 1.9.3
    |   |-- charcode...
    |   '-- path...
    |-- path...
    |-- pedantic...
    |-- pool 1.5.0-nullsafety.1
    |   |-- async...
    |   '-- stack_trace...
    |-- shelf 0.7.9
    |   |-- async...
    |   |-- collection...
    |   |-- http_parser...
    |   |-- path...
    |   |-- stack_trace...
    |   '-- stream_channel...
    |-- shelf_packages_handler 2.0.0
    |   |-- path...
    |   |-- shelf...
    |   '-- shelf_static...
    |-- shelf_static 0.2.8
    |   |-- convert...
    |   |-- http_parser...
    |   |-- mime 0.9.7
    |   |-- path...
    |   '-- shelf...
    |-- shelf_web_socket 0.2.3
    |   |-- shelf...
    |   |-- stream_channel...
    |   '-- web_socket_channel...
    |-- source_span...
    |-- stack_trace...
    |-- stream_channel...
    |-- test_api...
    |-- test_core 0.3.12-nullsafety.5
    |   |-- analyzer...
    |   |-- args...
    |   |-- async...
    |   |-- boolean_selector...
    |   |-- collection...
    |   |-- coverage...
    |   |-- glob...
    |   |-- io...
    |   |-- matcher...
    |   |-- meta...
    |   |-- package_config...
    |   |-- path...
    |   |-- pedantic...
    |   |-- pool...
    |   |-- source_map_stack_trace 2.1.0-nullsafety.2
    |   |   |-- path...
    |   |   |-- source_maps...
    |   |   '-- stack_trace...
    |   |-- source_maps...
    |   |-- source_span...
    |   |-- stack_trace...
    |   |-- stream_channel...
    |   |-- test_api...
    |   |-- vm_service...
    |   '-- yaml...
    |-- typed_data...
    |-- web_socket_channel...
    |-- webkit_inspection_protocol 0.7.3
    |   '-- logging...
    '-- yaml 2.2.1
        |-- charcode...
        |-- collection...
        |-- source_span...
        '-- string_scanner...

@sidrao2006 sidrao2006 added Needs Attention This issue needs maintainer attention. type: bug Something isn't working labels Oct 16, 2020
@markusaksli-nc
Copy link
Contributor

There is already an open issue for analytics #1389

I can confirm this as reproducible.

flutter doctor -v
[✓] Flutter (Channel master, 1.23.0-19.0.pre.79, on Mac OS X 10.15.7 19H2 darwin-x64, locale en-GB)
    • Flutter version 1.23.0-19.0.pre.79 at /Users/markus/development/flutter_master
    • Framework revision 438c4ff21c (42 minutes ago), 2020-10-16 01:52:04 -0700
    • Engine revision 1bc025d6cb
    • Dart version 2.11.0 (build 2.11.0-222.0.dev)

[✓] Android toolchain - develop for Android devices (Android SDK version 30.0.1)
    • Android SDK at /Users/markus/Library/Android/sdk
    • Platform android-30, build-tools 30.0.1
    • Java binary at: /Users/markus/Library/Application Support/JetBrains/Toolbox/apps/AndroidStudio/ch-0/201.6858069/Android Studio.app/Contents/jre/jdk/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 1.8.0_242-release-1644-b3-6222593)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 12.0.1)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Xcode 12.0.1, Build version 12A7300
    • CocoaPods version 1.9.3

[✓] Chrome - develop for the web
    • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome

[✓] Android Studio (version 4.1)
    • Android Studio at /Users/markus/Library/Application Support/JetBrains/Toolbox/apps/AndroidStudio/ch-0/201.6858069/Android Studio.app/Contents
    • Flutter plugin can be installed from:
      � https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      � https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build 1.8.0_242-release-1644-b3-6222593)

[✓] Connected device (5 available)
    • Nevercode’s iPhone (mobile)         • b668e524315069f3db3661ac11ff1f66afafebdb • ios            • iOS 13.7
    • iPhone SE (2nd generation) (mobile) • B46F1F22-93B0-40C4-8DA7-1C9816E399F7     • ios            • com.apple.CoreSimulator.SimRuntime.iOS-14-0 (simulator)
    • macOS (desktop)                     • macos                                    • darwin-x64     • Mac OS X 10.15.7 19H2 darwin-x64
    • Web Server (web)                    • web-server                               • web-javascript • Flutter Tools
    • Chrome (web)                        • chrome                                   • web-javascript • Google Chrome 86.0.4240.80

• No issues found!

@markusaksli-nc markusaksli-nc added plugin: auth plugin: core and removed Needs Attention This issue needs maintainer attention. labels Oct 16, 2020
@mrweiland
Copy link

#1389 is a really old issue - is it ongoing development on this plugin?

Same problem with deprecated api.

@TahaTesser
Copy link

TahaTesser commented Nov 13, 2020

Warnings are thrown on iOS
For example
/Users/UserA/Library/Android/flutter/.pub-cache/hosted/pub.dartlang.org/firebase_analytics-6.2.0/ios/Classes/FLTFirebaseAnalyticsPlugin.m:49:19: 'setScreenName:screenClass:' is deprecated: Use +[FIRAnalytics logEventWithName:kFIREventScreenView parameters:] instead

@TahaTesser TahaTesser added platform: android Issues / PRs which are specifically for Android. platform: ios Issues / PRs which are specifically for iOS. labels Nov 13, 2020
@xlcod
Copy link

xlcod commented Nov 16, 2020

Still have the same problem, Screen reporting not working on IOS and Android, any solution?

@Developer-jdantas
Copy link

Same error...
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
Note: /Users/USER/PATH/flutter/.pub-cache/hosted/pub.dartlang.org/firebase_analytics-6.2.0/android/src/main/java/io/flutter/plugins/firebaseanalytics/FirebaseAnalyticsPlugin.java uses or overrides a deprecated API.
Note: Recompile with -Xlint:deprecation for details.

@aghyad97
Copy link

Same issue here, any solution?

@sidrao2006
Copy link
Contributor Author

@aghyad97
This isn't blocking builds or releases. Right?

@aghyad97
Copy link

@sidrao2006 It is affecting the app when it launches, it wasn't the case before.

@rakib205
Copy link

Any Solution?

@diegoporfirio
Copy link

Same here

@Developer-jdantas
Copy link

the error did’t crashing compilation.
So I just disregard for now.

@JesperWe
Copy link

JesperWe commented Nov 24, 2020

The problem is not only the compilation warnings. As #2315 (closed in favor of this issue) points out, the ecommerce_purchase event is officially deprecated in favor of purchase, which is supported by the native SDKs and has more options that the current version can't access (such as a list of purchased items).

https://firebase.google.com/docs/reference/android/com/google/firebase/analytics/FirebaseAnalytics.Event#ECOMMERCE_PURCHASE

@Dohmanlechx
Copy link

The feature mentioned above is really in demand. A purchase feature where you track the purchase event and send items in a list. There's no such function in the firebase_analytics.dart file. Please let us know if you are working on this.

https://firebase.google.com/docs/reference/android/com/google/firebase/analytics/FirebaseAnalytics.Param#public-static-final-string-items

@rovkinmax
Copy link

We are need this fix. Why is there such an easy-to-fix bug, but important for analytics still exists?

@syedz
Copy link

syedz commented Jan 17, 2021

Any solutions for this? Can't even compile at this point.

@iamvikasht
Copy link

please provide any solution or workaround for this.

@markusaksli-nc
Copy link
Contributor

For everyone commenting for a solution here. These are just warnings thrown during compilation. If your app did not compile then this has absolutely nothing to do with it. There are a vast number of frameworks out there that will throw these warnings. This issue is just here to track that they exist here as well, for whatever reason.

Moreover this repository only wraps the upstream Firebase native SDKs so that they could be used with Flutter. Please look through your build logs carefully to find the actual reason it failed.

@rovkinmax
Copy link

@markusaksli-nc Aha. But in analytics report I wanna see correct and not deprecated event

@markusaksli-nc
Copy link
Contributor

I'm not saying that these messages shouldn't be resolved somewhere, only that they will not cause a build to fail. If you want them to disappear you will need to simply wait for this to be resolved. The issue exists here to track this.

@JesperWe
Copy link

It's not only compiler warnings. It is also the in-ability to use up to date Firebase events. See my comment above.

@WesselBouman
Copy link

Make sure you disable your VPN and/or try switching between networks. This fixed the problem for me. It might be related to your network port.

@Elkelany84
Copy link

change minSdkVersion to 21 in app/build.gradle

hieugia3030 added a commit to hieugia3030/My_learning_project that referenced this issue May 23, 2021
have issues on the version of the dependencies, settings.graddle,
If you have this issues again, follow this link: firebase/flutterfire#3876
@LivingfaithProzav
Copy link

Suffered the error of FlutterFirebaseCorePlugin.java uses or overrides a deprecated API. for two days.
finally solved it by changing minSdkVersion to 21 in app/build.gradle and run the app with flutter run --no-sound-null-safety.

Found that the error comes from the sound null safety implementation which grey lists all incompatible API

@bledgeware
Copy link

my issue resolved.

File → Invalidate Caches / Restart(android studio).

@mirkopoloni
Copy link

mirkopoloni commented Jun 7, 2021

I do get the warnings for a few packages (firebase core, cloud firestore, firebase auth and firebase storage).
Could the problem be the PluginRegistry.Registrar method? It is marked as deprecated here https://api.flutter.dev/javadoc/io/flutter/plugin/common/PluginRegistry.html and used from all the packages.

I also noticed that if I build the app more than once without flutter clean between the builds I only see the warnings the first time.
For all the people that wrote their solution on this issue, have you executed flutter clean before building the app? Are the warnings there or not?

@andrefedev

This comment has been minimized.

@angelocapone

This comment has been minimized.

@gmalmeida
Copy link

After updating android/app/build.gradle to minSdkVersion 21 and doing a clean build with flutter clean; flutter build apk, I still see these warnings:

image

My version:
image

@markusaksli-nc
Copy link
Contributor

Why would updating any android configs get rid of these warnings? These stem from the plugin code itself using deprecated APIs.

@muhammadidrees
Copy link

muhammadidrees commented Jul 22, 2021

Any update on this? I am having the same issue

Note: /home/idrees/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/firebase_core-1.4.0/android/src/main/java/io/flutter/plugins/firebase/core/FlutterFirebaseCorePlugin.java uses or overrides a deprecated API.
Note: Recompile with -Xlint:deprecation for details.                    
Note: /home/idrees/snap/flutter/common/flutter/.pub-cache/hosted/pub.dartlang.org/firebase_auth-3.0.1/android/src/main/java/io/flutter/plugins/firebase/auth/FlutterFirebaseAuthPlugin.java uses or overrides a deprecated API.
Note: Recompile with -Xlint:deprecation for details. 

I am using the latest version (as of today):

  firebase_auth: ^3.0.1
  firebase_core: ^1.4.0

@madatr

This comment has been minimized.

@HaikelO
Copy link

HaikelO commented Sep 14, 2021

if your minSdkVersion is set to 20 or lower, then you must use the multidex support library and make the following modifications to your app project:

Open the /android/app/build.gradle file. Under dependencies add the multidex module, and enable it within the defaultConfig

android {
    defaultConfig {
        // ...
        minSdkVersion 16
        targetSdkVersion 28
        multiDexEnabled true
    }
}
dependencies {
  implementation 'com.android.support:multidex:1.0.3'
}

@russellwheatley
Copy link
Member

russellwheatley commented Sep 14, 2021

We are currently reworking the firebase_analytics plugin, and we will update the API to match the latest Firebase Analytics API 🙏. See Roadmap.

@neail001
Copy link

if your minSdkVersion is set to 20 or lower, then you must use the multidex support library and make the following modifications to your app project:

Open the /android/app/build.gradle file. Under dependencies add the multidex module, and enable it within the defaultConfig

android {
    defaultConfig {
        // ...
        minSdkVersion 16
        targetSdkVersion 28
        multiDexEnabled true
    }
}
dependencies {
  implementation 'com.android.support:multidex:1.0.3'
}

Absolutely, for the Arctic fox upgrade I made my minimum sdk 24. It worked.

Please also upgrade the Gradle to V7, update the path in Env. Variables for Windows ( upgraded Gradle is prompting me with no Settings.gradle , but it works and builds the app)

Please also do a flutter upgrade in PowerShell or cmd.

@Salakar
Copy link
Member

Salakar commented Jan 28, 2022

Closing as this was fixed in #7127 - thanks for the report

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
impact: crowd Affects many people, though not necessarily a specific customer with an assigned label. (P2) platform: android Issues / PRs which are specifically for Android. platform: ios Issues / PRs which are specifically for iOS. plugin: analytics plugin: auth plugin: core type: bug Something isn't working
Projects
None yet
Development

No branches or pull requests