Skip to content

warning: [deprecation] (shouldOverrideUrlLoading,onReceivedError,removeAllCookie) in WebViewClient has been deprecated #734

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

Open
3mrdev opened this issue May 4, 2020 · 3 comments

Comments

@3mrdev
Copy link

3mrdev commented May 4, 2020

System info

Issue occurs on: Android
Plugin version: ^0.3.11
Flutter doctor output:

[√] Flutter (Channel stable, v1.12.13+hotfix.9, on Microsoft Windows [Version 10.0.18362.476], locale en-US)
    • Flutter version 1.12.13+hotfix.9 at C:\Android\flutter
    • Framework revision f139b11009 (5 weeks ago), 2020-03-30 13:57:30 -0700
    • Engine revision af51afceb8
    • Dart version 2.7.2

[!] Android toolchain - develop for Android devices (Android SDK version 29.0.2)
    • Android SDK at C:\Android\sdk\sdk
    • Android NDK location not configured (optional; useful for native profiling support)
    • Platform android-29, build-tools 29.0.2
    • ANDROID_HOME = C:\Android\sdk\sdk\platform-tools
    • Java binary at: C:\Program Files\Android\Android Studio\jre\bin\java
    • Java version OpenJDK Runtime Environment (build 1.8.0_212-release-1586-b04)
    ! Some Android licenses not accepted.  To resolve this, run: flutter doctor --android-licenses

[√] Android Studio (version 3.6)
    • Android Studio at C:\Program Files\Android\Android Studio
    • Flutter plugin version 45.1.1
    • Dart plugin version 192.7761
    • Java version OpenJDK Runtime Environment (build 1.8.0_212-release-1586-b04)

[!] IntelliJ IDEA Community Edition (version 2019.2)
    • IntelliJ at C:\Program Files\JetBrains\IntelliJ IDEA Community Edition 2019.2.1
    X Flutter plugin not installed; this adds Flutter specific functionality.
    X Dart plugin not installed; this adds Dart specific functionality.
    • For information about installing plugins, see
      https://flutter.dev/intellij-setup/#installing-the-plugins

[√] VS Code (version 1.37.1)
    • VS Code at C:\Users\Amr Abd Alkrim\AppData\Local\Programs\Microsoft VS Code
    • Flutter extension version 2.25.1

[√] Connected device (1 available)
    • G8 • 1090308019017967 • android-arm64 • Android 9 (API 28)

! Doctor found issues in 2 categories.

Logs

C:\Android\flutter\.pub-cache\hosted\pub.dartlang.org\flutter_webview_plugin-0.3.11\android\src\main\java\com\flutter_webview_plugin\BrowserClient.java:80: warning: [deprecation] shouldOverrideUrlLoading(WebView,String) in WebViewClient has been deprecated
    public boolean shouldOverrideUrlLoading(WebView view, String url) {
                   ^
C:\Android\flutter\.pub-cache\hosted\pub.dartlang.org\flutter_webview_plugin-0.3.11\android\src\main\java\com\flutter_webview_plugin\BrowserClient.java:103: warning: [deprecation] onReceivedError(WebView,int,String,String) in WebViewClient has been deprecated
    public void onReceivedError(WebView view, int errorCode, String description, String failingUrl) {
                ^
C:\Android\flutter\.pub-cache\hosted\pub.dartlang.org\flutter_webview_plugin-0.3.11\android\src\main\java\com\flutter_webview_plugin\BrowserClient.java:104: warning: [deprecation] onReceivedError(WebView,int,String,String) in WebViewClient has been deprecated
        super.onReceivedError(view, errorCode, description, failingUrl);
             ^
C:\Android\flutter\.pub-cache\hosted\pub.dartlang.org\flutter_webview_plugin-0.3.11\android\src\main\java\com\flutter_webview_plugin\FlutterWebviewPlugin.java:310: warning: [deprecation] removeAllCookie() in CookieManager has been deprecated
            CookieManager.getInstance().removeAllCookie();
                                       ^
C:\Android\flutter\.pub-cache\hosted\pub.dartlang.org\flutter_webview_plugin-0.3.11\android\src\main\java\com\flutter_webview_plugin\WebviewManager.java:346: warning: [deprecation] removeAllCookie() in CookieManager has been deprecated
            CookieManager.getInstance().removeAllCookie();
                                       ^
Note: Some input files use unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.
5 warnings

[√] Flutter (Channel stable, v1.12.13+hotfix.9, on Microsoft Windows [Version 10.0.18362.476], locale en-US)
    • Flutter version 1.12.13+hotfix.9 at C:\Android\flutter
    • Framework revision f139b11009 (5 weeks ago), 2020-03-30 13:57:30 -0700
    • Engine revision af51afceb8
    • Dart version 2.7.2

[!] Android toolchain - develop for Android devices (Android SDK version 29.0.2)
    • Android SDK at C:\Android\sdk\sdk
    • Android NDK location not configured (optional; useful for native profiling support)
    • Platform android-29, build-tools 29.0.2
    • ANDROID_HOME = C:\Android\sdk\sdk\platform-tools
    • Java binary at: C:\Program Files\Android\Android Studio\jre\bin\java
    • Java version OpenJDK Runtime Environment (build 1.8.0_212-release-1586-b04)
    ! Some Android licenses not accepted.  To resolve this, run: flutter doctor --android-licenses

[√] Android Studio (version 3.6)
    • Android Studio at C:\Program Files\Android\Android Studio
    • Flutter plugin version 45.1.1
    • Dart plugin version 192.7761
    • Java version OpenJDK Runtime Environment (build 1.8.0_212-release-1586-b04)

[!] IntelliJ IDEA Community Edition (version 2019.2)
    • IntelliJ at C:\Program Files\JetBrains\IntelliJ IDEA Community Edition 2019.2.1
    X Flutter plugin not installed; this adds Flutter specific functionality.
    X Dart plugin not installed; this adds Dart specific functionality.
    • For information about installing plugins, see
      https://flutter.dev/intellij-setup/#installing-the-plugins

[√] VS Code (version 1.37.1)
    • VS Code at C:\Users\Amr Abd Alkrim\AppData\Local\Programs\Microsoft VS Code
    • Flutter extension version 2.25.1

[√] Connected device (1 available)
    • G8 • 1090308019017967 • android-arm64 • Android 9 (API 28)

! Doctor found issues in 2 categories.

@yourshinsuke
Copy link

@fluttercommunity

why do you use deprecated code?

@yourshinsuke
Copy link

Can I put custom error page?

shinriyo added a commit to shinriyo/flutter_webview_plugin that referenced this issue Oct 6, 2020
Detail for
warning: [deprecation] (shouldOverrideUrlLoading,onReceivedError,removeAllCookie) in WebViewClient has been deprecated fluttercommunity#734
shinriyo added a commit to shinriyo/flutter_webview_plugin that referenced this issue Oct 6, 2020
Detail for
warning: [deprecation] (shouldOverrideUrlLoading,onReceivedError,removeAllCookie) in WebViewClient has been deprecated fluttercommunity#734
This was referenced Oct 6, 2020
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

3 participants