2

Running server locally. Tested client via all browsers, works well, but once on Cordova and trying it on Simulator (as well as on device), it fails with (per Safari Technology Preview):

WebSocket connection to 'ws://192.X.X.X:5000/socket.io/?EIO=4&transport=websocket' failed: Unexpected response code: 400

Using

  • Cordova version 10.0.0
  • Socket.IO v3.0.4 (flask-SocketIO)
  • Python 3.9.4

config.xml

<?xml version='1.0' encoding='utf-8'?>
<widget id="com.X.X" version="1.0.0" xmlns="http://www.w3.org/ns/widgets" xmlns:cdv="http://cordova.apache.org/ns/1.0">
    <name>X</name>
    <description>
        A sample Apache Cordova application that responds to the deviceready event.
    </description>
    <author email="dev@cordova.apache.org" href="http://cordova.io">
        Apache Cordova Team
    </author>
    <content src="index.html" />
    <access origin="*" />
    <allow-navigation href="*" />
    <allow-intent href="*" />
    <allow-intent href="http://*/*" />
    <allow-intent href="https://*/*" />
    <allow-intent href="tel:*" />
    <allow-intent href="sms:*" />
    <allow-intent href="mailto:*" />
    <allow-intent href="geo:*" />
    <platform name="android">
        <allow-intent href="market:*" />
    </platform>
    <platform name="ios">
        <allow-intent href="itms:*" />
        <allow-intent href="itms-apps:*" />
    </platform>
    <plugin name="cordova-plugin-whitelist" />
    <plugin name="cordova-plugin-media" />
    <plugin name="cordova-plugin-firebase" />
    <plugin name="cordova-plugin-device" />
    <plugin name="cordova-plugin-admobpro" >
      <variable name="ADMOB_APP_ID" value="X" />
    </plugin>
</widget>

Any tips is more than welcome!

Thanks!

KalleJuhans
  • 129
  • 2
  • 10

0 Answers0