istornz / flutter_live_activities

A Flutter plugin to use iOS 16.1+ Live Activities ⛹️ & iPhone Dynamic Island 🏝️ features
https://dimitridessus.fr/
MIT License
161 stars 48 forks source link

Unable to start Live Activity with LiveActivityImageFromUrl #81

Open lazarohcm opened 4 months ago

lazarohcm commented 4 months ago

I'm unable to start an activity when using LiveActivityImageFromUrl.

It can be reproduced with the example project, just update any of the team's logos with an image from URL and it will prevent the creation of an activity.

Here is an example of the code I used in the example project to create and activity that breaks it

footballGameLiveActivityModel = FootballGameLiveActivityModel(
  matchName: 'World cup ⚽️',
  teamAName: 'PSG',
  teamAState: 'Home',
  teamALogo: LiveActivityImageFromUrl(
      "https://www.shutterstock.com/image-vector/bart-simpson-cartoon-character-editorial-600nw-2392134361.jpg"),
  teamBLogo: LiveActivityImageFromAsset(
    'assets/images/chelsea.png',
  ),
  teamBName: 'Chelsea',
  teamBState: 'Guest',
  matchStartDate: DateTime.now(),
  matchEndDate: DateTime.now().add(
    const Duration(
      minutes: 6,
      seconds: 30,
    ),
  ),
);

Is anyone else facing this issue or able to reproduce it?