if url response like this
code:200
body: { msg:xxxxx ๆไปถไธๅญๅจ }
throw Exception: Could not instantiate image codec.
When the exception was thrown, this was the stack:
...
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
and error widget not visible
Same
โโโโโโโโ Exception caught by image resource service โโโโโโโโโโโโโโโโโโโโโโโโโโโโ
The following _Exception was thrown resolving an image codec:
Exception: Could not instantiate image codec.
When the exception was thrown, this was the stack
#0 _futurize (dart:ui/painting.dart:4134:5)
#1 instantiateImageCodec (dart:ui/painting.dart:1669:10)
#2 PaintingBinding.instantiateImageCodec
package:flutter/โฆ/painting/binding.dart:74
#3 FileImage._loadAsync
package:flutter/โฆ/painting/image_provider.dart:545
<asynchronous suspension>
...
Same problem here...
โโโโโโโโ Exception caught by image resource service โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
The following _Exception was thrown resolving an image codec:
Exception: Could not instantiate image codec.
When the exception was thrown, this was the stack:
#0 _futurize (dart:ui/painting.dart:4134:5)
#1 instantiateImageCodec (dart:ui/painting.dart:1669:10)
#2 PaintingBinding.instantiateImageCodec (package:flutter/src/painting/binding.dart:74:12)
#3 FileImage._loadAsync (package:flutter/src/painting/image_provider.dart:545:43)
<asynchronous suspension>
Error widget did not work for me either, but I fixed the issue by providing an actual image url, instead of a web page url with an image on it.
I have the same problem
The following _Exception was thrown resolving an image codec:
Exception: Could not instantiate image codec.
When the exception was thrown, this was the stack:
#0 _futurize (dart:ui/painting.dart:4134:5)
#1 instantiateImageCodec (dart:ui/painting.dart:1669:10)
#2 PaintingBinding.instantiateImageCodec (package:flutter/src/painting/binding.dart:74:12)
#3 FileImage._loadAsync (package:flutter/src/painting/image_provider.dart:545:43)
<asynchronous suspension>
...
Path: /data/user/0/.../cache/libCachedImageData/49895850-043f-11ea-fc85-65e2c2bd2c9c.plain; charset=utf-8
I have same problem.
Any workaround on this?
โโโโโโโโ Exception caught by image resource service โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
The following _Exception was thrown resolving an image codec:
Exception: Could not instantiate image codec.
When the exception was thrown, this was the stack:
#0 _futurize (dart:ui/painting.dart:4134:5)
#1 instantiateImageCodec (dart:ui/painting.dart:1669:10)
#2 PaintingBinding.instantiateImageCodec (package:flutter/src/painting/binding.dart:74:12)
#3 NetworkImage._loadAsync (package:flutter/src/painting/_network_image_io.dart:104:39)
<asynchronous suspension>
Please check that the url you've provided has a .jpg or .png or .jpeg in the line
eg.
.../7-78595_asian-businessman-png-professional-man-images-png.png <----
Hope this helps
Error widget did not work for me either, but I fixed the issue by providing an actual image url, instead of a web page url with an image on it.
You saved my day!
same here
Image.memory(jpgCompressedBytes)
โโโโโโโโ (3) Exception caught by image resource service โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
Exception: Could not instantiate image codec.
Exception: Could not instantiate image codec.
how to solve this problem
Same here.
Image.memory(resizedImage.getBytes()) -> "Could not instantiate image codec."
Apparently the image must be re-encoded in the appropriate file format, JPG in my case:
Image.memory(img.encodeJpg(resizedImage))
same
I save myself
my server respose like this
code:200
body: { msg:xxxxx ๆไปถไธๅญๅจ }
fix:
import 'package:flutter_cache_manager/flutter_cache_manager.dart';
import 'package:http/http.dart' as http;
import 'package:path/path.dart' as p;
import 'package:path_provider/path_provider.dart';
class MyCacheManager extends BaseCacheManager {
static const key = "my_cache";
static MyCacheManager _instance;
/// The DefaultCacheManager that can be easily used directly. The code of
/// this implementation can be used as inspiration for more complex cache
/// managers.
factory MyCacheManager() {
if (_instance == null) {
_instance = new MyCacheManager._();
}
return _instance;
}
MyCacheManager._()
: super(
key,
fileFetcher: _myHttpGetter,
);
Future<String> getFilePath() async {
var directory = await getTemporaryDirectory();
return p.join(directory.path, key);
}
static Future<FileFetcherResponse> _myHttpGetter(String url,
{Map<String, String> headers}) async {
var token = await UserInfoManager.getToken();
if (token != null) {
headers["Authorization"] = token;
}
var httpResponse = await http.get(url, headers: headers);
return new MyHttpFileFetcherResponse(httpResponse);
}
}
class MyHttpFileFetcherResponse extends HttpFileFetcherResponse {
http.Response _mResponse;
MyHttpFileFetcherResponse(this._mResponse) : super(_mResponse);
@override
get statusCode {
// see here, rewrite error response
try {
return _mResponse.statusCode == 200 &&
_mResponse.headers['content-type'].toString().contains("json")
? 404
: _mResponse.statusCode;
} catch (e) {
print(e);
return super.statusCode;
}
}
}
use:
CachedNetworkImage(
fit: BoxFit.cover,
cacheManager: MyCacheManager(),
//...
่ฑ่ฏญๅฎๅจๅๅพ, ๅฏไปฅ็ป cache_manager ๅบ ๆ issue ๆ่
pull request ๆฝๅ้
็ฝฎ FileFetcherResponse
close by error response type (not image), create other issu for other problem
please check the image url after inspecting the element.
like: https://image.shutterstock.com/image-photo/colorful-flower-on-dark-tropical-260nw-721703848.jpg
yes Zakir it's work pleaz cant u tell what issue was ,thinks
Somebody was not taking the correct URL. So that it was creating a problem. I have just suggested them to take the correct url of the image after inspecting the image element from browser.
Yes I agree Zakir , some URL could not load by flutter Image . For example , https://github.com/larrySmile02/YueWifiConnect/blob/master/img/my_cat.png ๏ผ https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1585992366358&di=742d439ce491f923c03f8e5ded0249df&imgtype=0&src=http%3A%2F%2F5b0988e595225.cdn.sohucs.com%2Fq_70%2Cc_zoom%2Cw_640%2Fimages%2F20181219%2Fc10da453b88345ee90e1bd47133028c2.jpeg
The first link isn't an image but a web page, don't expect the library to find images within a web page. This is the real url: https://raw.githubusercontent.com/larrySmile02/YueWifiConnect/master/img/my_cat.png
The second works perfectly fine on my phone in a CachedNetworkImage widget.
iam still getting this issue from time to time
Non-fatal Exception: java.lang.Exception: Exception: Could not instantiate image codec.
at PaintingBinding.instantiateImageCodec(binding.dart:88)
at FileImage._loadAsync(image_provider.dart:653)
at FileImage.load(image_provider.dart:638)
at ImageProvider.resolve.
at ImageCache.putIfAbsent(image_cache.dart:160)
at ImageProvider.resolve.
at SynchronousFuture.then(synchronous_future.dart:38)
at ImageProvider.resolve.
at ImageProvider.resolve(image_provider.dart:315)
at _ImageState._resolveImage(image.dart:1010)
at _ImageState.didChangeDependencies(image.dart:967)
at StatefulElement._firstBuild(framework.dart:4376)
at ComponentElement.mount(framework.dart:4201)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at ComponentElement.performRebuild(framework.dart:4243)
at Element.rebuild(framework.dart:3947)
at ComponentElement._firstBuild(framework.dart:4206)
at ComponentElement.mount(framework.dart:4201)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at ComponentElement.performRebuild(framework.dart:4243)
at Element.rebuild(framework.dart:3947)
at ComponentElement._firstBuild(framework.dart:4206)
at ComponentElement.mount(framework.dart:4201)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at SingleChildRenderObjectElement.mount(framework.dart:5445)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at SingleChildRenderObjectElement.mount(framework.dart:5445)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at ComponentElement.performRebuild(framework.dart:4243)
at Element.rebuild(framework.dart:3947)
at ComponentElement._firstBuild(framework.dart:4206)
at StatefulElement._firstBuild(framework.dart:4381)
at ComponentElement.mount(framework.dart:4201)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at SingleChildRenderObjectElement.mount(framework.dart:5445)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at ComponentElement.performRebuild(framework.dart:4243)
at Element.rebuild(framework.dart:3947)
at ComponentElement._firstBuild(framework.dart:4206)
at ComponentElement.mount(framework.dart:4201)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at SingleChildRenderObjectElement.mount(framework.dart:5445)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at ComponentElement.performRebuild(framework.dart:4243)
at Element.rebuild(framework.dart:3947)
at ComponentElement._firstBuild(framework.dart:4206)
at StatefulElement._firstBuild(framework.dart:4381)
at ComponentElement.mount(framework.dart:4201)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at ComponentElement.performRebuild(framework.dart:4243)
at Element.rebuild(framework.dart:3947)
at ComponentElement._firstBuild(framework.dart:4206)
at ComponentElement.mount(framework.dart:4201)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at SingleChildRenderObjectElement.mount(framework.dart:5445)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at ComponentElement.performRebuild(framework.dart:4243)
at Element.rebuild(framework.dart:3947)
at ComponentElement._firstBuild(framework.dart:4206)
at ComponentElement.mount(framework.dart:4201)
at ParentDataElement.mount(framework.dart:4617)
at Element.inflateWidget(framework.dart:3194)
at MultiChildRenderObjectElement.mount(framework.dart:5551)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at SingleChildRenderObjectElement.mount(framework.dart:5445)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at ComponentElement.performRebuild(framework.dart:4243)
at Element.rebuild(framework.dart:3947)
at ComponentElement._firstBuild(framework.dart:4206)
at ComponentElement.mount(framework.dart:4201)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at ComponentElement.performRebuild(framework.dart:4243)
at Element.rebuild(framework.dart:3947)
at ComponentElement._firstBuild(framework.dart:4206)
at StatefulElement._firstBuild(framework.dart:4381)
at ComponentElement.mount(framework.dart:4201)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at SingleChildRenderObjectElement.mount(framework.dart:5445)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at ComponentElement.performRebuild(framework.dart:4243)
at Element.rebuild(framework.dart:3947)
at ComponentElement._firstBuild(framework.dart:4206)
at ComponentElement.mount(framework.dart:4201)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at SingleChildRenderObjectElement.mount(framework.dart:5445)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at ComponentElement.performRebuild(framework.dart:4243)
at Element.rebuild(framework.dart:3947)
at ComponentElement._firstBuild(framework.dart:4206)
at ComponentElement.mount(framework.dart:4201)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at SingleChildRenderObjectElement.mount(framework.dart:5445)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at ComponentElement.performRebuild(framework.dart:4243)
at Element.rebuild(framework.dart:3947)
at ComponentElement._firstBuild(framework.dart:4206)
at StatefulElement._firstBuild(framework.dart:4381)
at ComponentElement.mount(framework.dart:4201)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at ComponentElement.performRebuild(framework.dart:4243)
at Element.rebuild(framework.dart:3947)
at ComponentElement._firstBuild(framework.dart:4206)
at StatefulElement._firstBuild(framework.dart:4381)
at ComponentElement.mount(framework.dart:4201)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at SingleChildRenderObjectElement.mount(framework.dart:5445)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at ComponentElement.performRebuild(framework.dart:4243)
at Element.rebuild(framework.dart:3947)
at ComponentElement._firstBuild(framework.dart:4206)
at ComponentElement.mount(framework.dart:4201)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at SingleChildRenderObjectElement.mount(framework.dart:5445)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at ComponentElement.performRebuild(framework.dart:4243)
at Element.rebuild(framework.dart:3947)
at ComponentElement._firstBuild(framework.dart:4206)
at ComponentElement.mount(framework.dart:4201)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at ComponentElement.performRebuild(framework.dart:4243)
at Element.rebuild(framework.dart:3947)
at ComponentElement._firstBuild(framework.dart:4206)
at ComponentElement.mount(framework.dart:4201)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at SingleChildRenderObjectElement.mount(framework.dart:5445)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at ComponentElement.performRebuild(framework.dart:4243)
at Element.rebuild(framework.dart:3947)
at ComponentElement._firstBuild(framework.dart:4206)
at StatefulElement._firstBuild(framework.dart:4381)
at ComponentElement.mount(framework.dart:4201)
at Element.inflateWidget(framework.dart:3194)
at MultiChildRenderObjectElement.mount(framework.dart:5551)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at SingleChildRenderObjectElement.mount(framework.dart:5445)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at ComponentElement.performRebuild(framework.dart:4243)
at Element.rebuild(framework.dart:3947)
at ComponentElement._firstBuild(framework.dart:4206)
at ComponentElement.mount(framework.dart:4201)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at SingleChildRenderObjectElement.mount(framework.dart:5445)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at ComponentElement.performRebuild(framework.dart:4243)
at Element.rebuild(framework.dart:3947)
at ComponentElement._firstBuild(framework.dart:4206)
at StatefulElement._firstBuild(framework.dart:4381)
at ComponentElement.mount(framework.dart:4201)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at ComponentElement.performRebuild(framework.dart:4243)
at Element.rebuild(framework.dart:3947)
at ComponentElement._firstBuild(framework.dart:4206)
at ComponentElement.mount(framework.dart:4201)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at ComponentElement.performRebuild(framework.dart:4243)
at Element.rebuild(framework.dart:3947)
at ComponentElement._firstBuild(framework.dart:4206)
at StatefulElement._firstBuild(framework.dart:4381)
at ComponentElement.mount(framework.dart:4201)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at SingleChildRenderObjectElement.mount(framework.dart:5445)
at Element.inflateWidget(framework.dart:3194)
at MultiChildRenderObjectElement.mount(framework.dart:5551)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at ComponentElement.performRebuild(framework.dart:4243)
at Element.rebuild(framework.dart:3947)
at ComponentElement._firstBuild(framework.dart:4206)
at ComponentElement.mount(framework.dart:4201)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at SingleChildRenderObjectElement.mount(framework.dart:5445)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at SingleChildRenderObjectElement.mount(framework.dart:5445)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at SingleChildRenderObjectElement.mount(framework.dart:5445)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at SingleChildRenderObjectElement.mount(framework.dart:5445)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at ComponentElement.performRebuild(framework.dart:4243)
at Element.rebuild(framework.dart:3947)
at ComponentElement._firstBuild(framework.dart:4206)
at ComponentElement.mount(framework.dart:4201)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at SingleChildRenderObjectElement.mount(framework.dart:5445)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at ComponentElement.performRebuild(framework.dart:4243)
at Element.rebuild(framework.dart:3947)
at ComponentElement._firstBuild(framework.dart:4206)
at StatefulElement._firstBuild(framework.dart:4381)
at ComponentElement.mount(framework.dart:4201)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at SingleChildRenderObjectElement.mount(framework.dart:5445)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at ComponentElement.performRebuild(framework.dart:4243)
at Element.rebuild(framework.dart:3947)
at ComponentElement._firstBuild(framework.dart:4206)
at ComponentElement.mount(framework.dart:4201)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at ComponentElement.performRebuild(framework.dart:4243)
at Element.rebuild(framework.dart:3947)
at ComponentElement._firstBuild(framework.dart:4206)
at ComponentElement.mount(framework.dart:4201)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at SingleChildRenderObjectElement.mount(framework.dart:5445)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at SingleChildRenderObjectElement.mount(framework.dart:5445)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at SingleChildRenderObjectElement.mount(framework.dart:5445)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at SingleChildRenderObjectElement.mount(framework.dart:5445)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at ComponentElement.performRebuild(framework.dart:4243)
at Element.rebuild(framework.dart:3947)
at ComponentElement._firstBuild(framework.dart:4206)
at ComponentElement.mount(framework.dart:4201)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at ComponentElement.performRebuild(framework.dart:4243)
at Element.rebuild(framework.dart:3947)
at ComponentElement._firstBuild(framework.dart:4206)
at StatefulElement._firstBuild(framework.dart:4381)
at ComponentElement.mount(framework.dart:4201)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at ComponentElement.performRebuild(framework.dart:4243)
at Element.rebuild(framework.dart:3947)
at ComponentElement._firstBuild(framework.dart:4206)
at StatefulElement._firstBuild(framework.dart:4381)
at ComponentElement.mount(framework.dart:4201)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at ComponentElement.performRebuild(framework.dart:4243)
at Element.rebuild(framework.dart:3947)
at ComponentElement._firstBuild(framework.dart:4206)
at ComponentElement.mount(framework.dart:4201)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at SingleChildRenderObjectElement.mount(framework.dart:5445)
at Element.inflateWidget(framework.dart:3194)
at MultiChildRenderObjectElement.mount(framework.dart:5551)
at _ViewportElement.mount(viewport.dart:186)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at SingleChildRenderObjectElement.mount(framework.dart:5445)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at SingleChildRenderObjectElement.mount(framework.dart:5445)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at SingleChildRenderObjectElement.mount(framework.dart:5445)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at ComponentElement.performRebuild(framework.dart:4243)
at Element.rebuild(framework.dart:3947)
at ComponentElement._firstBuild(framework.dart:4206)
at ComponentElement.mount(framework.dart:4201)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at SingleChildRenderObjectElement.mount(framework.dart:5445)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at ComponentElement.performRebuild(framework.dart:4243)
at Element.rebuild(framework.dart:3947)
at ComponentElement._firstBuild(framework.dart:4206)
at StatefulElement._firstBuild(framework.dart:4381)
at ComponentElement.mount(framework.dart:4201)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at SingleChildRenderObjectElement.mount(framework.dart:5445)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at ComponentElement.performRebuild(framework.dart:4243)
at Element.rebuild(framework.dart:3947)
at ComponentElement._firstBuild(framework.dart:4206)
at ComponentElement.mount(framework.dart:4201)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at ComponentElement.performRebuild(framework.dart:4243)
at Element.rebuild(framework.dart:3947)
at ComponentElement._firstBuild(framework.dart:4206)
at ComponentElement.mount(framework.dart:4201)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at SingleChildRenderObjectElement.mount(framework.dart:5445)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at SingleChildRenderObjectElement.mount(framework.dart:5445)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at SingleChildRenderObjectElement.mount(framework.dart:5445)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at SingleChildRenderObjectElement.mount(framework.dart:5445)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at ComponentElement.performRebuild(framework.dart:4243)
at Element.rebuild(framework.dart:3947)
at ComponentElement._firstBuild(framework.dart:4206)
at ComponentElement.mount(framework.dart:4201)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at ComponentElement.performRebuild(framework.dart:4243)
at Element.rebuild(framework.dart:3947)
at ComponentElement._firstBuild(framework.dart:4206)
at StatefulElement._firstBuild(framework.dart:4381)
at ComponentElement.mount(framework.dart:4201)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at ComponentElement.performRebuild(framework.dart:4243)
at Element.rebuild(framework.dart:3947)
at ComponentElement._firstBuild(framework.dart:4206)
at StatefulElement._firstBuild(framework.dart:4381)
at ComponentElement.mount(framework.dart:4201)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at ComponentElement.performRebuild(framework.dart:4243)
at Element.rebuild(framework.dart:3947)
at ComponentElement._firstBuild(framework.dart:4206)
at ComponentElement.mount(framework.dart:4201)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at ComponentElement.performRebuild(framework.dart:4243)
at Element.rebuild(framework.dart:3947)
at ComponentElement._firstBuild(framework.dart:4206)
at ComponentElement.mount(framework.dart:4201)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at ComponentElement.performRebuild(framework.dart:4243)
at Element.rebuild(framework.dart:3947)
at ComponentElement._firstBuild(framework.dart:4206)
at ComponentElement.mount(framework.dart:4201)
at Element.inflateWidget(framework.dart:3194)
at Element.updateChild(framework.dart:2988)
at _LayoutBuilderElement._layout.
at BuildOwner.buildScope(framework.dart:2412)
at _LayoutBuilderElement._layout(layout_builder.dart:95)
at RenderObject.invokeLayoutCallback.
at PipelineOwner._enableMutationsToDirtySubtrees(object.dart:875)
at RenderObject.invokeLayoutCallback(object.dart:1823)
at RenderConstrainedLayoutBuilder.layoutAndBuildChild(layout_builder.dart:173)
at _RenderLayoutBuilder.performLayout(layout_builder.dart:240)
at RenderObject.layout(object.dart:1724)
at RenderProxyBoxMixin.performLayout(proxy_box.dart:105)
at RenderObject._layoutWithoutResize(object.dart:1584)
at PipelineOwner.flushLayout(object.dart:844)
at RendererBinding.drawFrame(binding.dart:344)
at WidgetsBinding.drawFrame(binding.dart:774)
at RendererBinding._handlePersistentFrameCallback(binding.dart:283)
at SchedulerBinding._invokeFrameCallback(binding.dart:1102)
at SchedulerBinding.handleDrawFrame(binding.dart:1041)
at SchedulerBinding._handleDrawFrame(binding.dart:957)

I'm confused about this Shouldn't the error widget display if the URL is somehow bad?
That is fixed in 2.3.0-beta
That is fixed in 2.3.0-beta
When we will have the version 2.3.0?
Most helpful comment
Please check that the url you've provided has a .jpg or .png or .jpeg in the line
eg.
.../7-78595_asian-businessman-png-professional-man-images-png.png <----
Hope this helps