flex_color_scheme icon indicating copy to clipboard operation
flex_color_scheme copied to clipboard

`flex_color_scheme` v8.2.0 broken in Flutter 3.33

Open domesticmouse opened this issue 11 months ago • 3 comments

Just a quick heads up that flex_color_scheme is broken on master/main channel.

Relevant logs:

../../../../../.pub-cache/hosted/pub.dev/flex_color_scheme-8.2.0/lib/src/flex_color_scheme.dart:7691:11: Error: The argument type 'BottomAppBarTheme' can't be assigned to the parameter type 'BottomAppBarThemeData?'.
 - 'BottomAppBarTheme' is from 'package:flutter/src/material/bottom_app_bar_theme.dart' ('../../../../../hostedtoolcache/flutter/master-any-arm64/packages/flutter/lib/src/material/bottom_app_bar_theme.dart').
 - 'BottomAppBarThemeData' is from 'package:flutter/src/material/bottom_app_bar_theme.dart' ('../../../../../hostedtoolcache/flutter/master-any-arm64/packages/flutter/lib/src/material/bottom_app_bar_theme.dart').
          ? FlexSubThemes.bottomAppBarTheme(

hth, brett

domesticmouse avatar May 23 '25 05:05 domesticmouse

Thanks @domesticmouse for the heads up. I saw a PR or a mention somewhere that this is coming too.

The fix is simple enough. However, to use it, I need to check if the new API also already works in Flutter 3.32.x stable and maybe also in version 3.29.x.

If it works in stable 3.32.x, I can make migration fix and release it, if it also works on 3.29.x I can keep the constraint for the release to still include it as well, but no idea. Need to apply the fix and test with current and older stable versions. If it does not work in the latest stable channel at all, then I cannot release a new version that support all channels.

This annoying constant stream of breaking changes in Flutter SDK is a part of what they call "Component Theme Normalization",

https://github.com/flutter/flutter/issues/91772

Based on this, 3 more remaining Image

Basically just a bit of rename and refactor of what is where and what it is called.

Older themes used a bit different naming standards and they are trying to get read of them.

rydmike avatar May 25 '25 14:05 rydmike

Ok just checked, seems like the needed fix for master channel, is not supported on stable channel 3.32.x.

At this stage I cannot support master and stable channels at the same time with this breaking API incompatibility in place between the channels.

Added a comment in the PR that introduced this. https://github.com/flutter/flutter/pull/168586#issuecomment-2907884796

rydmike avatar May 25 '25 15:05 rydmike

Added a comment in the PR that introduced this.

Nicely written.

domesticmouse avatar May 25 '25 23:05 domesticmouse

A dev release has been added to pub to support Flutter beta 3.34.0-0 https://pub.dev/packages/flex_color_scheme/versions/8.2.1-dev.1

rydmike avatar Jul 16 '25 19:07 rydmike