Closed wade-liwei closed 4 years ago
@wade-liwei Please make sure you satisfy the development requirements. Also, once you made sure that you have the proper Flutter version installed, you need to run the following commands:
flutter pub get
flutter pub run build_runner build
This should generate all the code properly
I have try the cmd:
flutter upgrade flutter pub get flutter pub run build_runner build
and: flutter version 1.20.0 flutter pub get flutter pub run build_runner build
same errors happen:
(base) adeMacBook-Pro:mooncake a$ flutter pub run build_runner build Precompiling executable... Failed to precompile build_runner:build_runner: ../../../../../.pub-cache/hosted/pub.flutter-io.cn/build_resolvers-1.3.7/lib/src/resolver.dart:343:10: Error: Method not found: 'SummaryBuilder'. return SummaryBuilder(sdkSources, sdk.context) ^^^^^^^^^^^^^^ ../../../../../.pub-cache/hosted/pub.flutter-io.cn/build_resolvers-1.3.7/lib/src/resolver.dart:332:7: Error: The setter 'useSummary' isn't defined for the class 'FolderBasedDartSdk'.
can not run the cmd one by one: $ flutter version 1.20.0 $ flutter upgrade
I have to checkout stable branch after the cmd " flutter version 1.20.0"
@RiccardoM these days too tired, Thank you help me.
After talking on Discord, I'm closing this as it surely is a network problem and we can't reproduce it.
Could you please help me fix the following errors. I have tested v0.4.1 and v0.4.0, I am a flutter beginner.
(base) adeMacBook-Pro:mooncake a$ flutter run Running "flutter pub get" in mooncake... 3.3s Using hardware rendering with device sdk gphone x86. If you get graphics artifacts, consider enabling software rendering with "--enable-software-rendering". Launching lib/main.dart on sdk gphone x86 in debug mode...
Compiler message: lib/ui/blocs/simple_bloc_delegate.dart:3:34: Error: Type 'BlocDelegate' not found. class SimpleBlocDelegate extends BlocDelegate {
^^^^^^^^^^^^
lib/main.dart:29:5: Error: Getter not found: 'BlocSupervisor'.
BlocSupervisor.delegate = SimpleBlocDelegate();
^^^^^^^^^^^^^^
lib/sources/dependency_injection.dart:41:21: Error: Too many positional arguments: 0 allowed, but 1 found. Try removing the extra positional arguments.
link: HttpLink(
^
../../../../../.pub-cache/hosted/pub.flutter-io.cn/graphql-3.1.0/lib/src/link/http/link_http.dart:21:3: Context: Found this candidate, but the arguments don't match. HttpLink({
^^^^^^^^
lib/sources/dependency_injection.dart:45:29: Error: Too many positional arguments: 0 allowed, but 1 found. Try removing the extra positional arguments.
).concat(WebSocketLink(
^
../../../../../.pub-cache/hosted/pub.flutter-io.cn/graphql-3.1.0/lib/src/link/web_socket/link_web_socket.dart:16:3 : Context: Found this candidate, but the arguments don't match. WebSocketLink({
^^^^^^^^^^^^^
lib/sources/dependency_injection.dart:50:14: Error: The method 'GraphQLCache' isn't defined for the class 'SourcesModule'.
^^^^^^^^^^^^
lib/ui/blocs/simple_bloc_delegate.dart:6:11: Error: Superclass has no method named 'onEvent'. super.onEvent(bloc, event);
^^^^^^^
lib/ui/blocs/simple_bloc_delegate.dart:12:11: Error: Superclass has no method named 'onTransition'. super.onTransition(bloc, transition);
^^^^^^^^^^^^
lib/ui/blocs/simple_bloc_delegate.dart:18:11: Error: Superclass has no method named 'onError'. super.onError(bloc, error, stacktrace);
^^^^^^^
lib/ui/blocs/home/home_bloc.dart:23:3: Error: The superclass, 'Bloc<HomeEvent, HomeState>', has no unnamed constructor that takes no arguments. HomeBloc({
^^^^^^^^
lib/ui/blocs/mnemonic/mnemonic_bloc.dart:23:3: Error: The superclass, 'Bloc<MnemonicEvent, MnemonicState>', has no unnamed constructor that takes no arguments. MnemonicBloc({
^^^^^^^^^^^^
lib/ui/blocs/navigator/navigator_bloc.dart:20:3: Error: The superclass, 'Bloc<NavigatorEvent, void>', has no unnamed constructor that takes no arguments. NavigatorBloc({
^^^^^^^^^^^^^
lib/ui/blocs/notifications/notifications_bloc.dart:16:3: Error: The superclass, 'Bloc<NotificationsEvent, NotificationsState>', has no unnamed constructor that takes no arguments. NotificationsBloc({
^^^^^^^^^^^^^^^^^
lib/ui/blocs/recover_account/recover_account_bloc.dart:12:3: Error: The superclass, 'Bloc<RecoverAccountEvent, RecoverAccountState>', has no unnamed constructor that takes no arguments. RecoverAccountBloc();
^^^^^^^^^^^^^^^^^^
lib/ui/blocs/restore_backup/restore_backup_bloc.dart:22:3: Error: The superclass, 'Bloc<RestoreBackupEvent, RestoreBackupState>', has no unnamed constructor that takes no arguments. RestoreBackupBloc({
^^^^^^^^^^^^^^^^^
lib/ui/screens/user/wallet_screen.dart:27:7: Error: No named parameter with the name 'bloc'. bloc: BlocProvider.of
../../../../../.pub-cache/hosted/pub.flutter-io.cn/flutter_bloc-6.0.1/lib/src/bloc_builder.dart:75:9: Context: Found this candidate, but the arguments don't match. const BlocBuilder({
^^^^^^^^^^^
lib/ui/blocs/account/edit/edit_account_bloc.dart:20:3: Error: The superclass, 'Bloc<EditAccountEvent, EditAccountState>', has no unnamed constructor that takes no arguments. EditAccountBloc(
^^^^^^^^^^^^^^^
lib/ui/blocs/account/read/account_bloc.dart:30:3: Error: The superclass, 'Bloc<AccountEvent, AccountState>', has no unnamed constructor that takes no arguments. AccountBloc({
^^^^^^^^^^^
lib/ui/blocs/posts/post_details/post_details_bloc.dart:24:3: Error: The superclass, 'Bloc<PostDetailsEvent, PostDetailsState>', has no unnamed constructor that takes no arguments. PostDetailsBloc({
^^^^^^^^^^^^^^^
lib/ui/blocs/posts/post_input/post_input_bloc.dart:28:3: Error: The superclass, 'Bloc<PostInputEvent, PostInputState>', has no unnamed constructor that takes no arguments. PostInputBloc({
^^^^^^^^^^^^^
lib/ui/blocs/posts/posts_list/posts_list_bloc.dart:44:3: Error: The superclass, 'Bloc<PostsListEvent, PostsListState>', has no unnamed constructor that takes no arguments. PostsListBloc({
^^^^^^^^^^^^^
lib/ui/blocs/posts/report_popup/report_popup_bloc.dart:23:3: Error: The superclass, 'Bloc<ReportPopupEvent, ReportPopupState>', has no unnamed constructor that takes no arguments. ReportPopupBloc({
^^^^^^^^^^^^^^^
lib/ui/blocs/security/biometrics/biometrics_bloc.dart:24:3: Error: The superclass, 'Bloc<BiometricsEvent, BiometricsState>', has no unnamed constructor that takes no arguments. BiometricsBloc({
^^^^^^^^^^^^^^
lib/ui/blocs/security/password/set_password_bloc.dart:21:3: Error: The superclass, 'Bloc<SetPasswordEvent, SetPasswordState>', has no unnamed constructor that takes no arguments. SetPasswordBloc({
^^^^^^^^^^^^^^^
lib/sources/posts/remote/remote_posts_source.dart:63:33: Error: The method 'SubscriptionOptions' isn't defined for the class 'RemotePostsSourceImpl'.
lib/sources/user/remote/helpers/gql_users_helper.dart:40:19: Error: The argument type 'DocumentNode' can't be assigned to the parameter type 'String'.
('../../../../../.pub-cache/hosted/pub.flutter-io.cn/gql-0.12.3/lib/src/ast/ast.dart'). document: gql(query),
^
lib/sources/posts/remote/helpers/gql_posts_helper.dart:133:19: Error: The argument type 'DocumentNode' can't be assigned to the parameter type 'String'.
('../../../../../.pub-cache/hosted/pub.flutter-io.cn/gql-0.12.3/lib/src/ast/ast.dart'). document: gql(query),
^
lib/sources/posts/remote/helpers/gql_posts_helper.dart:162:17: Error: The argument type 'DocumentNode' can't be assigned to the parameter type 'String'.
('../../../../../.pub-cache/hosted/pub.flutter-io.cn/gql-0.12.3/lib/src/ast/ast.dart'). document: gql(query),
^
lib/sources/posts/remote/helpers/gql_posts_helper.dart:189:17: Error: The argument type 'DocumentNode' can't be assigned to the parameter type 'String'.
('../../../../../.pub-cache/hosted/pub.flutter-io.cn/gql-0.12.3/lib/src/ast/ast.dart'). document: gql(query),
^
Exception in thread "main" java.net.ConnectException: Operation timed out (Connection timed out) at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:350) at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:206) at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:188) at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392)
at java.net.Socket.connect(Socket.java:607)
at sun.security.ssl.SSLSocketImpl.connect(SSLSocketImpl.java:666) at sun.security.ssl.BaseSSLSocketImpl.connect(BaseSSLSocketImpl.java:173) at sun.net.NetworkClient.doConnect(NetworkClient.java:180)
at sun.net.www.http.HttpClient.openServer(HttpClient.java:463)
at sun.net.www.http.HttpClient.openServer(HttpClient.java:558)
at sun.net.www.protocol.https.HttpsClient.
at org.gradle.wrapper.Install$1.call(Install.java:61)
at org.gradle.wrapper.Install$1.call(Install.java:48)
at org.gradle.wrapper.ExclusiveFileAccessManager.access(ExclusiveFileAccessManager.java:65) at org.gradle.wrapper.Install.createDist(Install.java:48)
at org.gradle.wrapper.WrapperExecutor.execute(WrapperExecutor.java:128) at org.gradle.wrapper.GradleWrapperMain.main(GradleWrapperMain.java:61) Running Gradle task 'assembleDebug'...
Running Gradle task 'assembleDebug'... Done 76.6s Exception: Gradle task assembleDebug failed with exit code 1