โโโโโโโโ Exception caught by SVG โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
The following JSNoSuchMethodError was thrown resolving a single-frame picture stream:
NoSuchMethodError: tried to call a non-function, such as null: 'this.function._equals'
packages/petitparser/src/definition/reference.dart 19:11 _equals
dart-sdk/lib/_internal/js_dev_runtime/private/ddc_runtime/operations.dart 687:60 equals
dart-sdk/lib/_internal/js_dev_runtime/private/linked_hash_map.dart 147:17 _get
packages/petitparser/src/definition/grammar.dart 138:27 _dereference
packages/petitparser/src/definition/grammar.dart 163:30 [_resolve]
...
Picture provider: ExactAssetPicture(name: "res/icons/plus.svg", bundle: null, colorFilter: null)
Picture key: AssetBundlePictureKey(bundle: PlatformAssetBundle#526cb(), name: "res/icons/plus.svg", colorFilter: null)
โโโโโโโโ Exception caught by SVG โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
NoSuchMethodError: tried to call a non-function, such as null: 'this.function._equals'
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โโโโโโโโ Exception caught by SVG โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
NoSuchMethodError: tried to call a non-function, such as null: 'this.function._equals'
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
everything was working just a 2 days ago , after i updated flutter and pubspec.yaml , all svgs' in my app are not working they show nothing,
Can you share an SVG and pubspec that recreates this? Or perhaps an entire project?
It'd be helpful to note which version of Flutter as well (which commit).
https://github.com/phaylali/albourane/tree/master/admin
I SHOULD NOTE THAT THE PROBLEM HAPPENS ON FLUTTER WEB, LATEST DEV CHANNEL
if it didn't work just make a firebase-config.js in the web folder and put some dummy project credentials there
in the HomePage you'll find a "MainBody" widget which had a custom drawer, i made a class called OmniIcons to put the svgs there , put i also tried it directly and it didn't work
Flutter is already up to date on channel dev
Flutter 2.2.0-10.1.pre โข channel dev โข https://github.com/flutter/flutter.git
Framework โข revision 0941968447 (3 days ago) โข 2021-04-15 12:01:02 -0700
Engine โข revision d2a2e93510
Tools โข Dart 2.13.0 (build 2.13.0-211.6.beta)
i tried it on flutter stable , and it's working fine on the web, i'm closing this issue for now , but there might be some issue in the future releases that may break all packages depending on svg
I don't think this issue should be closed. I am seeing the same issue on the Flutter beta channel. It affects all SVGs in my web project. It seems very likely that this will be a major issue in the next Flutter stable release.
@dnfield
https://github.com/doppio/svg_error_example Here is a very simple example project that just displays a simple icon SVG.
When you run it web using the latest Flutter beta (v2.2.0-10.1.pre, commit 0941968), you'll see that no image is displayed and the exception reported by @phaylali is printed to the console. The project works as expected on the stable channel (v2.0.5, commit adc6878) as well as the _previous_ beta release (v2.1.0-12.2.pre, commit 5bedb7b).
@dnfield
https://github.com/doppio/svg_error_example Here is a very simple example project that just displays a simple icon SVG.When you run it web using the latest Flutter beta (v2.2.0-10.1.pre, commit 0941968), you'll see that no image is displayed and the exception reported by @phaylali is printed to the console. The project works as expected on the stable channel (v2.0.5, commit adc6878) as well as the _previous_ beta release (v2.1.0-12.2.pre, commit 5bedb7b).
Yeah, that's why the developer must investigate what's causing that, because if what causing that got merged in the stable channel, the package and all packages depending on it will break (yes i tried other packages that depend on this one and they didn't work) having it work on stable, is more of a temporary workaround rather than a solution,
In that case, would you mind re-opening the issue @phaylali?
I'm able to reproduce this easily with the example SVG app in this repo.
This seems like abug in DDC.
This is a bug in ddc.
Minimal repro:
void main() {
Function f1 = () { print('f1'); };
Function f2 = () { print('f2'); };
print(f1 == f2);
}
You'll find it works in profile or release mode, but not debug mode, because of DDC.
Filed https://github.com/dart-lang/sdk/issues/45762, closing this issue in favor of that one.
@dnfield I poked around the issues and they all appear to claim that the issue above was resolved by a cherry picked commit on beta... but we're getting this issue on dev. any visibility on this being fixed in dev?
Flutter 2.2.0-10.1.pre โข channel dev โข https://github.com/flutter/flutter.git
Framework โข revision 0941968447 (11 days ago) โข 2021-04-15 12:01:02 -0700
Engine โข revision d2a2e93510
Tools โข Dart 2.13.0 (build 2.13.0-211.6.beta)
โโโโโโโโ Exception caught by SVG โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
NoSuchMethodError: tried to call a non-function, such as null: 'this.function._equals'
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โโโโโโโโ Exception caught by SVG โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
NoSuchMethodError: tried to call a non-function, such as null: 'this.function._equals'
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โโโโโโโโ Exception caught by SVG โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
NoSuchMethodError: tried to call a non-function, such as null: 'this.function._equals'
@dnfield I'm trying to get visibility on where this fix is in relation to the dev flutter/flutter channel. I haven't been able to find a way to really understand where the cherry pick is. Our team is currently unable to run the app on web in dev mode which is blocking one of our developes so I'm trying to find some relief.
Just got the same issue, is there a workaround meanwhile?
Flutter's latest beta channel has the fix for this.
Flutter's latest beta channel has the fix for this.
On the master channel I still have the issue, so that's pretty strange
It's been cherry picked into beta specifically.
AFAIK, it should also be fixed on master though... Are you sure you're up to date with the latest revision?
Are you sure you're up to date with the latest revision?
Pretty sure!
Flutter doctor output
Doctor summary (to see all details, run flutter doctor -v):
[โ] Flutter (Channel master, 2.3.0-1.0.pre.181, on macOS 11.3 20E232 darwin-x64, locale en-GB)
[โ] Android toolchain - develop for Android devices (Android SDK version 30.0.2)
[โ] Xcode - develop for iOS and macOS
[โ] Chrome - develop for the web
[โ] Android Studio (version 4.1)
[โ] VS Code (version 1.55.2)
[โ] Connected device (2 available)
! Error: iPhone is not connected. Xcode will continue when iPhone is connected. (code -13)
โข No issues found!
This is resolved on dev channel FWIW
Most helpful comment
Filed https://github.com/dart-lang/sdk/issues/45762, closing this issue in favor of that one.