Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

When using dio.download for a streamed download it crashes #5

Closed
d-silveira opened this issue Feb 14, 2020 · 1 comment
Closed

When using dio.download for a streamed download it crashes #5

d-silveira opened this issue Feb 14, 2020 · 1 comment

Comments

@d-silveira
Copy link

d-silveira commented Feb 14, 2020

I'm using an instance of dio with custom configurations for all my app requests, I have responseBody logging enabled, which works perfectly for most of my requests.
Unfortunately for dio.download it crashes because body is not a String.

type 'ResponseBody' is not a subtype of type 'String'
#0      PrettyDioLogger._printResponse (package:pretty_dio_logger/pretty_dio_logger.dart:148:30)
#1      PrettyDioLogger.onResponse (package:pretty_dio_logger/pretty_dio_logger.dart:124:7)
#2      DioMixin._request._interceptorWrapper.<anonymous closure>.<anonymous closure>.<anonymous closure> (package:dio/src/dio.dart:828:37)
#3      DioMixin.checkIfNeedEnqueue (package:dio/src/dio.dart:1099:22)
#4      DioMixin._request._interceptorWrapper.<anonymous closure>.<anonymous closure> (package:dio/src/dio.dart:825:22)
#5      new Future.<anonymous closure> (dart:async/future.dart:176:37)
#6      _rootRun (dart:async/zone.dart:1122:38)
#7      _CustomZone.run (dart:async/zone.dart:1023:19)
#8      _CustomZone.runGuarded (dart:async/zone.dart:925:7)
#9      _CustomZone.bindCallbackGuarded.<anonymous closure> (dart:async/zone.dart:965:23)
#10     _rootRun (dart:async/zone.d<…>
@Milad-Akarie
Copy link
Owner

hey @d-silveira, I believe this's been fixed before, are you sure you're using the latest version v1.1.0?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants