time_machine icon indicating copy to clipboard operation
time_machine copied to clipboard

Invalid value: Not in inclusive range - Flutter Web - precalculated_datetimezone.dart

Open neil-mmhg opened this issue 2 years ago • 1 comments

Linked to issue #25

I am trying to use the package with Flutter Web. As with the other issue, I can run the app in debug, but it crashes on initialize() in release mode.

As suggested in the workaround in issue #25, I have added the .json files to my app/build/web/packages/time_machine as below: Screenshot 2023-06-01 at 11 14 53

When I try to run the release version on flutter web, I get the following error:

Uncaught RangeError (seconds): Invalid value: Not in inclusive range -64800..64800: 170814831 at Object.d (js_helper.dart:1195:37) at Object.cq (preconditions.dart:37:7) at b1n.$1 (offset.dart:255:19) at ah.cO (iterable.dart:415:31) at c9.u (iterable.dart:344:5) at Object.bPF (core_patch.dart:476:5) at Object.ae (core_patch.dart:457:39) at ah.eP (iterable.dart:214:7) at ah.eO (iterable.dart:213:11) at Object.c7k (precalculated_datetimezone.dart:163:10)

Can anyone help with this issue?

neil-mmhg avatar Jun 01 '23 17:06 neil-mmhg

It should be fixed here: https://pub.dev/packages/time_machine2

tigloo avatar Jan 06 '25 20:01 tigloo