Skip to content

[Web] XFile.fromData throws The following ImageCodecException was thrown resolving an image codec: #93068

Open

Description

@muddi900

Steps to Reproduce

The code that is working on Mobile Devices.

final profileImageFile = await _profileImage.readAsBytes();
        if (!kIsWeb) {
          try {
            await ref
                .putData(
                  profileImageFile,
                  fbSorage.SettableMetadata(
                    contentType: 'image/png',
                  ),
                )
                .whenComplete(() {});
          } on Exception catch (e) {
            print(e);
            return;
          }
        }

The _profileImage is the XFile When trying on the web, the uploaded file is corrupted.

The following DomException object was thrown resolving an image codec:
  EncodingError: The source image cannot be decoded.

I used the universal_html package to upload a html.Blob using putBlob method:

if (kIsWeb) {
          await ref
              .putBlob(
                html.Blob(profileImageFile),
                fbSorage.SettableMetadata(
                  contentType: 'image/png',
                ),
              )
              .whenComplete(() {});
        }

Same exception is thrown.

Flutter Run Verbose

Flutter Run
[ +189 ms] executing: [C:\flutter/] git -c log.showSignature=false log -n 1
--pretty=format:%H
[ +911 ms] Exit code 0 from: git -c log.showSignature=false log -n 1 --pretty=format:%H[   +2 ms] ffb2ecea5223acdd139a5039be2f9c796962833d
[   +2 ms] executing: [C:\flutter/] git tag --points-at
ffb2ecea5223acdd139a5039be2f9c796962833d
[ +168 ms] Exit code 0 from: git tag --points-at
ffb2ecea5223acdd139a5039be2f9c796962833d
[   +2 ms] 2.5.1
[  +31 ms] executing: [C:\flutter/] git rev-parse --abbrev-ref --symbolic @{u}
[ +103 ms] Exit code 0 from: git rev-parse --abbrev-ref --symbolic @{u}
[   +1 ms] origin/stable
[   +1 ms] executing: [C:\flutter/] git ls-remote --get-url origin
[  +92 ms] Exit code 0 from: git ls-remote --get-url origin
[   +1 ms] https://github.com/flutter/flutter.git
[ +351 ms] executing: [C:\flutter/] git rev-parse --abbrev-ref HEAD
[ +146 ms] Exit code 0 from: git rev-parse --abbrev-ref HEAD
[   +1 ms] stable
[ +165 ms] Artifact Instance of 'AndroidGenSnapshotArtifacts' is not required, skippingupdate.
[   +2 ms] Artifact Instance of 'AndroidInternalBuildArtifacts' is not required,
skipping update.
[   +1 ms] Artifact Instance of 'IOSEngineArtifacts' is not required, skipping update. 
[   +1 ms] Artifact Instance of 'FlutterWebSdk' is not required, skipping update.      
[   +9 ms] Artifact Instance of 'WindowsEngineArtifacts' is not required, skipping     
update.
[   +2 ms] Artifact Instance of 'WindowsUwpEngineArtifacts' is not required, skipping  
update.
[   +2 ms] Artifact Instance of 'MacOSEngineArtifacts' is not required, skipping       
update.
[   +1 ms] Artifact Instance of 'LinuxEngineArtifacts' is not required, skipping       
update.
[   +1 ms] Artifact Instance of 'LinuxFuchsiaSDKArtifacts' is not required, skipping
update.
[   +2 ms] Artifact Instance of 'MacOSFuchsiaSDKArtifacts' is not required, skipping   
update.
[   +2 ms] Artifact Instance of 'FlutterRunnerSDKArtifacts' is not required, skipping  
update.
[   +2 ms] Artifact Instance of 'FlutterRunnerDebugSymbols' is not required, skipping  
update.
[ +157 ms] executing: C:\Users\muddi\AppData\Local\Android\sdk\platform-tools\adb.exe
devices -l
[ +140 ms] Artifact Instance of 'AndroidGenSnapshotArtifacts' is not required, skippingupdate.
[   +2 ms] Artifact Instance of 'AndroidInternalBuildArtifacts' is not required,
skipping update.
[   +1 ms] Artifact Instance of 'IOSEngineArtifacts' is not required, skipping update. 
[   +9 ms] Artifact Instance of 'WindowsEngineArtifacts' is not required, skipping     
update.
[   +1 ms] Artifact Instance of 'WindowsUwpEngineArtifacts' is not required, skipping  
update.
[   +2 ms] Artifact Instance of 'MacOSEngineArtifacts' is not required, skipping       
update.
[   +1 ms] Artifact Instance of 'LinuxEngineArtifacts' is not required, skipping       
update.
[   +5 ms] Artifact Instance of 'LinuxFuchsiaSDKArtifacts' is not required, skipping
update.
[   +1 ms] Artifact Instance of 'MacOSFuchsiaSDKArtifacts' is not required, skipping   
update.
[   +2 ms] Artifact Instance of 'FlutterRunnerSDKArtifacts' is not required, skipping  
update.
[   +2 ms] Artifact Instance of 'FlutterRunnerDebugSymbols' is not required, skipping  
update.
[ +177 ms] executing: C:\Users\muddi\AppData\Local\Android\sdk\platform-tools\adb.exe
devices -l
[  +25 ms] Skipping pub get: version match.
[  +54 ms] Found plugin cloud_firestore at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\cloud_firestore-2.5.4\
[  +13 ms] Found plugin cloud_firestore_web at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\cloud_firestore_web-2.4.4\
[  +22 ms] Found plugin firebase_auth at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\firebase_auth-2.0.0\
[   +5 ms] Found plugin firebase_auth_web at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\firebase_auth_web-2.0.0\
[   +5 ms] Found plugin firebase_core at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\firebase_core-1.8.0\
[   +9 ms] Found plugin firebase_core_web at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\firebase_core_web-1.1.0\
[  +12 ms] Found plugin firebase_storage at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\firebase_storage-10.0.6\
[   +8 ms] Found plugin firebase_storage_web at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\firebase_storage_web-3.0.4\
[  +19 ms] Found plugin flutter_plugin_android_lifecycle at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\flutter_plugin_android_lifecycle-2.0.2\  
[  +14 ms] Found plugin image_picker at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\image_picker-0.8.4+2\
[   +5 ms] Found plugin image_picker_for_web at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\image_picker_for_web-2.1.0\
[  +10 ms] Found plugin location at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\location-4.3.0\
[   +6 ms] Found plugin location_web at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\location_web-3.1.1\
[  +23 ms] Found plugin path_provider at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\path_provider-2.0.5\
[   +4 ms] Found plugin path_provider_linux at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\path_provider_linux-2.0.2\
[   +5 ms] Found plugin path_provider_macos at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\path_provider_macos-2.0.2\
[   +4 ms] Found plugin path_provider_windows at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\path_provider_windows-2.0.3\
[  +27 ms] Found plugin sqflite at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\sqflite-2.0.0+3\
[  +10 ms] Found plugin stripe_android at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\stripe_android-1.3.0\
[   +4 ms] Found plugin stripe_ios at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\stripe_ios-1.3.0\
[  +20 ms] Found plugin url_launcher at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\url_launcher-6.0.6\
[   +6 ms] Found plugin url_launcher_linux at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\url_launcher_linux-2.0.0\
[   +5 ms] Found plugin url_launcher_macos at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\url_launcher_macos-2.0.0\
[   +8 ms] Found plugin url_launcher_web at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\url_launcher_web-2.0.1\
[   +4 ms] Found plugin url_launcher_windows at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\url_launcher_windows-2.0.0\
[   +9 ms] Found plugin video_player at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\video_player-2.2.5\
[   +4 ms] Found plugin video_player_web at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\video_player_web-2.0.4\
[   +3 ms] Found plugin wakelock at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\wakelock-0.5.6\
[   +3 ms] Found plugin wakelock_macos at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\wakelock_macos-0.4.0\
[   +5 ms] Found plugin wakelock_web at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\wakelock_web-0.4.0\
[   +4 ms] Found plugin webview_flutter at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\webview_flutter-2.0.8\
[ +167 ms] Found plugin cloud_firestore at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\cloud_firestore-2.5.4\
[   +5 ms] Found plugin cloud_firestore_web at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\cloud_firestore_web-2.4.4\
[  +13 ms] Found plugin firebase_auth at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\firebase_auth-2.0.0\
[   +8 ms] Found plugin firebase_auth_web at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\firebase_auth_web-2.0.0\
[   +3 ms] Found plugin firebase_core at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\firebase_core-1.8.0\
[   +6 ms] Found plugin firebase_core_web at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\firebase_core_web-1.1.0\
[   +6 ms] Found plugin firebase_storage at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\firebase_storage-10.0.6\
[   +4 ms] Found plugin firebase_storage_web at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\firebase_storage_web-3.0.4\
[  +12 ms] Found plugin flutter_plugin_android_lifecycle at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\flutter_plugin_android_lifecycle-2.0.2\  
[   +8 ms] Found plugin image_picker at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\image_picker-0.8.4+2\
[   +4 ms] Found plugin image_picker_for_web at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\image_picker_for_web-2.1.0\
[   +7 ms] Found plugin location at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\location-4.3.0\
[   +3 ms] Found plugin location_web at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\location_web-3.1.1\
[  +20 ms] Found plugin path_provider at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\path_provider-2.0.5\
[   +5 ms] Found plugin path_provider_linux at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\path_provider_linux-2.0.2\
[   +4 ms] Found plugin path_provider_macos at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\path_provider_macos-2.0.2\
[   +6 ms] Found plugin path_provider_windows at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\path_provider_windows-2.0.3\
[  +17 ms] Found plugin sqflite at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\sqflite-2.0.0+3\
[  +10 ms] Found plugin stripe_android at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\stripe_android-1.3.0\
[   +6 ms] Found plugin stripe_ios at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\stripe_ios-1.3.0\
[  +17 ms] Found plugin url_launcher at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\url_launcher-6.0.6\
[   +3 ms] Found plugin url_launcher_linux at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\url_launcher_linux-2.0.0\
[   +2 ms] Found plugin url_launcher_macos at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\url_launcher_macos-2.0.0\
[   +3 ms] Found plugin url_launcher_web at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\url_launcher_web-2.0.1\
[   +3 ms] Found plugin url_launcher_windows at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\url_launcher_windows-2.0.0\
[   +7 ms] Found plugin video_player at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\video_player-2.2.5\
[   +5 ms] Found plugin video_player_web at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\video_player_web-2.0.4\
[   +3 ms] Found plugin wakelock at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\wakelock-0.5.6\
[   +5 ms] Found plugin wakelock_macos at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\wakelock_macos-0.4.0\
[   +5 ms] Found plugin wakelock_web at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\wakelock_web-0.4.0\
[   +4 ms] Found plugin webview_flutter at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\webview_flutter-2.0.8\
[  +46 ms] Generating
C:\src\tennis_over_40\android\app\src\main\java\io\flutter\plugins\GeneratedPluginRegistrant.java
[ +125 ms] List of devices attached
                    emulator-5554          device product:sdk_gphone_x86_arm
                    model:AOSP_on_IA_Emulator device:generic_x86_arm transport_id:1    
[ +164 ms] Launching lib\main.dart on Chrome in debug mode...
[  +24 ms] List of devices attached
           emulator-5554          device product:sdk_gphone_x86_arm
           model:AOSP_on_IA_Emulator device:generic_x86_arm transport_id:1
[ +178 ms] Updating assets
[ +309 ms] Manifest contained wildcard assets. Inserting missing file into build graph
to force rerun. for more information see #56466.
[  +11 ms] Waiting for connection from debug service on Chrome...
[  +26 ms] Found plugin cloud_firestore at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\cloud_firestore-2.5.4\
[   +4 ms] Found plugin cloud_firestore_web at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\cloud_firestore_web-2.4.4\
[  +11 ms] Found plugin firebase_auth at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\firebase_auth-2.0.0\
[   +4 ms] Found plugin firebase_auth_web at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\firebase_auth_web-2.0.0\
[   +4 ms] Found plugin firebase_core at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\firebase_core-1.8.0\
[   +4 ms] Found plugin firebase_core_web at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\firebase_core_web-1.1.0\
[   +3 ms] Found plugin firebase_storage at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\firebase_storage-10.0.6\
[   +4 ms] Found plugin firebase_storage_web at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\firebase_storage_web-3.0.4\
[   +9 ms] Found plugin flutter_plugin_android_lifecycle at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\flutter_plugin_android_lifecycle-2.0.2\  
[   +9 ms] Found plugin image_picker at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\image_picker-0.8.4+2\
[   +3 ms] Found plugin image_picker_for_web at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\image_picker_for_web-2.1.0\
[   +7 ms] Found plugin location at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\location-4.3.0\
[   +4 ms] Found plugin location_web at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\location_web-3.1.1\
[  +11 ms] Found plugin path_provider at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\path_provider-2.0.5\
[   +3 ms] Found plugin path_provider_linux at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\path_provider_linux-2.0.2\
[   +2 ms] Found plugin path_provider_macos at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\path_provider_macos-2.0.2\
[   +4 ms] Found plugin path_provider_windows at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\path_provider_windows-2.0.3\
[  +11 ms] Found plugin sqflite at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\sqflite-2.0.0+3\
[   +6 ms] Found plugin stripe_android at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\stripe_android-1.3.0\
[   +2 ms] Found plugin stripe_ios at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\stripe_ios-1.3.0\
[  +12 ms] Found plugin url_launcher at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\url_launcher-6.0.6\
[   +2 ms] Found plugin url_launcher_linux at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\url_launcher_linux-2.0.0\
[   +3 ms] Found plugin url_launcher_macos at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\url_launcher_macos-2.0.0\
[   +5 ms] Found plugin url_launcher_web at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\url_launcher_web-2.0.1\
[   +3 ms] Found plugin url_launcher_windows at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\url_launcher_windows-2.0.0\
[   +5 ms] Found plugin video_player at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\video_player-2.2.5\
[   +5 ms] Found plugin video_player_web at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\video_player_web-2.0.4\
[   +3 ms] Found plugin wakelock at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\wakelock-0.5.6\
[   +3 ms] Found plugin wakelock_macos at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\wakelock_macos-0.4.0\
[   +4 ms] Found plugin wakelock_web at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\wakelock_web-0.4.0\
[   +3 ms] Found plugin webview_flutter at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\webview_flutter-2.0.8\
[  +34 ms] Found plugin cloud_firestore at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\cloud_firestore-2.5.4\
[   +3 ms] Found plugin cloud_firestore_web at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\cloud_firestore_web-2.4.4\
[   +8 ms] Found plugin firebase_auth at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\firebase_auth-2.0.0\
[   +5 ms] Found plugin firebase_auth_web at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\firebase_auth_web-2.0.0\
[   +3 ms] Found plugin firebase_core at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\firebase_core-1.8.0\
[   +3 ms] Found plugin firebase_core_web at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\firebase_core_web-1.1.0\
[   +2 ms] Found plugin firebase_storage at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\firebase_storage-10.0.6\
[   +4 ms] Found plugin firebase_storage_web at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\firebase_storage_web-3.0.4\
[   +8 ms] Found plugin flutter_plugin_android_lifecycle at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\flutter_plugin_android_lifecycle-2.0.2\  
[   +7 ms] Found plugin image_picker at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\image_picker-0.8.4+2\
[   +3 ms] Found plugin image_picker_for_web at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\image_picker_for_web-2.1.0\
[   +5 ms] Found plugin location at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\location-4.3.0\
[   +2 ms] Found plugin location_web at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\location_web-3.1.1\
[  +10 ms] Found plugin path_provider at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\path_provider-2.0.5\
[   +2 ms] Found plugin path_provider_linux at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\path_provider_linux-2.0.2\
[   +2 ms] Found plugin path_provider_macos at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\path_provider_macos-2.0.2\
[   +3 ms] Found plugin path_provider_windows at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\path_provider_windows-2.0.3\
[   +8 ms] Found plugin sqflite at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\sqflite-2.0.0+3\
[   +4 ms] Found plugin stripe_android at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\stripe_android-1.3.0\
[   +2 ms] Found plugin stripe_ios at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\stripe_ios-1.3.0\
[   +9 ms] Found plugin url_launcher at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\url_launcher-6.0.6\
[   +2 ms] Found plugin url_launcher_linux at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\url_launcher_linux-2.0.0\
[   +3 ms] Found plugin url_launcher_macos at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\url_launcher_macos-2.0.0\
[   +3 ms] Found plugin url_launcher_web at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\url_launcher_web-2.0.1\
[   +3 ms] Found plugin url_launcher_windows at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\url_launcher_windows-2.0.0\
[   +5 ms] Found plugin video_player at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\video_player-2.2.5\
[   +3 ms] Found plugin video_player_web at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\video_player_web-2.0.4\
[   +3 ms] Found plugin wakelock at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\wakelock-0.5.6\
[   +2 ms] Found plugin wakelock_macos at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\wakelock_macos-0.4.0\
[   +3 ms] Found plugin wakelock_web at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\wakelock_web-0.4.0\
[   +3 ms] Found plugin webview_flutter at
C:\flutter\.pub-cache\hosted\pub.dartlang.org\webview_flutter-2.0.8\
[ +216 ms] <- reset
[  +95 ms] C:\flutter\bin\cache\dart-sdk\bin\dart.exe --disable-dart-dev
C:\flutter\bin\cache\artifacts\engine\windows-x64\frontend_server.dart.snapshot        
--sdk-root C:\flutter\bin\cache\flutter_web_sdk/ --incremental --target=dartdevc       
--debugger-module-names --experimental-emit-debug-metadata
-DFLUTTER_WEB_AUTO_DETECT=true --output-dill
C:\Users\muddi\AppData\Local\Temp\flutter_tools.c0e86315\flutter_tool.c254fae0\app.dill--libraries-spec file:///C:/flutter/bin/cache/flutter_web_sdk/libraries.json --packagesC:\src\tennis_over_40\.dart_tool\package_config.json -Ddart.vm.profile=false
-Ddart.vm.product=false --enable-asserts --track-widget-creation --filesystem-root     
C:\Users\muddi\AppData\Local\Temp\flutter_tools.c0e86315\flutter_tools.a5e7cb4d        
--filesystem-scheme org-dartlang-app --initialize-from-dill
build\c7922d95bf4a2462b75c84a97c312edb.cache.dill.track.dill --platform
file:///C:/flutter/bin/cache/flutter_web_sdk/kernel/flutter_ddc_sdk.dill
--no-sound-null-safety
[  +30 ms] <- compile org-dartlang-app:/web_entrypoint.dart
[+70293 ms] Waiting for connection from debug service on Chrome... (completed in 71.0s)[   +1 ms] Synced 42.5MB.
[   +1 ms] <- accept
[   +1 ms] Caching compiled dill
[ +906 ms] [CHROME]:
[   +4 ms] [CHROME]:DevTools listening on
ws://127.0.0.1:50608/devtools/browser/c34fb2ab-a3ab-4f94-9d87-3a4c0c203e2d
[+1258 ms] DwdsInjector: Received request for entrypoint at
http://localhost:50506/main_module.bootstrap.js
[  +21 ms] MetadataProvider: Loading debug metadata...
[  +98 ms] MetadataProvider: Loaded debug metadata (no sound null safety)
[  +41 ms] DwdsInjector: Injected debugging metadata for entrypoint at
http://localhost:50506/main_module.bootstrap.js
[+10299 ms] ChromeProxyService: Initializing expression compiler for
main_module.bootstrap.js with sound null safety: false
[ +450 ms] DevHandler: Debug service listening on ws://127.0.0.1:50642/FlIxN623vd8=/ws

[  +68 ms] This app is linked to the debug service:
ws://127.0.0.1:50642/FlIxN623vd8=/ws
[  +33 ms] Debug service listening on ws://127.0.0.1:50642/FlIxN623vd8=/ws
[   +2 ms] Running with unsound null safety
[   +1 ms] For more information see https://dart.dev/null-safety/unsound-null-safety   
[  +10 ms]   To hot restart changes while running, press "r" or "R".
[   +6 ms] For a more detailed help message, press "h". To quit, press "q".
[   +5 ms] An Observatory debugger and profiler on Chrome is available at:
           http://127.0.0.1:50642/FlIxN623vd8=
[+1176 ms] Activating Dart DevTools...
[+1247 ms] WARNING: You are using the Auth Emulator, which is intended for local
testing only.  Do
                    not use with production credentials.

Flutter Analyze

Flutter Analyze
 info - Unused import: 'package:path_provider/path_provider.dart' -
          lib\screens\crop_screen.dart:7:8 - unused_import
   info - Unused import: 'dart:typed_data' - lib\screens\login_screen.dart:2:8 -
          unused_import
   info - Unused import: 'dart:convert' - lib\screens\tennis_court_select.dart:1:8 -   
          unused_import
   info - Unused import: 'package:http/http.dart' -
          lib\screens\tennis_court_select.dart:10:8 - unused_import
   info - Unused import: 'package:universal_io/io.dart' -
          lib\screens\tennis_court_select.dart:11:8 - unused_import
   info - Unused import: '../models/user_data.dart' - lib\widgets\user_avatar.dart:10:8          - unused_import

