Flutter 2.0版本是不是还没适配?
Flutter 2.0版本是不是还没适配?
目前是支持2.0的。不过项目里的ws连接还存在一些问题,需要添加一些配置文件和修改一下ws地址才可以使用。后续会在README上说明并更新
@asjqkkkk 我现在也是在flutter2上跑,检测platformView泄漏时。点要进入LeakInfoPage时卡住就直接闪退了。Android
@asjqkkkk 我现在也是在flutter2上跑,检测platformView泄漏时。点要进入LeakInfoPage时卡住就直接闪退了。Android
这周会更新一个版本,如果还有闪退问题的话,可以再提一个issue,详细描述一下
@asjqkkkk 我现在也是在flutter2上跑,检测platformView泄漏时。点要进入LeakInfoPage时卡住就直接闪退了。Android
这周会更新一个版本,如果还有闪退问题的话,可以再提一个issue,详细描述一下
ok
本周的更新,会支持2.0和nullsafety吧? @asjqkkkk
本周的更新,会支持2.0和nullsafety吧? @asjqkkkk
会的
目前最新版本0.0.5已发布,由于项目使用到了 isolate 库,想要支持NullSafety的话需要该库先支持才行
目前最新版本0.0.5已发布,由于项目使用到了
isolate库,想要支持NullSafety的话需要该库先支持才行 flutter 2.0.4上报报超时 [ERROR:flutter/lib/ui/ui_dart_state.cc(186)] Unhandled Exception: SocketException: OS Error: Connection timed out, errno = 110, address = 10.0.2.2, port = 39568
目前最新版本0.0.5已发布,由于项目使用到了
isolate库,想要支持NullSafety的话需要该库先支持才行 flutter 2.0.4上报报超时 [ERROR:flutter/lib/ui/ui_dart_state.cc(186)] Unhandled Exception: SocketException: OS Error: Connection timed out, errno = 110, address = 10.0.2.2, port = 39568
运行环境是什么?可以先看一下README上面提到的问题是不是适用于你
目前最新版本0.0.5已发布,由于项目使用到了
isolate库,想要支持NullSafety的话需要该库先支持才行 flutter 2.0.4上报报超时 [ERROR:flutter/lib/ui/ui_dart_state.cc(186)] Unhandled Exception: SocketException: OS Error: Connection timed out, errno = 110, address = 10.0.2.2, port = 39568运行环境是什么?可以先看一下README上面提到的问题是不是适用于你
Android环境,已经加了android:usesCleartextTraffic="true"
demo跑起来也不能检测出内存泄漏。2.0.4版本。一样报连接超时
10.0.2.2 这个地址是不是要修改?
10.0.2.2 这个地址是不是要修改?
那试一试,在 android创建 network_security_config.xml文件: res/xml/network_security_config.xml
内容为:
<?xml version="1.0" encoding="utf-8"?>
<network-security-config>
<domain-config cleartextTrafficPermitted="false">
<domain includeSubdomains="true">secure.example.com</domain>
</domain-config>
</network-security-config>
再到AndroidManefest.xml中声明:
<application ...>
...
<meta-data android:name="io.flutter.network-policy"
android:resource="@xml/network_security_config"/>
</application>
10.0.2.2 这个地址是不是要修改?
那试一试,在 android创建
network_security_config.xml文件:res/xml/network_security_config.xml内容为:
<?xml version="1.0" encoding="utf-8"?> <network-security-config> <domain-config cleartextTrafficPermitted="false"> <domain includeSubdomains="true">secure.example.com</domain> </domain-config> </network-security-config>再到AndroidManefest.xml中声明:
<application ...> ... <meta-data android:name="io.flutter.network-policy" android:resource="@xml/network_security_config"/> </application>
还是不行的,你确定你那边可以的吗
10.0.2.2 这个地址是不是要修改?
那试一试,在 android创建
network_security_config.xml文件:res/xml/network_security_config.xml内容为:<?xml version="1.0" encoding="utf-8"?> <network-security-config> <domain-config cleartextTrafficPermitted="false"> <domain includeSubdomains="true">secure.example.com</domain> </domain-config> </network-security-config>再到AndroidManefest.xml中声明:
<application ...> ... <meta-data android:name="io.flutter.network-policy" android:resource="@xml/network_security_config"/> </application>还是不行的,你确定你那边可以的吗
猜测可能和你的网络环境有关系,你进行测试的设备网络环境是否有问题?
10.0.2.2 这个地址是不是要修改?
那试一试,在 android创建
network_security_config.xml文件:res/xml/network_security_config.xml内容为:<?xml version="1.0" encoding="utf-8"?> <network-security-config> <domain-config cleartextTrafficPermitted="false"> <domain includeSubdomains="true">secure.example.com</domain> </domain-config> </network-security-config>再到AndroidManefest.xml中声明:
<application ...> ... <meta-data android:name="io.flutter.network-policy" android:resource="@xml/network_security_config"/> </application>还是不行的,你确定你那边可以的吗
猜测可能和你的网络环境有关系,你进行测试的设备网络环境是否有问题?
在1.22.5版本上面就是正常的,host为什么是10.0.2.2?
10.0.2.2
测试环境受限,可能某些场景无法覆盖。 可以多提供一下相关的信息,比如测试设备的,如果是模拟器,可以看一下模拟器的一些设置 至于host为什么会修改,可以看一下https://developer.android.com/studio/run/emulator-networking
我看链接里面说的是用模拟器,所以要改host,我用是小米9真机。Android 10系统
------------------ 原始邮件 ------------------ 发件人: 安卓小哥 @.> 发送时间: 2021年5月13日 17:21 收件人: asjqkkkk/memory_checker @.> 抄送: Owenli0202 @.>, Author @.> 主题: 回复:[asjqkkkk/memory_checker] Flutter 2.0版本是不是还没适配? (#2)
10.0.2.2
测试环境受限,可能某些场景无法覆盖。 可以多提供一下相关的信息,比如测试设备的,如果是模拟器,可以看一下模拟器的一些设置 至于host为什么会修改,可以看一下https://developer.android.com/studio/run/emulator-networking
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.
[ERROR:flutter/lib/ui/ui_dart_state.cc(186)] Unhandled Exception: Bad state: Insecure HTTP is not allowed by platform: http://10.0.2.2:49592/q5W9RZaIevY=/ws
同样的问题,非模拟器。可能与targetSdkVersion 30有关,android:usesCleartextTraffic="true"无效了。 而network-security-config里又无法填IP
[ERROR:flutter/lib/ui/ui_dart_state.cc(186)] Unhandled Exception: Bad state: Insecure HTTP is not allowed by platform: http://10.0.2.2:49592/q5W9RZaIevY=/ws
同样的问题,非模拟器。可能与targetSdkVersion 30有关,android:usesCleartextTraffic="true"无效了。 而network-security-config里又无法填IP
我大概知道为什么了。因为目前只处理了模拟器连接到电脑的host地址。 但是当使用真机时,还需要手机与电脑处于同一网络环境下,并且通过路由器给电脑分配的ip地址来连接,但是这一部分的逻辑暂时是没有做的。