I downloaded the "flutter_weather" example from here.And run "flutter packages get", I got an error after I run "flutter run"
_flutter: βββ‘ EXCEPTION CAUGHT BY WIDGETS LIBRARY ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
flutter: The following _CompileTimeError was thrown attaching to the render tree:
flutter: 'package:bloc/src/bloc.dart': error: line 24 pos 44:
flutter: file:///Users/xxxxx/flutter/.pub-cache/hosted/pub.dartlang.org/bloc-0.7.8/lib/src/bloc.dart:24:44:
flutter: Error: No named parameter with the name 'seedValue'.
flutter: _stateSubject = BehaviorSubject
flutter: ^^^^^^^^^
flutter: _stateSubject = BehaviorSubject
I don't understand what this problem means. Someone who knows?? Please help me
Hey @MorLightJ, just now took a clone and it works like charm. Worth to check by doing a flutter clean
and get packages again. Also check the bloc package path in pubspec.yaml
file
flutter_bloc:
path: ../../packages/flutter_bloc
My bloc package version in external libraries when I get packages is bloc-0.9.3
.
Hope these findings may help you. Cheers!
@dhar619 I ran "flutter clean"οΌand get packages again. The same error..
How can I upgrade the bloc version at this path "file:///Users/xxxxx/flutter/.pub-cache/hosted/pub.dartlang.org/bloc-0.7.8/lib/src/bloc.dart:24:44:" ?
@MorLightJ I am new to flutter mate, still digging on it. My path is flutter_bloc: path: ../../packages/flutter_bloc
The package came from the repo https://github.com/felangel/bloc/tree/master/packages/flutter_bloc
@MorLightJ this is a duplicate of #104. The problem is rxdart v0.21.0 introduced breaking changes so you should just need to use bloc v0.9.3.
Try deleting your .packages and pubspec.lock and then running flutter packages get. Somehow it seems like you're using bloc v0.7.8 which is really old.
Let me know if that helps.
Same issue, works on my mac, but not in CI.
@Ogiwara-CostlierRain464 did you try running flutter clean first?
Does flutter clean
step is required for CI?
I'm just going to publish an update of flutter_bloc and angular_bloc that forces the latest bloc version which should solve everyone's problems. Give me 5 mins and it should be ready.
By adding bloc: ^0.9.3
to pubspec.yaml, it works!
@Ogiwara-CostlierRain464 yeah something weird is happening with the pubspec version resolution. flutter_bloc requires bloc ^0.9.0 which should take the latest 0.9.x but it seems like it's not working as expected for some people. As soon as #107 is merged everything should just work without having to manually add bloc: ^0.9.3
So I was using flutter_bloc: ^0.6.2
,and
local machine was using bloc-0.9.3
but CI was using other version of bloc.
Please update to the latest version of flutter_bloc
and angular_bloc
and things should be back to normal.
dependencies:
flutter_bloc: ^0.6.3
dependencies:
angular_bloc: ^0.4.3
@MorLightJ, @dhar619 , @Ogiwara-CostlierRain464 can you please confirm that things are working? I'll keep this open until then.
I'm running CI at here
...and also at here
(former is building android on Bitrise, latter is building ios on Azure Pileline)
@felangel works like a charm at my end. Thanks! π
It's working, Thanks!π
Closing this for now.
@MorLightJ if you're still having trouble just let me know! π
Thanks, It works.
Most helpful comment
I'm just going to publish an update of flutter_bloc and angular_bloc that forces the latest bloc version which should solve everyone's problems. Give me 5 mins and it should be ready.