yoktavian / time-picker-sheet

Time picker sheet library
Apache License 2.0
2 stars 11 forks source link

No named parameter with the name 'primary' #3

Open masalha-alaa opened 9 months ago

masalha-alaa commented 9 months ago

I started getting the following error after updating flutter to version 3.19.1:

Running Gradle task 'assembleDebug'...
../AppData/Local/Pub/Cache/hosted/pub.dev/time_picker_sheet-0.0.2+1/lib/widget/composition/body.dart:222:17: Error: No named parameter with the name 'primary'.
                primary: provider.saveButtonColor,
                ^^^^^^^
../flutter/packages/flutter/lib/src/material/elevated_button.dart:151:22: Context: Found this candidate, but the arguments don't match.
  static ButtonStyle styleFrom({
                     ^^^^^^^^^
Target kernel_snapshot failed: Exception

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':app:compileFlutterBuildDebug'.
> Process 'command 'path\to\flutter\bin\flutter.bat'' finished with non-zero exit value 1

* Try:
> Run with --stacktrace option to get the stack trace.
> Run with --info or --debug option to get more log output.
> Run with --scan to get full insights.

* Get more help at https://help.gradle.org

BUILD FAILED in 7s
Error: Gradle task assembleDebug failed with exit code 1

Any idea how to solve this? I have the following in pubspec.yaml: time_picker_sheet: ^0.0.2+1

I tried deleting pubspeck.lock, running flutter clean, flutter pub cache repair, flutter pub get, nothing helped.

Thanks

tigranelyazyan commented 9 months ago

Hi @masalha-alaa I fixed the issue in this PR. @yoktavian Could you please check?