Flutter Doctor

Flutter Doctor
[√] Flutter (Channel stable, 2.5.1, on Microsoft Windows [Version 10.0.19043.1288],
    locale en-US)
    • Flutter version 2.5.1 at C:\flutter
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision ffb2ecea52 (7 weeks ago), 2021-09-17 15:26:33 -0400
    • Engine revision b3af521a05
    • Dart version 2.14.2

[√] Android toolchain - develop for Android devices (Android SDK version 30.0.2)
    • Android SDK at C:\Users\muddi\AppData\Local\Android\sdk
    • Platform android-30, build-tools 30.0.2
    • Java binary at: C:\Program Files\Android\Android Studio1\jre\bin\java
    • Java version OpenJDK Runtime Environment (build 11.0.10+0-b96-7249189)
    • All Android licenses accepted.

[√] Chrome - develop for the web
    • Chrome at C:\Program Files (x86)\Google\Chrome\Application\chrome.exe

[√] Android Studio (version 2020.3)
    • Android Studio at C:\Program Files\Android\Android Studio1
    • Flutter plugin can be installed from:
       https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
       https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build 11.0.10+0-b96-7249189)

[√] VS Code (version 1.61.2)
    • VS Code at C:\Users\muddi\AppData\Local\Programs\Microsoft VS Code
    • Flutter extension version 3.27.0

