Android app connect

So mobile dev really tests ones patience. :slight_smile: Hoping Wappler will be investing more energy into this as it isn’t quite baked yet, but feels very close.

I now am able to retrieve server connect results and display them inside the iOS simulator. I can’t get the same in Android and could use some pointers on how to troubleshoot, OR how to fix.

The app loads into the Android emulator but when trying to submit a form that returns results, it appears the server connect action isn’t firing. I am basing this on the Android Studio profiler which does not show any network activity.

Is there a better way to debug similar to dev tools in a browser? I don.t have android device so can’t direct connect like iOS.

Any thoughts why this would work in iOS and not Android?

Anybody know mall the ins and outs of this and want to make some money teaching?

Dev is going way too slow right now. :frowning:

Try adding the path to the Server Connect forms Action to your Meta Security Policy Ken. You may have to include the corresponding remote domain and give that a go sir (ie, the full path to the Action). Or could add the path up to the dmxAppConnect directory and add a wildcard… May have some positive impact? Like below:

https://example.com/dmxAppConnect/*/

See if that helps?

In Android Studio you have Logcat which is located in the bottom left corner. Great for debugging including network traffic. Could always use something like Wireshark to monitor your network traffic for any corresponding connections relating to your Project. May also give some insight?

Understatement! :smiley:

1 Like

@mebeingken

Maybe one day we could see something similar to the following blog post from Airbnb’s dev team, Server-Driven Rendering, and a consolidated DLS environment… All available from within Wappler. Would make our respective roles that much easier as cross platform developers! :slight_smile:

1 Like

Thanks Dave,

Policy didn’t impact here.

One thought you could help with…what are the required permissions that need to be added to the manifest for network calls back to server?

I’m seeing this in the log (thanks for that tip)

 E/chromium: [ERROR:socket_posix.cc(94)] CreatePlatformSocket() failed: Operation not permitted (1)

I’m not sure I can’t say I have seen that error before? The only thing I could find on good old StackOverflow was the following, no doubt you may have already seen this though…?

1 Like

Yep, thanks.

I know I’m going to feel stupid when I finally find this! :slight_smile:

2 Likes

Yes google made android well to difficult use. It’s at least good that you have Wappler and you don’t have to go program in Java!

So all tips you are discovering here Ken! I think also Dave started once on getting started tips for Android but we can definitely use a good guide!

1 Like

I was hoping Wappler would give me a setup where I could submit a basic form though (using wkwebview since anything else will be rejected in a couple months). This is where I am stuck. iOS posts to a server project just fine, but Android does not. All I have to go on is this CreatePlatformSocket error.

Will of course keep looking!

I’m sure we could put some guides together as Ken has gone a slightly different path to myself. We did not use Framework 7 or routes in our application. I think Ken is using both, and pushing the boundaries while at it too!

:slight_smile:

1 Like

Well, I don’t feel stupid, but I did find a solution.

I added a new device to the emulator and everything worked, so I wiped the data of the existing emulator device and that broke it back in line as well.

Now I know.

2 Likes