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

Failed host lookup on release but works on dev build #336

Closed
JaceHo opened this issue Oct 21, 2019 · 1 comment
Closed

Failed host lookup on release but works on dev build #336

JaceHo opened this issue Oct 21, 2019 · 1 comment

Comments

@JaceHo
Copy link

JaceHo commented Oct 21, 2019

10-21 21:15:51.328 608 22064 I GRALLOC : iova_size=9265152,conUsg=0xb00,proUsg=0xb00, strd=1088,[afbc]HdrStrd=1088 PyldStrd=69632 Scrmbl=2,ionhnd = 1
10-21 21:15:51.337 16980 17017 E flutter : [ERROR:flutter/lib/ui/ui_dart_state.cc(148)] Unhandled Exception: SocketException: Failed host lookup: 'anime-pictures.net' (OS Error: No address associated with hostname, errno = 7)
10-21 21:15:51.337 16980 17017 E flutter : #0 IOClient.send (package:http/src/io_client.dart:30)
10-21 21:15:51.337 16980 17017 E flutter :
10-21 21:15:51.337 16980 17017 E flutter : #1 BaseClient._sendUnstreamed (package:http/src/base_client.dart:171)
10-21 21:15:51.337 16980 17017 E flutter :
10-21 21:15:51.337 16980 17017 E flutter : #2 BaseClient.get (package:http/src/base_client.dart:34)
10-21 21:15:51.337 16980 17017 E flutter : #3 get. (package:http/http.dart:47)
10-21 21:15:51.337 16980 17017 E flutter : #4 _withClient (package:http/http.dart:167)
10-21 21:15:51.337 16980 17017 E flutter :
10-21 21:15:51.337 16980 17017 E flutter : #5 get (package:http/http.dart:47)
10-21 21:15:51.337 16980 17017 E flutter : #6 _MyHomePageState.get:onchange. (package:reactive_app/main.dart:60)
10-21 21:15:51.337 16980 17017 E flutter : #7 EditableTextState._formatAndSetValue (package:flutter/src/widgets/editable_text.dart:1586)
10-21 21:15:51.337 16980 17017 E flutter : #8 EditableTextState.updateEditingValue (package:flutter/src/widgets/editable_text.dart:1201)

Above is the exception log, and below code runs well on dev build, using kotlin native code okhttp3 client also works

  get onchange => (str) {
        http
            .get(
                "https://anime-pictures.net/pictures/view_posts/0?&lang=zh_CN&search_tag=" +
                    str) //TODO
            .then((response) {
          return RegExp(r'img_cp[\s\S]+?src="\/\/([\s\S]+?)"', multiLine: true)
              .allMatches(response.body)
              .map((mt) => mt.group(1))
              .toList();
        }).then((List<String> urls) {
          print(urls);
          _updateWheel(urls);
        });
      };

My network is in good status. so, what's wrong here?

@natebosch
Copy link
Member

We don't have expertise to help with emulator or android/ios network and permission issues. Please follow up with the flutter team.
https://github.com/flutter/flutter/issues/29688

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

2 participants