[√] Connected device (3 available)
    • AOSP on IA Emulator (mobile) • emulator-5554 • android-x86    • Android 9 (API   
      28) (emulator)
    • Chrome (web)                 • chrome        • web-javascript • Google Chrome    
      95.0.4638.69
    • Edge (web)                   • edge          • web-javascript • Microsoft Edge   
      95.0.1020.40

• No issues found!

Activity

  1. maheshj01 commented on Nov 5, 2021

    @maheshj01
    Member

    Hi @muddi900, Thanks for filing the issue. It looks like you are using a older version of flutter 2.5.1, the latest stable version is 2.5.3 can you please try upgrading by running flutter upgrade and see if that fixes the issue?

    If the issue persists please share the updated output of flutter doctor -v and a minimal and complete reproducible code that I can paste and run it (preferably a minimal flutter project).

    Thanks

  2. added
    waiting for responseThe Flutter team cannot make further progress on this issue until the original reporter responds
    on Nov 5, 2021
  3. muddi900 commented on Nov 5, 2021

    @muddi900
    Author

    Flutter Doctor After Update

    [√] Flutter (Channel stable, 2.5.3, on Microsoft Windows [Version 10.0.19043.1288],
        locale en-US)
        • Flutter version 2.5.3 at C:\flutter
        • Upstream repository https://github.com/flutter/flutter.git
        • Framework revision 18116933e7 (3 weeks ago), 2021-10-15 10:46:35 -0700
        • Engine revision d3ea636dc5
        • Dart version 2.14.4
    
    [√] Android toolchain - develop for Android devices (Android SDK version 30.0.2)
        • Android SDK at C:\Users\muddi\AppData\Local\Android\sdk
        • Platform android-30, build-tools 30.0.2
        • Java binary at: C:\Program Files\Android\Android Studio1\jre\bin\java
        • Java version OpenJDK Runtime Environment (build 11.0.10+0-b96-7249189)
        • All Android licenses accepted.
    
    [√] Chrome - develop for the web
        • Chrome at C:\Program Files (x86)\Google\Chrome\Application\chrome.exe
    
    [√] Android Studio (version 2020.3)
        • Android Studio at C:\Program Files\Android\Android Studio1
        • Flutter plugin can be installed from:
           https://plugins.jetbrains.com/plugin/9212-flutter
        • Dart plugin can be installed from:
           https://plugins.jetbrains.com/plugin/6351-dart
        • Java version OpenJDK Runtime Environment (build 11.0.10+0-b96-7249189)
    
    [√] VS Code (version 1.61.2)
        • VS Code at C:\Users\muddi\AppData\Local\Programs\Microsoft VS Code
        • Flutter extension version 3.27.0
    
    [√] Connected device (2 available)
        • Chrome (web) • chrome • web-javascript • Google Chrome 95.0.4638.69
        • Edge (web)   • edge   • web-javascript • Microsoft Edge 95.0.1020.40
    
    • No issues found!
    

    Error Message on Web

    
    ════════ Exception caught by image resource service ════════════════════════════
    The following ImageCodecException was thrown resolving an image codec:
    Failed to decode image data.
    Image source: http://localhost:9199/v0/b/tennis-over-40.appspot.com/o/images%2Ftest.png?alt=media&token=0cf12510-648a-414f-8cbf-4ae58eb0fab5
    
    When the exception was thrown, this was the stack
    C:/b/s/w/ir/cache/builder/src/out/host_debug/dart-sdk/lib/_internal/js_dev_runtime/private/ddc_runtime/errors.dart 251:49      throw_
    C:/b/s/w/ir/cache/builder/src/out/host_debug/flutter_web_sdk/lib/_engine/engine/canvaskit/image.dart 109:7                     createDefault
    C:/b/s/w/ir/cache/builder/src/out/host_debug/flutter_web_sdk/lib/_engine/engine/canvaskit/skia_object_cache.dart 222:41        new
    C:/b/s/w/ir/cache/builder/src/out/host_debug/flutter_web_sdk/lib/_engine/engine/canvaskit/image.dart 94:3                      decodeFromBytes
    C:/b/s/w/ir/cache/builder/src/out/host_debug/flutter_web_sdk/lib/_engine/engine/canvaskit/image.dart 77:53                     <fn>
    C:/b/s/w/ir/cache/builder/src/out/host_debug/dart-sdk/lib/_internal/js_dev_runtime/private/ddc_runtime/operations.dart 334:14  _checkAndCall
    C:/b/s/w/ir/cache/builder/src/out/host_debug/dart-sdk/lib/_internal/js_dev_runtime/private/ddc_runtime/operations.dart 339:39  dcall
    C:/b/s/w/ir/cache/builder/src/out/host_debug/dart-sdk/lib/html/dart2js/html_dart2js.dart 37308:58                              <fn>
    C:/b/s/w/ir/cache/builder/src/out/host_debug/dart-sdk/lib/async/zone.dart 1444:13                                              _rootRunUnary
    C:/b/s/w/ir/cache/builder/src/out/host_debug/dart-sdk/lib/async/zone.dart 1335:19                                              runUnary
    C:/b/s/w/ir/cache/builder/src/out/host_debug/dart-sdk/lib/async/zone.dart 1244:7                                               runUnaryGuarded
    C:/b/s/w/ir/cache/builder/src/out/host_debug/dart-sdk/lib/async/zone.dart 1281:26                                              <fn>
    Image provider: NetworkImage("http://localhost:9199/v0/b/tennis-over-40.appspot.com/o/images%2Ftest.png?alt=media&token=0cf12510-648a-414f-8cbf-4ae58eb0fab5", scale: 1)
    Image key: NetworkImage("http://localhost:9199/v0/b/tennis-over-40.appspot.com/o/images%2Ftest.png?alt=media&token=0cf12510-648a-414f-8cbf-4ae58eb0fab5", scale: 1)
    ════════════════════════════════════════════════════════════════════════════════
    

    Reproducible Code

    code sample

    upload_test.dart

    import 'package:flutter/cupertino.dart';
    import 'package:firebase_storage/firebase_storage.dart';
    import 'package:flutter/foundation.dart';
    import 'package:flutter/material.dart';
    import 'package:image_picker/image_picker.dart';
    
    import 'package:cross_file_image/cross_file_image.dart';
    import 'package:universal_html/html.dart' as html;
    import 'package:cached_network_image/cached_network_image.dart';
    
    import 'crop_screen.dart';
    
    class UploadTest extends StatefulWidget {
      const UploadTest({Key key}) : super(key: key);
    
      @override
      _UploadTestState createState() => _UploadTestState();
    }
    
    class _UploadTestState extends State<UploadTest> {
      XFile _profileImage;
      final storage = FirebaseStorage.instance;
      String imageUrl;
    
      Future<XFile> _imagePicker(ImageSource source) async {
        final picker = ImagePicker();
        final pickedProfileImage = await picker.pickImage(source: source);
        if (pickedProfileImage != null) {
          return pickedProfileImage;
        }
      }
    
      void uploadFile() async {
        final ref = storage.ref('images').child('test.png');
    
        final profileImageFile = await _profileImage.readAsBytes();
    
        if (!kIsWeb) {
          try {
            await ref
                .putData(
                  profileImageFile,
                  SettableMetadata(
                    contentType: 'image/png',
                  ),
                )
                .whenComplete(() {});
          } on Exception catch (e) {
            debugPrint(e.toString());
            return;
          }
        }
    
        if (kIsWeb) {
          try {
            await ref
                .putBlob(
                  html.Blob(profileImageFile.toList()),
                  SettableMetadata(
                    contentType: 'image/png',
                  ),
                )
                .whenComplete(() {});
          } on Exception catch (e) {
            print(e);
            return;
          }
        }
    
        imageUrl = await ref.getDownloadURL();
    
        setState(
          () {
            imageUrl = imageUrl;
          },
        );
      }
    
      void profileImageSelect() async {
        final tempFile = await _imagePicker(
          ImageSource.gallery,
        );
    
        final tempImage = await Navigator.push<XFile>(
          context,
          CupertinoPageRoute(
            builder: (ctx) => CropScreen(tempFile),
            fullscreenDialog: true,
          ),
        );
    
        if (tempImage == null) return;
    
        setState(() {
          _profileImage = tempImage;
        });
      }
    
      @override
      Widget build(BuildContext context) {
        return CupertinoPageScaffold(
          child: SafeArea(
            child: Column(
              mainAxisAlignment: MainAxisAlignment.center,
              crossAxisAlignment: CrossAxisAlignment.center,
              children: [
                CircleAvatar(
                  radius: 30,
                  backgroundImage: _profileImage == null
                      ? null
                      : kIsWeb
                          ? NetworkImage(_profileImage.path)
                          : XFileImage(_profileImage),
                ),
                CupertinoButton(
                  child: const Text('Get Image'),
                  onPressed: profileImageSelect,
                ),
                if (_profileImage != null)
                  CupertinoButton(
                    child: const Text('Upload File'),
                    onPressed: uploadFile,
                  ),
                if (imageUrl != null)
                  SizedBox(
                    width: 300,
                    child: Image.network(
                      imageUrl,
                    ),
                  ),
              ],
            ),
          ),
        );
      }
    }

    crop_screen.dart

    import 'dart:ui' as ui;
    import 'dart:io';
    
    import 'package:crop_image/crop_image.dart';
    import 'package:flutter/cupertino.dart';
    import 'package:flutter/foundation.dart';
    import 'package:path_provider/path_provider.dart';
    import 'package:cross_file/cross_file.dart';
    
    class CropScreen extends StatelessWidget {
      CropScreen(
        this.imageFile, {
        Key key,
      }) : super(key: key);
    
      final XFile imageFile;
    
      final cropController = CropController(
        aspectRatio: 1,
        defaultCrop: Rect.fromLTRB(
          0.1,
          0.1,
          0.9,
          0.9,
        ),
      );
    
      @override
      Widget build(BuildContext context) {
        return CupertinoPageScaffold(
          navigationBar: CupertinoNavigationBar(
            middle: const Text('Adjust Image'),
            trailing: CupertinoButton(
              child: const Text('Done'),
              onPressed: () async {
                XFile file;
    
                ui.Image croppedImage = await cropController.croppedBitmap();
    
                final data = await croppedImage.toByteData(
                  format: ui.ImageByteFormat.png,
                );
    
                final bytes = data.buffer.asUint8List();
    
                file = XFile.fromData(bytes);
    
                //file = await file.writeAsBytes(bytes, flush: true);
    
                Navigator.pop(
                  context,
                  file,
                );
              },
            ),
          ),
          child: Center(
            child: CropImage(
              controller: cropController,
              image: kIsWeb
                  ? Image.network(imageFile.path)
                  : Image.file(File(imageFile.path)),
              gridColor: CupertinoTheme.of(context).primaryColor,
            ),
          ),
        );
      }
    }

    Screenshots

    Android Web
  4. removed
    waiting for responseThe Flutter team cannot make further progress on this issue until the original reporter responds
    on Nov 5, 2021
  5. maheshj01 commented on Nov 8, 2021

    @maheshj01
    Member

    @muddi900 I see you are using a third party plugin in your code cross_file_image could you please try without that plugin using the built in XFile?

    Thanks

  6. added
    waiting for responseThe Flutter team cannot make further progress on this issue until the original reporter responds
    on Nov 8, 2021
  7. muddi900 commented on Nov 8, 2021

    @muddi900
    Author
  8. removed
    waiting for responseThe Flutter team cannot make further progress on this issue until the original reporter responds
    on Nov 8, 2021
  9. muddi900 commented on Nov 9, 2021

    @muddi900
    Author

    I did import cross_file separately. Same issue.
    Love Love Tennis - Google Chrome 11_9_2021 12_00_04 PM

  10. maheshj01 commented on Nov 9, 2021

    @maheshj01
    Member

    @muddi900 Does the image show up in your firebase storage?
    I ran your code sample the image preview does not load it looks like the upload code isn't correct for web.

    Alternatively, you may try this modified code sample, the change is in the uploadFile method it looks like you were using html Blob Object I am not really sure why would that not work.

    code sample
    import 'dart:async';
    import 'dart:io';
    import 'package:firebase_core/firebase_core.dart';
    import 'package:flutter/foundation.dart';
    import 'package:flutter/material.dart';
    import 'package:universal_html/html.dart' as html;
    import 'package:image_picker/image_picker.dart';
    import 'package:flutter/cupertino.dart';
    import 'package:firebase_storage/firebase_storage.dart';
    
    Future<void> main() async {
      WidgetsFlutterBinding.ensureInitialized();
      await Firebase.initializeApp(
          options: const FirebaseOptions(
              apiKey: "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
              authDomain: "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx.firebaseapp.com",
              projectId: "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
              storageBucket: "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
              messagingSenderId: "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
              appId: "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
              measurementId: "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"));
      runApp(UploadTest());
    }
    
    class UploadTest extends StatefulWidget {
      const UploadTest({Key key}) : super(key: key);
    
      @override
      _UploadTestState createState() => _UploadTestState();
    }
    
    class _UploadTestState extends State<UploadTest> {
      XFile _profileImage;
      final storage = FirebaseStorage.instance;
      String _imageUrl;
    
      Future<XFile> _imagePicker(ImageSource source) async {
        final picker = ImagePicker();
        final pickedProfileImage = await picker.pickImage(source: source);
        if (pickedProfileImage != null) {
          return pickedProfileImage;
        }
      }
    
      Future<UploadTask> uploadFile(XFile file) async {
        if (file == null) {
          ScaffoldMessenger.of(context).showSnackBar(const SnackBar(
            content: Text('No file was selected'),
          ));
          return null;
        }
    
        UploadTask uploadTask;
    
        final ref = storage.ref('images').child('image.png');
    
        final metadata = SettableMetadata(
            contentType: 'image/png',
            customMetadata: {'picked-file-path': file.path});
    
        if (kIsWeb) {
          uploadTask = ref.putData(await file.readAsBytes(), metadata);
        } else {
          uploadTask = ref.putFile(File(file.path), metadata);
        }
    
        return Future.value(uploadTask).then((value) async {
          _imageUrl = await ref.getDownloadURL();
          setState(() {});
        });
      }
    
      void profileImageSelect() async {
        final tempFile = await _imagePicker(
          ImageSource.gallery,
        );
        setState(() {
          _profileImage = tempFile;
        });
      }
    
      @override
      Widget build(BuildContext context) {
        return MaterialApp(
          home: Scaffold(
            body: SafeArea(
              child: Column(
                mainAxisAlignment: MainAxisAlignment.center,
                crossAxisAlignment: CrossAxisAlignment.center,
                children: [
                  _profileImage == null
                      ? Container()
                      : CircleAvatar(
                          radius: 30,
                          backgroundImage: NetworkImage(_profileImage.path)),
                  CupertinoButton(
                    child: const Text('pick Image'),
                    onPressed: profileImageSelect,
                  ),
                  if (_profileImage != null)
                    CupertinoButton(
                      child: const Text('Upload File'),
                      onPressed: () => uploadFile(_profileImage),
                    ),
                  if (_imageUrl != null)
                    SizedBox(
                      width: 300,
                      child: Image.network(
                        _imageUrl,
                      ),
                    ),
                ],
              ),
            ),
          ),
        );
      }
    }
    

    Output

  11. added
    waiting for responseThe Flutter team cannot make further progress on this issue until the original reporter responds
    on Nov 9, 2021
  12. muddi900 commented on Nov 9, 2021

    @muddi900
    Author

    I think the issue is the XFile.fromBytes I was declaring in crop_screen.dart. For some reason it does not work properly on the web. And it doesn't work properly on mobile as well. File(file.path) does not work. Which is why I am using the putData method for Firebase Storage.

  13. removed
    waiting for responseThe Flutter team cannot make further progress on this issue until the original reporter responds
    on Nov 9, 2021
  14. maheshj01 commented on Nov 9, 2021

    @maheshj01
    Member

    @muddi900 but I did not get why XFile.fromData is being used because to show a image from firebase_storage you could directly use

    _imageUrl = await ref.getDownloadURL(); // returns a download URL of image which directly works in ImageProvider
    
  15. 30 remaining items

  16. ditman commented on Jan 5, 2022

    @ditman
    Member

    Thanks!!

  17. maheshj01 commented on Jan 6, 2022

    @maheshj01
    Member

    @ditman, Thanks for the CORS link. This issue persists. I have setup CORS but when the image is downloaded it fails to decode (same exception as the author)

    Launching lib/main.dart on Chrome in debug mode...
    This app is linked to the debug service: ws://127.0.0.1:56892/dXJiiEnqv8o%3D/ws
    Debug service listening on ws://127.0.0.1:56892/dXJiiEnqv8o=/ws
    Running with unsound null safety
    For more information see https://dart.dev/null-safety/unsound-null-safety
    Connecting to VM Service at ws://127.0.0.1:56892/dXJiiEnqv8o=/ws
    
    ════════ Exception caught by image resource service ════════════════════════════
    The following ImageCodecException was thrown resolving an image codec:
    Failed to decode image data.
    Image source: https://firebasestorage.googleapis.com/v0/b/camera-triage.appspot.com/o/images%2Ftest.png?alt=media&token=07c3dfde-5b6f-47f5-9d7c-e24e021baaad
    
    When the exception was thrown, this was the stack
    dart-sdk/lib/_internal/js_dev_runtime/private/ddc_runtime/errors.dart 251:49      throw_
    lib/_engine/engine/canvaskit/image.dart 139:7                                     createDefault
    lib/_engine/engine/canvaskit/skia_object_cache.dart 222:41                        new
    lib/_engine/engine/canvaskit/image.dart 124:3                                     decodeFromBytes
    lib/_engine/engine/canvaskit/image.dart 107:53                                    <fn>
    dart-sdk/lib/_internal/js_dev_runtime/private/ddc_runtime/operations.dart 334:14  _checkAndCall
    dart-sdk/lib/_internal/js_dev_runtime/private/ddc_runtime/operations.dart 339:39  dcall
    dart-sdk/lib/html/dart2js/html_dart2js.dart 37230:58                              <fn>
    dart-sdk/lib/async/zone.dart 1444:13                                              _rootRunUnary
    dart-sdk/lib/async/zone.dart 1335:19                                              runUnary
    dart-sdk/lib/async/zone.dart 1244:7                                               runUnaryGuarded
    dart-sdk/lib/async/zone.dart 1281:26                                              <fn>
    Image provider: NetworkImage("https://firebasestorage.googleapis.com/v0/b/camera-triage.appspot.com/o/images%2Ftest.png?alt=media&token=07c3dfde-5b6f-47f5-9d7c-e24e021baaad", scale: 1)
    Image key: NetworkImage("https://firebasestorage.googleapis.com/v0/b/camera-triage.appspot.com/o/images%2Ftest.png?alt=media&token=07c3dfde-5b6f-47f5-9d7c-e24e021baaad", scale: 1)
    ════════════════════════════════════════════════════════════════════════════════

    Here's the minimal reproducible project to verify (same as above with cors.json included)
    firebase_storage 2.zip.

    Steps to reproduce

    • Run the same project flutter run -d chrome
    • Pick a image
    • crop the image (Click Done on right top)
    • Upload (Wait for uploaded image to download)
    • Exception is thrown.

    Let me know if you need any further info.

    flutter doctor -v
    [✓] Flutter (Channel stable, 2.8.1, on macOS 12.1 21C52 darwin-arm, locale en-GB)
        • Flutter version 2.8.1 at /Users/mahesh/Documents/flutter
        • Upstream repository https://github.com/flutter/flutter.git
        • Framework revision 77d935af4d (3 weeks ago), 2021-12-16 08:37:33 -0800
        • Engine revision 890a5fca2e
        • Dart version 2.15.1
    
    [✓] Android toolchain - develop for Android devices (Android SDK version 31.0.0)
        • Android SDK at /Users/mahesh/Library/Android/sdk
        • Platform android-31, build-tools 31.0.0
        • ANDROID_HOME = /Users/mahesh/Library/Android/sdk
        • Java binary at: /Applications/Android Studio.app/Contents/jre/jdk/Contents/Home/bin/java
        • Java version OpenJDK Runtime Environment (build 11.0.8+10-b944.6916264)
        • All Android licenses accepted.
    
    [✓] Xcode - develop for iOS and macOS (Xcode 13.1)
        • Xcode at /Applications/Xcode.app/Contents/Developer
        • CocoaPods version 1.10.2
    
    [✓] Chrome - develop for the web
        • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome
    
    [✓] Android Studio (version 4.2)
        • Android Studio at /Applications/Android Studio.app/Contents
        • Flutter plugin can be installed from:
          🔨 https://plugins.jetbrains.com/plugin/9212-flutter
        • Dart plugin can be installed from:
          🔨 https://plugins.jetbrains.com/plugin/6351-dart
        • Java version OpenJDK Runtime Environment (build 11.0.8+10-b944.6916264)
    
    [✓] IntelliJ IDEA Community Edition (version 2021.2.1)
        • IntelliJ at /Applications/IntelliJ IDEA CE.app
        • Flutter plugin version 60.1.4
        • Dart plugin version 212.5080.8
    
    [✓] VS Code (version 1.63.2)
        • VS Code at /Applications/Visual Studio Code.app/Contents
        • Flutter extension version 3.32.0
    
    [✓] Connected device (4 available)
        • Redmi K20 Pro (mobile) • 192.168.1.2:5555                     • android-arm64  • Android 11 (API 30)
        • iPhone 12 Pro (mobile) • B622CBB7-F906-4FA7-8F49-FACEAAC905AB • ios            • com.apple.CoreSimulator.SimRuntime.iOS-14-5 (simulator)
        • macOS (desktop)        • macos                                • darwin-arm64   • macOS 12.1 21C52 darwin-arm
        • Chrome (web)           • chrome                               • web-javascript • Google Chrome 96.0.4664.110
    
    • No issues found!
    

    Thanks

  18. ditman commented on Jan 7, 2022

    @ditman
    Member

    Let's reopen!

  19. reopened this on Jan 7, 2022
  20. removed
    r: timeoutIssue is closed due to author not providing the requested details in time
    on Jan 7, 2022
  21. removed their assignment
    on Oct 19, 2022
  22. removed
    assigned for triageissue is assigned to a domain expert for further triage
    on Feb 8, 2023
  23. unlocked this conversation on Jun 16, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    P2Important issues not at the top of the work listfound in release: 2.5Found to occur in 2.5found in release: 2.6Found to occur in 2.6has reproducible stepsThe issue has been confirmed reproducible and is ready to work onp: cross_fileThe cross_file pluginpackageflutter/packages repository. See also p: labels.platform-webWeb applications specificallyteam-webOwned by Web platform teamtriaged-webTriaged by Web platform team

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions