我正在尝试从远程服务器获取图像。我不断收到此错误:
Warning database has been locked for 0:00:10.000000.
Make sure you always use the transaction object for database operations during a transaction
Run Code Online (Sandbox Code Playgroud)
之后我的应用程序崩溃了。
Widget carousel = new Container(
height: 200,
child: FutureBuilder<List<String>>(
future: getPropImgs(),
builder: (context, snapshot) {
if (snapshot.hasData) {
return new Carousel(
boxFit: BoxFit.cover,
images: snapshot.data.map((f) {
return new CachedNetworkImage(
imageUrl: f.toString(),
imageBuilder: (context, imageProvider) => Container(
decoration: BoxDecoration(
image: DecorationImage(
image: imageProvider,
fit: BoxFit.cover,
colorFilter:
ColorFilter.mode(Colors.blue, BlendMode.dstIn)),
),
),
placeholder: (context, url) => Center(
child: Container(
height: …Run Code Online (Sandbox Code Playgroud)