Android Studio中运行鸿蒙问题

288 阅读1分钟

指定指定运行参数

Edit Configurations image.png

指定运行参数

--local-engine=<flutter_engine out path>  --release/debug

image.png

真机运行报错

1、android studio中没有指定flutter_engine路径运行,或者指定路径错误

LastFatalMessage:Thread:21340402432  
[FATAL:flutter/runtime/dart_vm_initializer.cc(89)] Error while initializing the Dart VM: Wrong full snapshot version, expected 'xxxe6165fa7cf' found 'xxxx4ca70abcd2d5c7251'

2、运行后真机黑屏 flutter_engine 产物与运行版本没有对应

release的flutter_engine产物 编译出的产物必须指定 --release

image.png