The flutter project runs incorrectly #838

Closed
opened 2026-02-20 23:11:54 -05:00 by deekerman · 1 comment
Owner

Originally created by @szxv587 on GitHub (Oct 13, 2022).

I encounter the following problems when trying to run the flutter project. I would like to know how to solve them. Thank you!

lib/models/platform_model.dart:1:8: Error: Error when reading 'lib/generated_bridge.dart': 系统找不到指定的文件�?

import 'package:flutter_hbb/generated_bridge.dart';
^
lib/models/model.dart:11:8: Error: Error when reading 'lib/generated_bridge.dart': 系统找不到指定的文件�?

import 'package:flutter_hbb/generated_bridge.dart';
^
lib/models/native_model.dart:15:8: Error: Error when reading 'lib/generated_bridge.dart': 系统找不到指定的文件�?

import '../generated_bridge.dart';
^
lib/models/platform_model.dart:7:1: Error: Type 'RustdeskImpl' not found.
RustdeskImpl get bind => platformFFI.ffiBind;
^^^^^^^^^^^^
lib/models/native_model.dart:34:8: Error: Type 'RustdeskImpl' not found.
late RustdeskImpl _ffiBind;
^^^^^^^^^^^^
lib/models/native_model.dart:43:3: Error: Type 'RustdeskImpl' not found.
RustdeskImpl get ffiBind => _ffiBind;
^^^^^^^^^^^^
lib/models/native_model.dart:191:26: Error: Type 'RustdeskImpl' not found.
void _startListenEvent(RustdeskImpl rustdeskImpl) {
^^^^^^^^^^^^
lib/mobile/pages/remote_page.dart:674:56: Error: The argument type 'void Function(String?)' can't be assigned to the parameter type 'void Function(dynamic)'.
getRadio('Legacy mode', 'legacy', current, setMode,
^
lib/mobile/pages/remote_page.dart:676:50: Error: The argument type 'void Function(String?)' can't be assigned to the parameter type 'void Function(dynamic)'.
getRadio('Map mode', 'map', current, setMode,
^
lib/models/model.dart:1088:24: Error: 'Event' isn't a type.
if (message is Event) {
^^^^^
lib/models/model.dart:1095:31: Error: 'Rgba' isn't a type.
} else if (message is Rgba) {
^^^^
lib/models/native_model.dart:34:8: Error: 'RustdeskImpl' isn't a type.
late RustdeskImpl _ffiBind;
^^^^^^^^^^^^
lib/models/native_model.dart:115:18: Error: The method 'RustdeskImpl' isn't defined for the class 'PlatformFFI'.

  • 'PlatformFFI' is from 'package:flutter_hbb/models/native_model.dart' ('lib/models/native_model.dart').
    Try correcting the name to the name of an existing method, or defining a method named 'RustdeskImpl'.
    _ffiBind = RustdeskImpl(dylib);
    ^^^^^^^^^^^^
    lib/models/native_model.dart:191:26: Error: 'RustdeskImpl' isn't a type.
    void _startListenEvent(RustdeskImpl rustdeskImpl) {
    ^^^^^^^^^^^^
    lib/models/user_model.dart:93:23: Error: The argument type 'List' can't be assigned to the parameter type 'Iterable<Future>'.
  • 'List' is from 'dart:core'.
  • 'Iterable' is from 'dart:core'.
  • 'Future' is from 'dart:async'.
    await Future.wait([
    ^

FAILURE: Build failed with an exception.

  • Where:
    Script 'D:\flutter\packages\flutter_tools\gradle\flutter.gradle' line: 1156

  • What went wrong:
    Execution failed for task ':app:compileFlutterBuildDebug'.

Process 'command 'D:\flutter\bin\flutter.bat'' finished with non-zero exit value 1

  • Try:

Run with --stacktrace option to get the stack trace.
Run with --info or --debug option to get more log output.
Run with --scan to get full insights.

BUILD FAILED in 17s
Exception: Gradle task assembleDebug failed with exit code 1

Originally created by @szxv587 on GitHub (Oct 13, 2022). I encounter the following problems when trying to run the flutter project. I would like to know how to solve them. Thank you! lib/models/platform_model.dart:1:8: Error: Error when reading 'lib/generated_bridge.dart': 系统找不到指定的文件�? import 'package:flutter_hbb/generated_bridge.dart'; ^ lib/models/model.dart:11:8: Error: Error when reading 'lib/generated_bridge.dart': 系统找不到指定的文件�? import 'package:flutter_hbb/generated_bridge.dart'; ^ lib/models/native_model.dart:15:8: Error: Error when reading 'lib/generated_bridge.dart': 系统找不到指定的文件�? import '../generated_bridge.dart'; ^ lib/models/platform_model.dart:7:1: Error: Type 'RustdeskImpl' not found. RustdeskImpl get bind => platformFFI.ffiBind; ^^^^^^^^^^^^ lib/models/native_model.dart:34:8: Error: Type 'RustdeskImpl' not found. late RustdeskImpl _ffiBind; ^^^^^^^^^^^^ lib/models/native_model.dart:43:3: Error: Type 'RustdeskImpl' not found. RustdeskImpl get ffiBind => _ffiBind; ^^^^^^^^^^^^ lib/models/native_model.dart:191:26: Error: Type 'RustdeskImpl' not found. void _startListenEvent(RustdeskImpl rustdeskImpl) { ^^^^^^^^^^^^ lib/mobile/pages/remote_page.dart:674:56: Error: The argument type 'void Function(String?)' can't be assigned to the parameter type 'void Function(dynamic)'. getRadio('Legacy mode', 'legacy', current, setMode, ^ lib/mobile/pages/remote_page.dart:676:50: Error: The argument type 'void Function(String?)' can't be assigned to the parameter type 'void Function(dynamic)'. getRadio('Map mode', 'map', current, setMode, ^ lib/models/model.dart:1088:24: Error: 'Event' isn't a type. if (message is Event) { ^^^^^ lib/models/model.dart:1095:31: Error: 'Rgba' isn't a type. } else if (message is Rgba) { ^^^^ lib/models/native_model.dart:34:8: Error: 'RustdeskImpl' isn't a type. late RustdeskImpl _ffiBind; ^^^^^^^^^^^^ lib/models/native_model.dart:115:18: Error: The method 'RustdeskImpl' isn't defined for the class 'PlatformFFI'. - 'PlatformFFI' is from 'package:flutter_hbb/models/native_model.dart' ('lib/models/native_model.dart'). Try correcting the name to the name of an existing method, or defining a method named 'RustdeskImpl'. _ffiBind = RustdeskImpl(dylib); ^^^^^^^^^^^^ lib/models/native_model.dart:191:26: Error: 'RustdeskImpl' isn't a type. void _startListenEvent(RustdeskImpl rustdeskImpl) { ^^^^^^^^^^^^ lib/models/user_model.dart:93:23: Error: The argument type 'List<dynamic>' can't be assigned to the parameter type 'Iterable<Future<dynamic>>'. - 'List' is from 'dart:core'. - 'Iterable' is from 'dart:core'. - 'Future' is from 'dart:async'. await Future.wait([ ^ FAILURE: Build failed with an exception. * Where: Script 'D:\flutter\packages\flutter_tools\gradle\flutter.gradle' line: 1156 * What went wrong: Execution failed for task ':app:compileFlutterBuildDebug'. > Process 'command 'D:\flutter\bin\flutter.bat'' finished with non-zero exit value 1 * Try: > Run with --stacktrace option to get the stack trace. > Run with --info or --debug option to get more log output. > Run with --scan to get full insights. * Get more help at https://help.gradle.org BUILD FAILED in 17s Exception: Gradle task assembleDebug failed with exit code 1
deekerman 2026-02-20 23:11:54 -05:00
  • closed this issue
  • added the
    bug
    label
Author
Owner

@rustdesk commented on GitHub (Oct 13, 2022):

#763

@rustdesk commented on GitHub (Oct 13, 2022): #763
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/rustdesk-rustdesk#838
No description provided.