Learnt it the hard way

Visakh Vijayan - Aug 22 '20 - - Dev Community

So am on this quest to learn how to use graphql with flutter. And even the library says it's pretty straight forward to implement it, I ran into a strange issue recently.

Problem

The strange thing is that while using the debug apk, graphql works nicely. Once I make a build it stops working.

After a lot of time spent :'( I saw that the APIs are not being hit. Thank you Heroku for the application logs. A

Solution

Apparently you have to add the INTERNET permission in the AndroidManifest.xml file under app/src/main. So if anyone is facing the same issue just add this line in the file

<uses-permission android:name="android.permission.INTERNET"/>
Enter fullscreen mode Exit fullscreen mode

P.S. It's strange REST never threw this error.

Strange.

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .