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

Exception happen in release. but run well in debug mode in macos #641

Closed
JMVoid opened this issue Jan 14, 2020 · 2 comments
Closed

Exception happen in release. but run well in debug mode in macos #641

JMVoid opened this issue Jan 14, 2020 · 2 comments

Comments

@JMVoid
Copy link

JMVoid commented Jan 14, 2020

I run "flutter build macos" to build release version code on a project and enter Contents/Macos folder and execute binary program. a Exception throw as following:
[ERROR:flutter/lib/ui/ui_dart_state.cc(157)] Unhandled Exception: SocketException: Failed host lookup: 'www.bitstunnel.com' (OS Error: nodename nor servname provided, or not known, errno = 8).
#0 IOClient.send (package:http/src/io_client.dart:33)

#1 BaseClient._sendUnstreamed (package:http/src/base_client.dart:176)
#2 BaseClient.get (package:http/src/base_client.dart:35)
#3 get. (package:http/http.dart:46)
otherwise, I execute "flutter run -d macos", the project is run well. have any idea of this issue??

flutter doctor -v message as following

[✓] Flutter (Channel master, v1.13.9-pre.59, on Mac OS X 10.14.6 18G103, locale en-HK)
• Flutter version 1.13.9-pre.59 at /Users/jmvoid/Android/flutter
• Framework revision ab36346af6 (3 days ago), 2020-01-11 14:20:05 -0500
• Engine revision 3d37d39d95
• Dart version 2.8.0 (build 2.8.0-dev.0.0 395daaa3ec)

[✓] Android toolchain - develop for Android devices (Android SDK version 28.0.3)
• Android SDK at /Users/jmvoid/Library/Android/sdk
• Android NDK location not configured (optional; useful for native profiling support)
• Platform android-28, build-tools 28.0.3
• ANDROID_HOME = /Users/jmvoid/Library/Android/sdk
• Java binary at: /Applications/Android Studio.app/Contents/jre/jdk/Contents/Home/bin/java
• Java version OpenJDK Runtime Environment (build 1.8.0_152-release-1343-b01)
• All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 11.3)
• Xcode at /Applications/Xcode.app/Contents/Developer
• Xcode 11.3, Build version 11C29
• CocoaPods version 1.6.1

[✓] Android Studio (version 3.4)
• Android Studio at /Applications/Android Studio.app/Contents
• Flutter plugin version 35.3.1
• Dart plugin version 183.6270
• Java version OpenJDK Runtime Environment (build 1.8.0_152-release-1343-b01)

[✓] Connected device (1 available)
• macOS • macOS • darwin-x64 • Mac OS X 10.14.6 18G103

@lesnitsky

This comment has been minimized.

@stuartmorgan
Copy link
Collaborator

The necessary entitlement, and the process for enabling it, is documented here. Note that you should not use the UI pictured above to enable it, as explained in the documentation.

@lesnitsky Please don't point people to the UI, which, as documented, is unlikely to work correctly. Also, it's not clear why you are instructing @JMVoid to enable server capabilities as nothing about this report suggests an intent for the app to be a server. @JMVoid You should start with enabling just the client entitlement unless you know that your application intends to accepting incoming connections. Enabling the server entitlement unnecessarily adds a significant attack surface to your application.

Closing as this is almost certainly a configuration error in the project rather than a bug.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Aug 6, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants