dylanwuzh / flutter-cupertino-date-picker

Flutter cupertino style date picker.
Apache License 2.0
363 stars 416 forks source link

DiagnosticableMixin error on flutter master branch #111

Open songyiYu opened 4 years ago

songyiYu commented 4 years ago

Hi, I'm using your plugin and I think it's useful. but i have trouble with an error on flutter master branch. I switch to flutter master branch, when I run this error is occured.

../../.pub-cache/hosted/pub.dartlang.org/flutter_cupertino_date_picker-1.0.26/lib/src/date_picker_theme.dart:23:32: Error: Type 'DiagnosticableMixin' not found.
class DateTimePickerTheme with DiagnosticableMixin {
                               ^^^^^^^^^^^^^^^^^^^
../../.pub-cache/hosted/pub.dartlang.org/flutter_cupertino_date_picker-1.0.26/lib/src/date_picker_theme.dart:23:7: Error: The type 'DiagnosticableMixin' can't be mixed in.
class DateTimePickerTheme with DiagnosticableMixin {
      ^

FAILURE: Build failed with an exception.

No issue on stable channel, but only master channel.

I think you should review this error. Thank you!

rignaneseleo commented 4 years ago

Same issue using:

Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel dev, 1.20.0-2.0.pre, on Mac OS X 10.15.5 19F101, locale en-GB)
[✓] Android toolchain - develop for Android devices (Android SDK version 29.0.2)
[✓] Xcode - develop for iOS and macOS (Xcode 11.5)
[✓] Chrome - develop for the web
[✓] Android Studio (version 4.0)
[✓] VS Code (version 1.46.1)
[✓] Connected device (4 available)

EDIT: the problem is not present on dev v1.19.0-4.0.pre

asai569 commented 4 years ago

@songyiYu @rignaneseleo I have the same problem. How did you solve this problem?

rignaneseleo commented 4 years ago

I downgraded to dev v1.19.0-4.0.pre using flutter downgrade 1.19.0-4.0.pre

songyiYu commented 4 years ago

@songyiYu @rignaneseleo I have the same problem. How did you solve this problem?

Not yet, I'm just working on stable channel now. It's ok

Flutter 1.17.4 • channel stable

keluokeda commented 4 years ago

me too

../../../.pub-cache/hosted/pub.flutter-io.cn/flutter_cupertino_date_picker-1.0.26+2/lib/src/date_picker_theme.dart:23:32: Error: Type 'DiagnosticableMixin' not found.
class DateTimePickerTheme with DiagnosticableMixin {
                               ^^^^^^^^^^^^^^^^^^^
../../../.pub-cache/hosted/pub.flutter-io.cn/flutter_cupertino_date_picker-1.0.26+2/lib/src/date_picker_theme.dart:23:7: Error: The type 'DiagnosticableMixin' can't be mixed in.
class DateTimePickerTheme with DiagnosticableMixin {
woodstream commented 4 years ago

Removed ‘with DiagnosticableMixin’ or change 'DiagnosticableMixin' to 'Diagnosticable' and it work well for me.

naccio8 commented 4 years ago

Removed ‘with DiagnosticableMixin’ or change 'DiagnosticableMixin' to 'Diagnosticable' and it work well for me.

yes with this change it works

rodgav commented 4 years ago

Eliminado 'con DiagnosticableMixin' o cambie 'DiagnosticableMixin' a 'Diagnosticable' y funciona bien para mí.

it work for me

hoonblizz commented 4 years ago

How do we modify the package? I can't find it in the project. Any help please? Update: Sorry, figured out right away. Actually, didn't modify the package (because it's been already fixed) but just changed the dependency source in pubspec.yaml. For example,

flutter_cupertino_date_picker:
    git: https://github.com/daveleenew/flutter-cupertino-date-picker.git
Tayeb-Ali commented 4 years ago

How do we modify the package? I can't find it in the project. Any help please? Update: Sorry, figured out right away. Actually, didn't modify the package (because it's been already fixed) but just changed the dependency source in pubspec.yaml. For example,

flutter_cupertino_date_picker:
    git: https://github.com/daveleenew/flutter-cupertino-date-picker.git

this is real help . thnx Pro

sadhu1998 commented 4 years ago

I had input_sheet as dependency.... Removing it solved the issue

stickyburn commented 3 years ago

Removed ‘with DiagnosticableMixin’ or change 'DiagnosticableMixin' to 'Diagnosticable' and it work well for me.

Not the best solution as pub get will eventually update the package sometime and would return the same error.

girjeshtech9teen commented 3 years ago

Error: Type 'DiagnosticableMixin' not found.

and i am on stable channel Flutter (Channel stable, 1.22.4, how do i fix this error please let me know?

willhaslett commented 3 years ago

Is this package being maintained, or is it dead? This is a breaking error that has been around for some time and has not been addressed. This is not a complaint, I'm just wondering whether or not I should use it.

marcusforsberg commented 3 years ago

How do we modify the package? I can't find it in the project. Any help please? Update: Sorry, figured out right away. Actually, didn't modify the package (because it's been already fixed) but just changed the dependency source in pubspec.yaml. For example,

flutter_cupertino_date_picker:
    git: https://github.com/daveleenew/flutter-cupertino-date-picker.git

Thanks for this fix, the referenced repo has been working well for us. However, it seems the latest beta channel of Flutter breaks the flutter-cupertino-date-picker library yet again, so I've worked the repo again and implemented the necessary fixes. Feel free to reference our fork for now: https://github.com/winteragency/flutter-cupertino-date-picker.git