Closed delphi007 closed 1 year ago
I have the same problem here. Using conduit 4.3.6 Dart 2.19.4 Debian
@delphi007 @pst9354 can you both try purging all the conduit packages from pub cache and try rerunning conduit build?
Same error after cleaning cache.
This might be an issue "hosted/pub.flutter-io.cn" @pst9354 what location are you using for your cache?
taxiteknik@vps-NPvKz:~/.pub-cache$ ls -l hosted total 4 drwxr-xr-x 93 taxiteknik taxiteknik 4096 Mar 15 15:23 pub.dev
@j4qfrost After 'rm -rf conduit' in hosted/pub.flutter-io.cn and 'dart pub get' , I got the same error from 'conduit build'. Then I switched the pub repository back to pub.dev, remove 'conduit', rerun 'dart pub get & conduit build', the same error.
Btw, the version of each conduit package is in the picture. From the 'conduit build' output , Conduit Cli is 4.3.9, Conduit Project version is 4.3.8, although I specified the project the conduit plugin version 4.3.9 in pubspec.yaml. Just FYI.
add this code import 'package:conduit_runtime/src/analyzer.dart';
@youfameifa this perfectly solve the problem. @j4qfrost Would it be possible to add this line in migration_source.dart for the next release?
Describe the bug conduit build fail
To Reproduce Steps to reproduce the behavior:
See error -- Conduit CLI Version: 4.3.9 -- Conduit project version: 4.3.8 Starting build process... Resolving ASTs... Generating runtime... Generated runtime at 'file:///tmp/build/generated_runtime/'. Compiling package 'conduit_runtime'... Package 'conduit_runtime' compiled to 'file:///tmp/build/packages/conduit_runtime/'. Compiling package 'conduit_core'... Package 'conduit_core' compiled to 'file:///tmp/build/packages/conduit_core/'. Compiling package 'conduit_config'... Package 'conduit_config' compiled to 'file:///tmp/build/packages/conduit_config/'. Copying application package (from 'file:///Users/delphi/workdir/vda_auto_server/')... Application packaged copied to 'file:///tmp/build/packages/vda_auto_server/'. Fetching dependencies (--offline --no-precompile)... Finished fetching dependencies. Compiling... *** Uncaught error Bad state: Bad state: 'dart2native' failed with the following message: Info: Compiling with sound null safety. /Users/delphi/.pub-cache/hosted/pub.flutter-io.cn/conduit-4.3.9/lib/src/migration_source.dart:21:22: Error: Method not found: 'CodeAnalyzer'. final analyzer = CodeAnalyzer(uri); Error: AOT compilation failed Generating AOT kernel dill failed!
0 generateNative (package:dart2native/generate.dart:72:7)
Expected behavior build success
Analysis Actually this is not what my project error but conduit. Have checked pub_cache, the conduit_runtime/4.3.7 exist which include the CodeAnalyzer class definition.
System Information: