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

[Android] Deprecated API is used #48

Open
mizutani-wataru opened this issue Jan 15, 2025 · 0 comments
Open

[Android] Deprecated API is used #48

mizutani-wataru opened this issue Jan 15, 2025 · 0 comments

Comments

@mizutani-wataru
Copy link

Current Behavior

While trying to build our app, we were getting warning logs like this:

~/.pub-cache/hosted/pub.dev/karte_core-1.3.0/android/src/main/java/io/karte/flutter/core/KarteCorePlugin.java:73: 警告:[deprecation] PluginRegistryのRegistrarは推奨されません
    public static void registerWith(PluginRegistry.Registrar registrar) {
                                                  ^
~/.pub-cache/hosted/pub.dev/karte_core-1.3.0/android/src/main/java/io/karte/flutter/core/KarteCorePlugin.java:153: 警告:[deprecation] Trackerのidentify(Map<String,?>)は推奨されません
                    Tracker.identify(values != null ? values : new HashMap<String, Object>());
                           ^
~/.pub-cache/hosted/pub.dev/karte_core-1.3.0/android/src/main/java/io/karte/flutter/core/KarteCorePlugin.java:181: 警告:[deprecation] UserSyncのappendUserSyncQueryParameter(String)は推奨されません
                    result.success(UserSync.appendUserSyncQueryParameter(url));

Add the following to android/build.gradle to output the above log.

allprojects {
    repositories {
        google()
        mavenCentral()
    }
  // add code.
  gradle.projectsEvaluated {
    tasks.withType(JavaCompile) {
      options.compilerArgs << "-Xlint:deprecation"
    }
  }

Steps to Reproduce

  1. flutter pub add karte_core@^1.3.0
  2. flutter run

Context (Environment)

run flutter doctor

Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel stable, 3.27.1, on macOS 15.2 24C101 darwin-arm64, locale ja-JP)
[!] Android toolchain - develop for Android devices (Android SDK version 35.0.0)
    ! Some Android licenses not accepted. To resolve this, run: flutter doctor --android-licenses
[✓] Xcode - develop for iOS and macOS (Xcode 16.2)
[✓] Chrome - develop for the web
[✓] Android Studio (version 2024.1)
[✓] VS Code (version 1.95.0)
[✓] Connected device (3 available)
[✓] Ne
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

No branches or pull requests

1 participant