Closed ksmsk closed 4 years ago
Not sure this error somehow related to mapper, could you please provide more consistent information. At least error stack trace should contain mapper source code or mobx adapter code
Hey @k-paxian, i made a repository to reproduce the problem. https://github.com/ksmsk/json_mapper_bug_reprod
btw im using flutter beta channel. I forgot to mention that.
Flutter 1.19.0-4.1.pre • channel beta • https://github.com/flutter/flutter.git
Framework • revision f994b76974 (7 days ago) • 2020-06-09 15:53:13 -0700
Engine • revision 9a28c3bcf4
Tools • Dart 2.9.0 (build 2.9.0-14.1.beta)
update: I dig into problem and found out the problem related to flutter beta channel's analyzer. related issue: https://github.com/dart-lang/reflectable/issues/210. reverting flutter channel to stable fixed the issue.
slightly off-topic:
when will you update dart_json_mapper
to build_runner_core 6
? Latest build_runner
no longer compatible with dart_json_mapper
.
yep, reflectable
library is sensible to analyzer version. Well dart_json_mapper
depends heavily on reflectable
library, so once it will be updated to the latest build_runner
according to this issue
https://github.com/dart-lang/reflectable/issues/209
then dart_json_mapper
will be aligned too.
Thank you for investigation efforts :)
dependencies:
There is this error
type '() => (_SyncIterator<PropertyAccessorElement>) => bool' is not a subtype of type '() => (_SyncIterator<ExecutableElement>) => bool'
when usingmobx_codegen
anddart_json_mapper
together. Eventhough it says build failed, it still manages to generate successfully.here's the code:
BaseModel
contains helper methods nothing else. I tried with constructors aswell still same error.