openimsdk / open-im-flutter-demo

Demo developed based on flutter open IM SDK.
https://openim.io
Apache License 2.0
301 stars 205 forks source link

Bug: SignalingInfo and other classes or missing after upgrading to flutter_openim_sdk: 3.3.0 #92

Closed enkhchuluun closed 11 months ago

enkhchuluun commented 1 year ago

What happened?

After changes to latest flutter openim sdk 3.3.0 flutter_openim_sdk: git: url: https://github.com/OpenIMSDK/Open-IM-SDK-Flutter.git Compilation is failing.

`PS C:\Users\enkhchuluunchuluunkh\wspace\open-im-flutter-demo> flutter run Launching lib\main.dart on SM A546E in debug mode... openim_common/lib/src/utils/utils.dart:1101:29: Error: 'DeptMemberInfo' isn't a type. } else if (value is DeptMemberInfo) { ^^^^^^^^^^^^^^ openim_common/lib/src/utils/utils.dart:1121:29: Error: 'DeptMemberInfo' isn't a type. } else if (value is DeptMemberInfo) { ^^^^^^^^^^^^^^ openim_common/lib/src/utils/utils.dart:1138:26: Error: 'DeptMemberInfo' isn't a type. } else if (item is DeptMemberInfo) { ^^^^^^^^^^^^^^ openim_common/lib/src/utils/utils.dart:1154:26: Error: 'DeptMemberInfo' isn't a type. } else if (item is DeptMemberInfo) { ^^^^^^^^^^^^^^ openim_common/lib/src/utils/utils.dart:1170:24: Error: 'DeptMemberInfo' isn't a type. } else if (info is DeptMemberInfo) { ^^^^^^^^^^^^^^ openim_common/lib/src/utils/utils.dart:1190:26: Error: 'DeptMemberInfo' isn't a type. } else if (item is DeptMemberInfo) { ^^^^^^^^^^^^^^ lib/core/im_callback.dart:222:28: Error: Type 'SignalingInfo' not found. void invitationCancelled(SignalingInfo info) {} ^^^^^^^^^^^^^ lib/core/im_callback.dart:225:26: Error: Type 'SignalingInfo' not found. void invitationTimeout(SignalingInfo info) {} ^^^^^^^^^^^^^ lib/core/im_callback.dart:228:24: Error: Type 'SignalingInfo' not found. void inviteeAccepted(SignalingInfo info) {} ^^^^^^^^^^^^^ lib/core/im_callback.dart:231:24: Error: Type 'SignalingInfo' not found. void inviteeRejected(SignalingInfo info) {} ^^^^^^^^^^^^^ lib/core/im_callback.dart:234:29: Error: Type 'SignalingInfo' not found. void receiveNewInvitation(SignalingInfo info) {} ^^^^^^^^^^^^^ lib/core/im_callback.dart:237:37: Error: Type 'SignalingInfo' not found. void inviteeAcceptedByOtherDevice(SignalingInfo info) {} ^^^^^^^^^^^^^ lib/core/im_callback.dart:240:37: Error: Type 'SignalingInfo' not found. void inviteeRejectedByOtherDevice(SignalingInfo info) {} ^^^^^^^^^^^^^ lib/core/im_callback.dart:243:17: Error: Type 'SignalingInfo' not found. void beHangup(SignalingInfo info) {} ^^^^^^^^^^^^^ lib/core/im_callback.dart:246:33: Error: Type 'RoomCallingInfo' not found. void roomParticipantConnected(RoomCallingInfo info) { ^^^^^^^^^^^^^^^ lib/core/im_callback.dart:250:36: Error: Type 'RoomCallingInfo' not found. void roomParticipantDisconnected(RoomCallingInfo info) { ^^^^^^^^^^^^^^^ lib/core/im_callback.dart:222:28: Error: 'SignalingInfo' isn't a type. void invitationCancelled(SignalingInfo info) {} ^^^^^^^^^^^^^ lib/core/im_callback.dart:225:26: Error: 'SignalingInfo' isn't a type. void invitationTimeout(SignalingInfo info) {} ^^^^^^^^^^^^^ lib/core/im_callback.dart:228:24: Error: 'SignalingInfo' isn't a type. void inviteeAccepted(SignalingInfo info) {} ^^^^^^^^^^^^^ lib/core/im_callback.dart:231:24: Error: 'SignalingInfo' isn't a type. void inviteeRejected(SignalingInfo info) {} ^^^^^^^^^^^^^ lib/core/im_callback.dart:234:29: Error: 'SignalingInfo' isn't a type. void receiveNewInvitation(SignalingInfo info) {} ^^^^^^^^^^^^^ lib/core/im_callback.dart:237:37: Error: 'SignalingInfo' isn't a type. void inviteeAcceptedByOtherDevice(SignalingInfo info) {} ^^^^^^^^^^^^^ lib/core/im_callback.dart:240:37: Error: 'SignalingInfo' isn't a type. void inviteeRejectedByOtherDevice(SignalingInfo info) {} ^^^^^^^^^^^^^ lib/core/im_callback.dart:243:17: Error: 'SignalingInfo' isn't a type. void beHangup(SignalingInfo info) {} ^^^^^^^^^^^^^ lib/core/im_callback.dart:246:33: Error: 'RoomCallingInfo' isn't a type. void roomParticipantConnected(RoomCallingInfo info) { ^^^^^^^^^^^^^^^ lib/core/im_callback.dart:250:36: Error: 'RoomCallingInfo' isn't a type. void roomParticipantDisconnected(RoomCallingInfo info) { ^^^^^^^^^^^^^^^ lib/pages/contacts/select_contacts/select_contacts_logic.dart:132:21: Error: 'DeptMemberInfo' isn't a type. } else if (e is DeptMemberInfo) { ^^^^^^^^^^^^^^ lib/pages/contacts/select_contacts/select_contacts_logic.dart:148:21: Error: 'DeptMemberInfo' isn't a type. } else if (e is DeptMemberInfo) { ^^^^^^^^^^^^^^ lib/pages/contacts/select_contacts/select_contacts_logic.dart:164:21: Error: 'DeptMemberInfo' isn't a type. } else if (e is DeptMemberInfo) { ^^^^^^^^^^^^^^ lib/pages/contacts/select_contacts/select_contacts_view.dart:289:24: Error: 'DeptMemberInfo' isn't a type. } else if (info is DeptMemberInfo) { ^^^^^^^^^^^^^^ lib/pages/contacts/select_contacts/search_contacts/search_contacts_logic.dart:27:42: Error: 'DeptMemberInfo' isn't a type. final friendList = result[0] as List; ^^^^^^^^^^^^^^ lib/pages/contacts/select_contacts/search_contacts/search_contacts_logic.dart:28:46: Error: 'DeptMemberInfo' isn't a type. final deptMemberList = result[1] as List; ^^^^^^^^^^^^^^ lib/pages/global_search/global_search_logic.dart:39:15: Error: Type 'DeptMemberInfo' not found. Future searchFriend() => ^^^^^^^^^^^^^^ lib/pages/global_search/global_search_logic.dart:45:27: Error: The getter 'DeptMemberInfo' isn't defined for the class 'CommonSearchLogic'.

'CommonSearchLogic' is from 'package:openim/pages/global_search/global_search_logic.dart' ('lib/pages/global_search/global_search_logic.dart'). Try correcting the name to the name of an existing getter, or defining a getter or field named 'DeptMemberInfo'. list.map((e) => DeptMemberInfo.fromJson(e.toJson())).toList()); ^^^^^^^^^^^^^^ lib/pages/global_search/global_search_logic.dart:86:21: Error: 'DeptMemberInfo' isn't a type. } else if (e is DeptMemberInfo) { ^^^^^^^^^^^^^^ lib/pages/global_search/global_search_logic.dart💯21: Error: 'DeptMemberInfo' isn't a type. } else if (e is DeptMemberInfo) { ^^^^^^^^^^^^^^ lib/pages/global_search/global_search_logic.dart:114:21: Error: 'DeptMemberInfo' isn't a type. } else if (e is DeptMemberInfo) { ^^^^^^^^^^^^^^ lib/pages/global_search/global_search_logic.dart:122:17: Error: 'DeptMemberInfo' isn't a type. if (info is DeptMemberInfo) { ^^^^^^^^^^^^^^ lib/pages/global_search/global_search_logic.dart:129:17: Error: 'DeptMemberInfo' isn't a type. if (info is DeptMemberInfo) { ^^^^^^^^^^^^^^ Target kernel_snapshot failed: Exception FAILURE: Build failed with an exception.`

What did you expect to happen?

it should run normally as noted in README.md

How can we reproduce it (as minimally and precisely as possible)?

  1. change sdk verstion to ==> flutter_openim_sdk: git: url: https://github.com/OpenIMSDK/Open-IM-SDK-Flutter.git
  2. flutter run

Anything else we need to know?

No response

version

```console $ {name} version # paste output here ```

Cloud provider

OS version

```console # On Linux: $ cat /etc/os-release # paste output here $ uname -a # paste output here # On Windows: C:\> wmic os get Caption, Version, BuildNumber, OSArchitecture # paste output here ```

Install tools

std-s commented 11 months ago

@enkhchuluun hi, Please get the latest Demo code.

std-s commented 11 months ago

No response for too long, close it temporarily.