I am trying to use the below library:
called http
when I am trying to run the code on web, I found the below error:
Compiler message:
Launching lib\main.dart on Chrome in debug mode...
main.dart:1
/C:/Users/ashra/AppData/Local/Pub/Cache/hosted/pub.dev/http-1.1.0/lib/src/browser_client.dart:79:7: Error: The getter 'completer7' isn't defined for the class 'BrowserClient'.
- 'BrowserClient' is from 'package:http/src/browser_client.dart' ('/C:/Users/ashra/AppData/Local/Pub/Cache/hosted/pub.dev/http-1.1.0/lib/src/browser_client.dart').
browser_client.dart:1
Try correcting the name to the name of an existing getter, or defining a getter or field named 'completer7'.
completer7.completeError(
^^^^^^^^^^
There is a good chance it's because you not using the latest version of flutter. You can update by running:
I ran into the same issue when the package syncfusion_flutter_sliders was added to my Flutter project and fixed it that way.
However, as mentioned above, it could also be caused by accidentally editing something you shouldn't have. But if you're sure you haven't done any as such,
flutter upgradeshould probably work. Hope it helps