You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This library cannot be used with flutter 3.16.0 as one of it's functions contains a method call that returns a future which is incorrectly assigned to a different type causing the compilation error.
Steps to reproduce
Install flutter
Use this library - I use DioAdapter like so: DioAdapter dioAdapter = DioAdapter(dio: myDioInstance); dioAdapter.onPost(...);
See error
../../../.pub-cache/hosted/pub.dev/http_mock_adapter-0.6.0/lib/src/mixins/request_handling.dart:32:42: Error: A value of type 'FutureOr<List<int>>' can't be assigned to a variable of type 'List<int>'.
- 'List' is from 'dart:core'.
bytes = options.requestEncoder!(data, options);
Expected behavior
Library can be used with no issues.
System details
Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel stable, 3.16.0, on macOS 14.1.1 23B81 darwin-arm64, locale en-NZ)
[✓] Android toolchain - develop for Android devices (Android SDK version 33.0.1)
[✓] Xcode - develop for iOS and macOS (Xcode 15.0.1)
[✓] Chrome - develop for the web
[✓] Android Studio (version 2022.2)
[✓] VS Code (version 1.84.2)
[✓] Connected device (3 available)
[✓] Network resources
getting exactly same error on version 0.4.4, is there any workaround for older version? I currently use flutter 3.7.0 and cannot upgrade yet because some package conflicts
Description
This library cannot be used with flutter 3.16.0 as one of it's functions contains a method call that returns a future which is incorrectly assigned to a different type causing the compilation error.
Steps to reproduce
DioAdapter dioAdapter = DioAdapter(dio: myDioInstance); dioAdapter.onPost(...);
Expected behavior
Library can be used with no issues.
System details
Additional context
Offending line:
http-mock-adapter/lib/src/mixins/request_handling.dart
Line 32 in e8298ff
The text was updated successfully, but these errors were encountered: