json_model
json_model copied to clipboard
报错:'Logger.onLevelChanged' is defined here.
PS D:\workspace\mobileSpace\flutter_githubclient_app> flutter packages pub run json_model Flutter assets will be downloaded from https://storage.flutter-io.cn. Make sure you trust this source! Failed to build json_model:json_model: /C:/Users/Administrator/AppData/Local/Pub/Cache/hosted/pub.flutter-io.cn/build_runner_core-7.2.2/lib/src/logging/build_for_input_logger.dart:13:7: Error: The non-abstract class 'BuildForInputLogger' is missing implementations for these members:
- Logger.onLevelChanged Try to either
- provide an implementation,
- mark the class as abstract, or
- provide a 'noSuchMethod' implementation.
class BuildForInputLogger implements Logger { ^^^^^^^^^^^^^^^^^^^ /C:/Users/Administrator/AppData/Local/Pub/Cache/hosted/pub.flutter-io.cn/logging-1.2.0/lib/src/logger.dart:162:22: Context: 'Logger.onLevelChanged' is defined here. Stream<Level?> get onLevelChanged { ^^^^^^^^^^^^^^
我解决了这个问题,删除pubspec.lock文件,然后dart pub upgrade,应该就解决了
我也遇到了这个问题
我解决了这个问题,删除pubspec.lock文件,然后dart pub upgrade,应该就解决了
不行
I resolved the same error by following the below link: https://github.com/dart-lang/build/issues/3519#issuecomment-1722803465